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.
| Author |
Topic |
|
AskSQLTeam
Ask SQLTeam Question
0 Posts |
Posted - 2006-02-14 : 09:25:42
|
| Braja writes "i am developing web based order monitoring system , i have to write a store procedure to find out pending order, i am giving you table detail below.CREATE TABLE tbl_order (orderid char(10) ,orderno char(20),orderdt datetime, Status char (4))CREATE TABLE tbl_orderdtl (orderid char (10) , itemcd char (5) , size char (3) ,orderqty int)CREATE TABLE tbl_despatch (despid char(10), despno char(20),despdt datetime ,orderid char(10))CREATE TABLE tbl_despdtl (despid char(10) ,itemcd char(5),size char(3),despatchqty int)now i also give you data detail.data in tbl_orderOrderid orderno orderdt status ======= ====== ======= =======0000000001 ord/0001 01/01/2006 PWhen user enterd order then default of order status is P for pendingdata in tbl_orderdtlOrderid itemcd size orderqty ======= ====== ==== ========0000000001 FG001 32 1500000000001 FG001 34 1200000000001 FG001 36 180data in tbl_despatch despid despno despdt orderid====== ====== ====== =======0000000001 dsp/00001 05/01/2006 0000000001data in tbl_despatch despid itemcd size despatchqty ======= ====== ==== ========0000000001 FG001 32 1000000000001 FG001 34 750000000001 FG001 36 120" |
|
|
robvolk
Most Valuable Yak
15732 Posts |
Posted - 2006-02-14 : 09:27:39
|
| If you are "developing" this stored procedure, why are you making us do all the work? Perhaps you should hire a consultant who has SQL experience, or look in Books Online under "SELECT" and "JOIN" and "CREATE PROCEDURE". |
 |
|
|
|
|
|
|
|