×
The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.
Carel,
i would use an SQLDA DS to use on the different file (the F-specs can be
removed)
I've never used the SQLDA DS. I'm going to do some reading on it tonight
and see where it takes e. Thanks!!
----Original Message Follows----
From: "Carel Teijgeler" <coteijgeler@xxxxxxxxx>
Reply-To: RPG programming on the AS400 / iSeries <rpg400-l@xxxxxxxxxxxx>
To: rpg400-l@xxxxxxxxxxxx
Subject: Re: Help improve performance of RPG program - Long Post
Date: Tue, 24 May 2005 23:12:29 +0200
Rich,
I had a quick scan on your code and some suggestions:
I see you use embedded SQL and to make it more generic i would use an SQLDA
DS to use on the different file (the F-specs can be removed)
Create an SQL statement with the selected fields (point 5). Prepare and
describe the SQL statement using the SQLDA, then you have the field names
used in the result set (point 3: second record).
Fetch one record at the time using the SQLDA, format your date fields and
output string (point 4).
Regards,
Carel Teijgeler
*********** REPLY SEPARATOR ***********
On 24-5-05 at 20:34 Rich Dotson wrote:
>I have a program that we use to create export files that are ftp*d to our
> data warehouse application. The program works great functionally but
we
> would like to improve the performance on files that have a lot of
fields
> and a lot of records (500,000+).
>
> The program specs were:
>
> 1) Must be *generic* enough to process, without modification, any file
on our iSeries.
> 2) First row of file must contain:
> a) File Name
> b) Number of fields in file
> c) Number of Records in the file
> d) Last G/L posting date
> 3) Second row of the file must contain the field names
> 4) Subsequent rows will be the data
>
> A sample of the first three rows would look like:
> "XAT90090",5,1297,05/22/2005
> "EFFDATE","APPLCD","ACCTNO","ACCTTYP","TRANAMT"
> 05/19/2005,20,1234567890,1,-190.78
> 4) All dates must be in MM/DD/CCYY format. For this I created a file
> (XAP10005L1) that contains the fields that contain dates and the format
> that they are in: a) File Name b) Date Field Name c)Stored Date
> Format (*LongJul, *MDY, *JUL, *YMD, etc..) When processing a field I
> check this file to see if it is a date field and reformat it if it is.
>
> 5) Only the fields that the user selects should appear in the export
> file. The way I solved this issue is if the user does not want all
the
> fields in the data file, I created another PF DDS containing only the
> desired fields. I pull the data from one file based on the fields
this
> *template* file.
>
--
This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/rpg400-l.
_________________________________________________________________
FREE pop-up blocking with the new MSN Toolbar ? get it now!
http://toolbar.msn.click-url.com/go/onm00200415ave/direct/01/
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact
[javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.