468,510 Members | 1,735 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 468,510 developers. It's quick & easy.

Please help. How to create Detail table using Summary

I have a following summary table:

DISP_ID CLAIM_TYPE ERROR_CODE FILE1_TOT FILE2_TOT
-------- ----------------------- ------------------------- -----------------
-- ---------------------
AA HUBC NOERR 379 410
AA HUBC 8018 118
127
AA HUBC 8019 226
235
AA HUBD 8022 15
22
.................................................. ............................
................
ER HUOP 9947 4
4
ER HUOP 51#L 5
5
.................................................. ............................
...............
UR HUBC NOERR 3066 3198
UR HUBC AAAA 144 144
UR HUBC BD01 12
17

I have to create(INSERT) 2 detail tables:

DISP_ID CLAIM_TYPE ERROR_CODE
AA HUBC 8018 <------ 379
ROWS IN TAB1, 410 IN TAB2
AA HUBC 8019 <------ 118
ROWS IN TAB1 , 127 IN TAB2
.................................................. ............................
.................................................. ....
.................................................. ............................
.................................................. ....
UR HUBC AAAA <------144 ROWS
IN TAB1, 144 IN TAB2
UR HUBC BD01 <------ 12
ROWS IN TAB1, 17 IN TAB2

Is this duable in one query or SP?
Need help. Thank's in advance.

--
Message posted via DBMonster.com
http://www.dbmonster.com/Uwe/Forums....m-db2/200803/1

Mar 22 '08 #1
0 949

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

1 post views Thread by Patrick Allmond | last post: by
2 posts views Thread by Jayjay | last post: by
3 posts views Thread by Kris van der Mast | last post: by
1 post views Thread by RJN | last post: by
reply views Thread by NPC403 | last post: by
1 post views Thread by fmendoza | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.