More SQL help!

Sep 19, 2007 2 Replies

Can somebody give me a query which will return from my HQ database all items which have no tax assigned (via the store tax tab in HQ)



Thanks again!


This is what I run periodically to check for no tax ...

SELECT ITEMDYNAMIC.STOREID AS 'Store ID', ITEM.ITEMLOOKUPCODE AS 'Item', ITEM.DESCRIPTION AS 'Description', ITEM.BINLOCATION AS 'Bin Location', ITEMDYNAMIC.QUANTITY AS 'Quantity', ITEM.PRICE AS 'Price', ITEMDYNAMIC.TAXID AS 'Tax ID' FROM ITEMDYNAMIC LEFT JOIN ITEM ON ITEM.ID = ITEMDYNAMIC.ITEMID WHERE ITEMDYNAMIC.TAXID IS NULL

"Philip Gass" wrote:

Or you could simply type

select * from item where taxid=null

This will provide you with all the nulls but of course if you have incorrect taxids in there you wont see them. I know its unlikely that you do but ive seen it happen before so what you can do is type

select * from item where taxid1 and taxid2

This assumes that your 2 taxids are 1 and 2 of course, change these as you need to

"Philip Gass" wrote:

Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required