I have two tables that are linked.
I have a table with a lot of products that is in a warehouse. Each product has a serialnumber that is unique, and a masternr that is not unique. every product has a masternr. I want a repport that print out how many products of each masternr that is in stock, and how much is sent out to customers.
I've tried to only have the mastertable as source, and get the number from the other table by using DLookup.
=DLookUp("[Målartype]";"Masterinfo";"Masternr = " & [Masternr])
That one worked since it is from the Masterinfo table.
=DCount("[Malernr]";"Lagerdata";"Masternr = " & [Masternr] & "StatusID = 1")
This one don't. Lagerdata is the table with all the unique serialnumbers. StatusID = 1 is "in stock".
If i use select and all the fields i would like includet, it write out a line for every serialnumber in the Lagerdata table, and thats not what i want, i only want a line for every masternr in Masterinfo-table.
Can someone help me with this one?
I have a table with a lot of products that is in a warehouse. Each product has a serialnumber that is unique, and a masternr that is not unique. every product has a masternr. I want a repport that print out how many products of each masternr that is in stock, and how much is sent out to customers.
I've tried to only have the mastertable as source, and get the number from the other table by using DLookup.
=DLookUp("[Målartype]";"Masterinfo";"Masternr = " & [Masternr])
That one worked since it is from the Masterinfo table.
=DCount("[Malernr]";"Lagerdata";"Masternr = " & [Masternr] & "StatusID = 1")
This one don't. Lagerdata is the table with all the unique serialnumbers. StatusID = 1 is "in stock".
If i use select and all the fields i would like includet, it write out a line for every serialnumber in the Lagerdata table, and thats not what i want, i only want a line for every masternr in Masterinfo-table.
Can someone help me with this one?