Delete Items from HQ database

Aug 15, 2009 2 Replies

We have taken physical inventory of a store and sync it with HQ.



We notice at least 30% of the items are not from our database (they were wrongly entered).



We need to delete those items in HQ so we can sync it with the store and have the correct items for the store.



Whats the best way to delete these items, which are in "0" and no activity, in HQ database


a query that would accomplish that task would look like this:

delete i from item i left join transactionentry e on i.id=e.itemid left join inventorytransferlog l on i.id=l.itemid where i.quantity=0 and e.id is null and l.id is null and itemtype=0

disclaimer: modify> We have taken physical inventory of a store and sync it with HQ. >

Understood.

Besides the query, is there an > a query that would accomplish that task would look like this:

Join the Discussion

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

Didn't find your answer?

Ask the community — no account required