sql - C# Windows Forms inner join three tables -
i have problem sql query in c#.
in database have tables: supplier, applicationform, supplieradress. trying join these 3 tables got syntax error inner join
.
also method in c# have input parameter appformid. parameter have open particular application form database on windows app.
this sql query:
command.commandtext = "select applicationform.date,applicationform.about,applicationform.supplier," + " supplier.idsupplier,supplier.name,supplier.email,supplier.phone," + " supplier.supplieradress,supplieradress.adressid,supplieradress.name" + " applicationform" + " inner join supplier on applicationform.supplier=supplier.idsupplier" + " inner join supplieradress on applicationform.supplier.supplieradress = supplieradress .adressid" + " applicationform.applicatonformid=" + appformid;
i hope me.
this wrong applicationform.supplier.supplieradress
try this, dunno exact field names:
from applicationform inner join supplier on applicationform.supplier=supplier.idsupplier inner join supplieradress on supplier.idadress =supplieradress.adressid
Comments
Post a Comment