× 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.



These most likely aren't the issue, but it has got to be something uncommon, right?

You are describing the ExtName(FileName) which defaults to the first format in the file. Just to prevent unexpected results I generally use the Format name instead of the file name.

One other thought: Does your PM file have the U for update in the file spec? (I lost the link to the specs you posted.)




On 5/1/2012 5:02 PM, John McKee wrote:
File 1 and file 2 are same length and same data types on the fields.
Only difference is the record format name and the second character of
the field names. Field names are not an issue, obviously. The am
file was populated via CPYF and then base file was cleared. Could
have used OVRDBF. Both files built via DDS. The am file has two key
fields to allow for CHAIN. I can't think of anything else.

John McKee

On Tue, May 1, 2012 at 4:41 PM, Monnier, Gary<Gary.Monnier@xxxxxxxxx> wrote:
Now here's a question I should have asked initially because it sounds like you are having a type/size mismatch problem.

Do File1 and File2 have the same structure? By this I mean does each field in File1 have the same properties as its counterpart in FileB (same data type, same size, same offset position, etc.)?

The fields in each file have to match exactly.

Have you manually compared File1 against File2?

Gary Monnier


-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx [mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of John McKee
Sent: Tuesday, May 01, 2012 2:14 PM
To: Midrange Systems Technical Discussion
Subject: Re: Stupid question

Booth,

Your sample is nearly identical to what I have. Difference is that without the e in the external position, SEU won't allow ExtName. Says keyword not allowed for a program described data structure. Put the 'e' there, and SEU is happy, compiler is happy. Just doesn't work right.

John McKee

On Tue, May 1, 2012 at 2:17 PM, Booth Martin<booth@xxxxxxxxxxxx> wrote:
Define two data structures with the EXTNAME key word:

D wFileA DS EXTNAME(Format1)
D wFileB DS EXTNAME(Format2)

C* If chain is successful,
C if wFileA = wFileB
C* delete record from file 2.

There is no need to load either DS. That is done automatically

On 5/1/2012 11:16 AM, John McKee wrote:
I posted this (I think - never get emails from posting) to the RPG
list. Never received a reply.

I have two files. Different names, formats, and field names.

One is produced early in the day.

I need to remove records from the second file that are identical to
those in the first file. Thus, second file only has new and changed
records.

I am stuck on how to set up a comparison of the entire record from
each file. I know I have done this, many years ago, but my brain is
just too foggy. I just don't want to have an IF with 90+ field
comparisons.

Logic is simple - read file 2, attempt to chain to file 1. No chain
- a new record. If chain is successful, compare the two records. If
same, delete record from file 2.

I can't directly compare the record formats. How do I define a
single field over each record?

I tried I-Specs - File name followed by single field name..

Dumb question. Thanks for a nudge.

John McKee

--
Booth Martin
802-461-5349
http://www.martinvt.com
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe,
unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take
a moment to review the archives at
http://archive.midrange.com/midrange-l.

--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take a moment to review the archives at http://archive.midrange.com/midrange-l.

--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-l.



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 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.