07-09-2021, 06:53 PM
I have failed to understand why some of BOM items are not showing yet when you run Bill Of Material Listing report they show.
I have a manufactured part 'COMFORT01' which totally returns null when you want check it's BOM list. yet on Bill Of Material Listing report shows that BOM components exists like it's in pic 1.
pic 2
Another case is again manufactured Part 'NEWTEST' has a missing BOM item missing yet on Bill Of Material Listing report it exists.
I tried to run this query manually from this file "BOMs.php" which displays [b]Component Details, again it returns null manufactured part '[b]COMFORT01' [/b][/b]
but when I tried to remove this AND RUN AGAIN
it returned some values.
So I failed to understand when creating New Component Details does the system sometimes fail to link the two tables "locstock and bm" or I there is a step I missed when creating locstock
I have a manufactured part 'COMFORT01' which totally returns null when you want check it's BOM list. yet on Bill Of Material Listing report shows that BOM components exists like it's in pic 1.
pic 2
Another case is again manufactured Part 'NEWTEST' has a missing BOM item missing yet on Bill Of Material Listing report it exists.
I tried to run this query manually from this file "BOMs.php" which displays [b]Component Details, again it returns null manufactured part '[b]COMFORT01' [/b][/b]
Code:
INNER JOIN stockcategory
ON stockcategory.categoryid = stockmaster.categoryid
INNER JOIN locations ON
bom.loccode = locations.loccode
INNER JOIN workcentres
ON bom.workcentreadded=workcentres.code
INNER JOIN locstock
ON bom.loccode=locstock.loccode
AND bom.component = locstock.stockid
INNER JOIN locationusers ON locationusers.loccode=locations.loccode AND locationusers.userid='admin' AND locationusers.canupd=1
WHERE
bom.component IN ('JUM002','FIR001','POLY002','TCOR001','COO001','TCOR005','TGLUE001','TPOLY001','TPOLY002','TPOLY003')
AND bom.parent IN ('COMFORT01','JUM003','TCOR001');
but when I tried to remove this AND RUN AGAIN
Code:
INNER JOIN locstock
ON bom.loccode=locstock.loccode
AND bom.component = locstock.stockid
it returned some values.
So I failed to understand when creating New Component Details does the system sometimes fail to link the two tables "locstock and bm" or I there is a step I missed when creating locstock