View previous topic :: View next topic
|
Author |
Message |
yogalakshmi
New User
Joined: 20 Sep 2007 Posts: 17 Location: cheenai
|
|
|
|
I have a table which has the following columns.
Main Table:
Branch
Account No
Account holder name
Account address
etc.
Say, Under a branch there might be 1 lakh accounts and there might be some 300 branches. Now, I want all the account details under some 50 branches(input in a file). I have two options.
a) Unload all the accounts from the table and extract only the accounts which are under given 50 branches(50 lakh accounts) through file processing
b) Retrieve the data through DB2 cursor.
Which one would be advisable. |
|
Back to top |
|
|
agkshirsagar
Active Member
Joined: 27 Feb 2007 Posts: 691 Location: Earth
|
|
|
|
Is this a one time requirement or you need to do it again sometime in future?
also
How about
c) Write a query and execute SPUFI in batch? |
|
Back to top |
|
|
Craq Giegerich
Senior Member
Joined: 19 May 2007 Posts: 1512 Location: Virginia, USA
|
|
|
|
Unload just the data you want. |
|
Back to top |
|
|
mkk157
Active User
Joined: 17 May 2006 Posts: 310
|
|
|
|
Hi,
R u looking to retrieve data for the same set of 50 branches every time or it vary from time to time ? |
|
Back to top |
|
|
shafeeqspi
New User
Joined: 01 Apr 2008 Posts: 4 Location: Mysore
|
|
|
|
U may use Cursor...
Regards,
Shaffu |
|
Back to top |
|
|
abhishekmdwivedi
New User
Joined: 22 Aug 2006 Posts: 95 Location: india
|
|
|
|
Quote: |
accounts which are under given 50 branches(50 lakh accounts) through file processing |
If you have this much of huge data . I would say go for unload and then process, rather then going through a DB2 cursor to fetch records one by one. A unload will be a optimized solution to this. |
|
Back to top |
|
|
yogalakshmi
New User
Joined: 20 Sep 2007 Posts: 17 Location: cheenai
|
|
|
|
Quote: |
R u looking to retrieve data for the same set of 50 branches every time or it vary from time to time ?
|
It is a weekly job. So the data will vary fom time to time.(every week)
Quote: |
A unload will be a optimized solution to this.
|
We have recommended to use unload instead of cursor (which is being used currently in the program) considering the huge volume of data.It is approved and we have started implementing the change.
Thank you all. |
|
Back to top |
|
|
|