What's your problem with converting DDS to DDL.
It is not a big deal (as long as you do not use features that are not supported by SQL for example EDTCDE and the physical file is not keyed). If the physical file is keyed, I'd suggest to create an additional index with this key and replace the keyed native I/O access onto the physical file with a (native) I/O access on the new index.
If you don't have a key on your physical, a reverse engineering, that creates the CREATE OR REPLACE statement (OR REPLACE is important) of the physical file and running the SQL Script, will convert the DDS described physical file into an SQL Table.
... and because the Format Level is not changed, you do not even have to recompile your programs with native I/O.
The DDS described logical files also can easily be converted (with reverse engineering) into SQL Indexes, which can be used with native I/O like any keyed logical file.
Running the generated SQL Script will convert the logical files into SQL indexes
... and again the format level is not changed so recompiling the programs with native I/O is not needed.
(BTW there are also companies/tools who will help you to automate the DDS to DDL conversion)
Mit freundlichen Grüßen / Best regards
Birgitta Hauser
"Shoot for the moon, even if you miss, you'll land among the stars." (Les Brown)
"If you think education is expensive, try ignorance." (Derek Bok)
"What is worse than training your staff and losing them? Not training them and keeping them!"
„Train people well enough so they can leave, treat them well enough so they don't want to.“ (Richard Branson)
-----Original Message-----
From: MIDRANGE-L <midrange-l-bounces@xxxxxxxxxxxxxxxxxx> On Behalf Of Mark Waterbury
Sent: Mittwoch, 31. Juli 2019 21:38
To: Midrange Systems Technical Discussion <midrange-l@xxxxxxxxxxxxxxxxxx>
Subject: Re: [EXTERNAL] Re: Expanding a field in a file or adding a new field to the file
Alan, and Charles,
Do not force the issue of converting from DDS to SQL DDL ... at least, not "right away" ...
In this case, for "legacy" applications, you can still use DDS to create a Logical File that has the exact same record layout, record format level ID, and it will have an index and so "native" Record I/O (e.g. RPG SETLL, READE etc.) will all work just fine.
This technique has been available since the days of the System/38 and CPF, and I am very surprised that more people are seemingly not aware of this method to avoid having to recompile all of the programs that use the "base" physical file, every time you want to add or change a single field or column in a database physical file.
Hope that helps,
Mark S. Waterbury
On Wednesday, July 31, 2019, 3:07:22 PM EDT, Charles Wilt <charles.wilt@xxxxxxxxx> wrote:
Sure it will...
Assume you have 100 programs that access the table now.
But only 10 actually do anything with the CC token column...
Instead of recompiling and testing 100 programs, you need only recompile and test 10.
Only catch is RPG programs that use RPG record level I/O through an SQL index (instead of a keyed logical file) Those would also need to be recompiled and tested as explicitly including columns in an SQL index changes the record layout...but that would only be needed this time. (Time time you change the table, you're golden.) I thought I had an RFE to change this...but guess not..
Charles
On Wed, Jul 31, 2019 at 12:19 PM Alan Shore via MIDRANGE-L < midrange-l@xxxxxxxxxxxxxxxxxx> wrote:
Thanks Sam
That article definitely helped
However, Im still not 100% sure this will help in what I need
Alan Shore
E-mail : ASHORE@xxxxxxxx
Phone [O] : (631) 200-5019
Phone [C] : (631) 880-8640
'If you're going through hell, keep going.'
Winston Churchill
-----Original Message-----
From: MIDRANGE-L [mailto:midrange-l-bounces@xxxxxxxxxxxxxxxxxx] On
Behalf Of Sam_L
Sent: Wednesday, July 31, 2019 2:08 PM
To: midrange-l@xxxxxxxxxxxxxxxxxx
Subject: Re: [EXTERNAL] Re: Expanding a field in a file or adding a
new field to the file
This article *might* help understand what Charles is suggesting:
https://www.mcpressonline.com/programming/rpg/use-a-logical-file-layer
-to-minimize-recompiles-from-field-additions
Sam
On 7/31/2019 2:00 PM, Alan Shore via MIDRANGE-L wrote:
Hi Charles
Im not too sure I have an understanding on this
I tried to create some type of diagram, following what you suggested
- but its NOT working out Any chance you could make it simpler for a
simpleton like me?
Alan Shore
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list To post a message email: MIDRANGE-L@xxxxxxxxxxxxxxxxxx To
subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives at
https://archive.midrange.com/midrange-l.
Please contact support@xxxxxxxxxxxx for any subscription related
questions.
Help support midrange.com by shopping at amazon.com with our affiliate
link: https://amazon.midrange.com
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list To post a message email: MIDRANGE-L@xxxxxxxxxxxxxxxxxx To
subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives at
https://archive.midrange.com/midrange-l.
Please contact support@xxxxxxxxxxxx for any subscription related
questions.
Help support midrange.com by shopping at amazon.com with our affiliate
link: https://amazon.midrange.com
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list To post a message email: MIDRANGE-L@xxxxxxxxxxxxxxxxxx To subscribe, unsubscribe, or change list options,
visit:
https://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives at
https://archive.midrange.com/midrange-l.
Please contact support@xxxxxxxxxxxx for any subscription related questions.
Help support midrange.com by shopping at amazon.com with our affiliate link:
https://amazon.midrange.com
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list To post a message email: MIDRANGE-L@xxxxxxxxxxxxxxxxxx To subscribe, unsubscribe, or change list options,
visit:
https://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives at
https://archive.midrange.com/midrange-l.
Please contact support@xxxxxxxxxxxx for any subscription related questions.
Help support midrange.com by shopping at amazon.com with our affiliate link:
https://amazon.midrange.com
As an Amazon Associate we earn from qualifying purchases.