Select Where and relationship sql table



SELECT
dbo.tblDocuments.arcId AS id,
dbo.tblFiles.arcDocumentId,
dbo.tblDocuments.D1 AS [Date],
dbo.tblDocuments.arcApp,
dbo.tblApplication.arcName AS DocName,
dbo.tblDocuments.S1 AS InvNo,
dbo.tblDocuments.S2 AS PoNo,
dbo.tblDocuments.S3 AS Vendor,
dbo.tblDocuments.N4 AS Ammount,
dbo.tblFiles.arcFileName AS Files,
dbo.tblFiles.arcPageCount AS Page
FROM dbo.tblDocuments
INNER JOIN dbo.tblFiles ON dbo.tblDocuments.arcId = dbo.tblFiles.arcDocumentId
INNER JOIN dbo.tblApplication ON dbo.tblDocuments.arcApp = dbo.tblApplication.arcId

WHERE dbo.tblDocuments.N4=1044

Comments