Buy Support
Incidents |
If you can't find your answer
in the FREE PUBLIC QDeveloper Forum, require URGENT Priority Support, or you need to send us
private or confidential information: |
Click Here
|
If you can't
login and post questions or you are having trouble viewing forum posts:
Click Here
|
Callback
Support |
If you live in USA, UK, Canada, Australia or New
Zealand, you can leave us details on your question and request us to call you back and discuss
them with you personally (charges apply). |
Click Here
|
Buy Support
Incidents |
If you can't find your answer
in the FREE PUBLIC QDeveloper Forum, require URGENT Priority Support, or you need to send us
private or confidential information: |
Click Here
|
|
SQL for Invoice with taken by who |
Author |
Message |
|
Posted : 2008-01-15 18:22:15 |
I am an QODBC user, I use the QODBC to extract data from the Quick Book Database, now I need to make a daily report using sql where I found the Invoice amount & the person who have taken that Invoice, is that possible, if yes please help me to do that. |
|
|
|
Tom |
|
Group | : Administrator |
Posts | : 5510 |
Joined | : 2006-02-17 |
|
Profile |
|
Posted : 2008-01-15 21:02:24 |
For all invoice lines since yesterday do:-
SELECT InvoiceLine.TxnDate, InvoiceLine.InvoiceLineItemRefListID, InvoiceLine.InvoiceLineItemRefFullName, InvoiceLine.InvoiceLineQuantity, {fn CURDATE()} as Today, ({fn CURDATE()}-1) as Yesterday FROM InvoiceLine InvoiceLine WHERE (InvoiceLine.TxnDate > {fn CURDATE()}-1) and InvoiceLineItemRefListID is not null ORDER BY InvoiceLine.InvoiceLineItemRefListID
If you just want today only do:
SELECT InvoiceLine.TxnDate, InvoiceLine.InvoiceLineItemRefListID, InvoiceLine.InvoiceLineItemRefFullName, InvoiceLine.InvoiceLineQuantity, {fn CURDATE()} as Today, ({fn CURDATE()}-1) as Yesterday FROM InvoiceLine InvoiceLine WHERE InvoiceLine.TxnDate = {fn CURDATE()} and InvoiceLineItemRefListID is not null ORDER BY InvoiceLine.InvoiceLineItemRefListID |
|
|
|
|