Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 How can i select pendent of delivery rows

Author  Topic 

Clages1
Yak Posting Veteran

69 Posts

Posted - 2007-10-30 : 11:20:41
Hi.
I need some help here
*codigo = Order code
*deposito = warehouse
*produto = goods
qttotal = qty requested by Customer
quantp2 = qty i can suply
qtpende = qty to be delivery later

* means fields key

the main order was 165000 with several goods
after processed was generated orders 165001 (01 is a sequence)
with goods that had not stock
after few weeks we have stock for goods IQ35F260J3 (qty 10)

after processed was generated orders 165002 (02 is a sequence)

and so on

finally i have this situation in this orders
takink a look i know that
Order 165003 goods IQ35F260J3 is still pendenting of 9.
all the othes was delivered.

the question is ?

how can i select only this row?


tks

Clages






codigo deposito produto qttotal quantp2 qtpende

165001 1 6680-23 2 0 4
165001 1 7501-13 4 0 4
165001 1 IQ35F260J3 19 10 9
165001 1 IQ35F150S 20 0 20

165002 1 6680-23 2 2 0
165002 1 7501-13 4 0 4
165002 1 IQ35F260J3 9 0 9
165002 1 IQ35F150S 20 0 20

165003 1 7501-13 4 4 0
165003 1 IQ35F260J3 9 0 9
165003 1 IQ35F150S 20 20 0
   

- Advertisement -