On 30 Dec 2011, at 11:44am, Sushil Dudhalkar wrote:

> My query returns everything but the corresponding Supplier and customer 
> records. The query is as under. 

You are using double quotes here:

> where Transactions.DocID = "P-1001"

They should be single quotes:

where Transactions.DocID = 'P-1001'

Apart from that, I don't notice anything wrong.  Try doing a lookup which goes 
straight from the PO to the Suppliers table:

SELECT 
PO.Po_ID,
PO.Po_Date,
PO.QuoteNum,
PO.PayTerms,
PO.DeliveryDate,
PO.VAt,
PO.SrvcTax,
PO.Amount,
Suppliers.SName,
Suppliers.Address1,
Suppliers.Address2,
Suppliers.City,
FROM PO
LEFT JOIN Suppliers 
ON PO.SuppID = Suppliers.SID 

and see whether that works and does return the data that would correspond to 
the transaction P-1001.

Simon.
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to