File Update

560 pts.
AS/400 SQL
Hi, I have a customized file which has 1Lakh records. We are using an ERP tool. We created an object in that tool using this customized file. So when we open that object in the view, it will list out all 1 Lakh records. Now I am updating only 10 records. So it will update in my file. At the end of the day users will try to update some other files using these customized files, so we provide an icon for them to update their files 1. Using Cursor we can do this-but SQL not allowed (we can't use) 2.Reading my customized file and updating their files- Due to 1 lakh records, performance will be very slow.  So I need to go with some other technique. Please give me some idea.

Software/Hardware used:

Answer Wiki

Thanks. We'll let you know when a new response is added.


Your question didn’t mention whether user files will contain all the records from your customized file or every user file will have some records from your customized file?

For any case, it will be better to use RPG program, so that you can update any number of files by using different CL Program with OVRDBF and RPG programs gives you a flexibility to add some validations too.

Discuss This Question: 6  Replies

There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.
  • philpl1jb
    Lakh what is a Lakh? Sounds like a potato pancake but that seems unlikely. Even if I knew that,, I'm not certain what you're application is doing. Phil
    54,090 pointsBadges:
  • carlosdl
    From Wikipedia: "A lakh (play /ˈlæk/ LAK or /ˈlɑːk/ LAHK; also lac; abbreviated L; Hindi: लाख, Nepali: लाख, Bengali: লাখ, Urdu: لاکھ) is a unit in the South Asian numbering system equal to one hundred thousand (100,000; 10^5)"
    85,885 pointsBadges:
  • philpl1jb
    Thanks Carlos. I think I had a better chance of answering this if it were potato pancakes, Latkes. Seriously, if you're copying a complete file to replace a complete file, then I think you might be looking at a CL Command CPYF (copy file) instead of a discreate RPG process. Phil
    54,090 pointsBadges:
  • Splat
    In my experience an RPG will be faster than a CPYF, especially if done as input primary / detail output. The program doesn't validate each record the way a CPYF does. But, as usual, circumstances determine the best solution.
    12,915 pointsBadges:
  • TomLiotta
    I have Customized File which has 1Lakh records.We are Using... Did any answer help you? If not, can you rephrase the question? It's not clear what you need to do. Please try to describe the purpose of your "Customized File". Why would performance be slow? A large number of records doesn't have to give poor performance. Tom
    125,585 pointsBadges:
  • The most-watched IT questions: April 2, 2012 - ITKE Community Blog
    [...] 3. Cursorposition and Splat explain how to update files using different CL programs. [...]
    0 pointsBadges:

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

Thanks! We'll email you when relevant content is added and updated.


Share this item with your network: