Hi!
I am developing a customized report in which i need to add a filter of item group id.
and fetch availphysical from inventsum and minimum and maximum quantity from reqitem table.
so I built a query
while select ItemId from inventItemGroupItem
where inventItemGroupItem.ItemGroupId == parmItemGroupId.parmObject()
join sum(AvailPhysical) from Inventsum
where inventsum.ItemId == inventItemGroupItem.ItemId
join MinInventOnhand,MaxInventOnhand from reqItemTable
where reqItemTable.ItemId == inventItemGroupItem.ItemId
here the problem is there are every record in inventtable but not all added to the inventory
and the table inventsum only contains the records which are added to the inventory and reqitemtable only provides the records of which minimum and maximum quantity has been added. so when i run this query it only fetches the records present in all three tables. otherwise it doesnt bring the other all records in invent table.
iwant to fetch all the records from inventtable and of which item the min max and avail physical is not available it show them blank but must fetch the data according to inventtable.
what should i do please help.
*This post is locked for comments
Make InventTable the first table in your query and use left outer joins for the other tables.
Also don't forget about InventDim. You wouldn't want to show the Min/Max quantities for one warehouse along with the available physical quantity for another.
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 291,232 Super User 2024 Season 2
Martin Dráb 230,064 Most Valuable Professional
nmaenpaa 101,156