Hello
I am trying to create a qry using tbls from an MRP system. The tbls are linked to a network and cannot be modified for security reasons.
The qry is pulling a bunch of part numbers that are past due. Each past due part number has a related so_no and a seqnr. This works fine.
I want to be able to run this qry and type in a due date value onto my own tbl. My tbl, along with a due date field, has both the so_no and seqnr as primary keys. I tried relating so_no to so_no and seqnr to seqnr on the MRP tbl, but all I get are intermmediate joins, and the qry doesn't return anything. I can change a join in the qry to Left Join, and the due date field shows up but it wont let me type anything in it.
Any suggestions on how to add a due date to this qry? A subquery, maybe? (I loooked into it, but didn't find much help there). Any suggestions would be helpful and appreciated.
Thanks
Jeremy
P.S. - Here is the working qry without a due date field.
SELECT dbo_bcklines.part_no, dbo_bcklines.seqnr, dbo_bcklines.partdesc, dbo_hnymastr.part_class, dbo_hnyquan.on_hand, dbo_bcklines.pre_invoiced, dbo_bcklines.so_no, dbo_bckmastr.order_date, dbo_bcklines.ship_date, dbo_customer.sort_name, dbo_bckmastr.credit_hold_flag, dbo_bcklines.open_qty, dbo_hnyquan.store_no
FROM (dbo_hnymastr INNER JOIN dbo_hnyquan ON dbo_hnymastr.part_number = dbo_hnyquan.part_no) INNER JOIN ((dbo_customer INNER JOIN dbo_bckmastr ON dbo_customer.cuscode = dbo_bckmastr.cuscode) INNER JOIN dbo_bcklines ON dbo_bckmastr.so_no = dbo_bcklines.so_no) ON dbo_hnymastr.part_number = dbo_bcklines.part_no
WHERE (((dbo_hnyquan.on_hand)<([open_qty]-[pre_invoiced])) AND ((dbo_bcklines.ship_date)>=[Start Date] And (dbo_bcklines.ship_date)<=[End Date]) AND ((dbo_bckmastr.credit_hold_flag)<>"H" AND ((dbo_bcklines.open_qty)<>0) AND ((dbo_hnyquan.store_no)="100");
I am trying to create a qry using tbls from an MRP system. The tbls are linked to a network and cannot be modified for security reasons.
The qry is pulling a bunch of part numbers that are past due. Each past due part number has a related so_no and a seqnr. This works fine.
I want to be able to run this qry and type in a due date value onto my own tbl. My tbl, along with a due date field, has both the so_no and seqnr as primary keys. I tried relating so_no to so_no and seqnr to seqnr on the MRP tbl, but all I get are intermmediate joins, and the qry doesn't return anything. I can change a join in the qry to Left Join, and the due date field shows up but it wont let me type anything in it.
Any suggestions on how to add a due date to this qry? A subquery, maybe? (I loooked into it, but didn't find much help there). Any suggestions would be helpful and appreciated.
Thanks
Jeremy
P.S. - Here is the working qry without a due date field.
SELECT dbo_bcklines.part_no, dbo_bcklines.seqnr, dbo_bcklines.partdesc, dbo_hnymastr.part_class, dbo_hnyquan.on_hand, dbo_bcklines.pre_invoiced, dbo_bcklines.so_no, dbo_bckmastr.order_date, dbo_bcklines.ship_date, dbo_customer.sort_name, dbo_bckmastr.credit_hold_flag, dbo_bcklines.open_qty, dbo_hnyquan.store_no
FROM (dbo_hnymastr INNER JOIN dbo_hnyquan ON dbo_hnymastr.part_number = dbo_hnyquan.part_no) INNER JOIN ((dbo_customer INNER JOIN dbo_bckmastr ON dbo_customer.cuscode = dbo_bckmastr.cuscode) INNER JOIN dbo_bcklines ON dbo_bckmastr.so_no = dbo_bcklines.so_no) ON dbo_hnymastr.part_number = dbo_bcklines.part_no
WHERE (((dbo_hnyquan.on_hand)<([open_qty]-[pre_invoiced])) AND ((dbo_bcklines.ship_date)>=[Start Date] And (dbo_bcklines.ship_date)<=[End Date]) AND ((dbo_bckmastr.credit_hold_flag)<>"H" AND ((dbo_bcklines.open_qty)<>0) AND ((dbo_hnyquan.store_no)="100");