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



here's one way.

build your source like this:

create table &library/&filename

compile your SQL DDL source into a query manager query (CRTQMQRY) and
pass the library and file names into the source using the substitution
parameters in the STRQMQRY command.

STRQMQRY QMQRY(querylib/qryname) SETVAR((LIBRARY 'MYLIB') (FILENAME 'MYFILE'))

On 5/31/07, Jerry Adams <jerry@xxxxxxxxxxxxxxx> wrote:
I just started using DDL to define tables so this is certainly a newbie
question.


I have a lot of tables with exactly the same layout, but different
names. Is there a way to override the file name on the CREATE statement
[CREATE TABLE ARMAST ( , for example] so that I can use the same source
member to create different files? Even files that still use the S/36
group file id (such as A.ARMAST)? Same question as it relates to the
ALTER TABLE.


I saw in the RUNSQLSTM command the DFTRDBCOL parameter to tell it the
name of the schema (library), but I didn't see anything about the table
name.

--
* Jerry C. Adams
*IBM System i5/iSeries Programmer/Analyst
B&W Wholesale Distributors, Inc.* *
voice
615.995.7024
fax
615.995.1201
email
jerry@xxxxxxxxxxxxxxx <mailto:jerry@xxxxxxxxxxxxxxx>


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

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.