|
Or you can use SQL to add constraints to a PF built by DDS. Or you can use ADDPFCST to add constraints to a table built with SQL... In other words, there's basically no difference between a DDS PF and an SQL table. HTH, Charles > -----Original Message----- > From: Holden Tommy [mailto:Tommy.Holden@xxxxxxx] > Sent: Wednesday, October 13, 2004 7:51 PM > To: 'RPG programming on the AS400 / iSeries' > Subject: RE: CONSTRAINT DDS Equivalent > > > you can add constraints to files built by DDS via the > ADDPFCST command. > > Thanks, > Tommy Holden > > > -----Original Message----- > From: T.Bryant@xxxxxxxxxxxxxx [mailto:T.Bryant@xxxxxxxxxxxxxx] > Sent: Wednesday, October 13, 2004 6:30 PM > To: RPG programming on the AS400 / iSeries > Subject: Re: CONSTRAINT DDS Equivalent > > > What about a trigger program that validates the fields just before a > record is written. > This can take care of prompting the user for specific values > if incorrect. > When you need to change the specifics you only have to do so in one > program. > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > Troy Bryant > Analyst Programmer > Patrick Autocare. > Phone: +61 03 9926 9913 > Fax: +61 03 9926 9977 > Mobile: +61 0408 397 333 > T.Bryant@xxxxxxxxxxxxxx > > > > > > > > > I am in the process of building a new application, and I have a need > to create some fields that must contain a certain list of values. I > know that these files will be utilized by other programmers, and I > would like to ensure, at the file level, that only certain values make > it into these fields. > > I reviewed the DDS VALUES keyword for PFs, and it seems that this only > helps when building DSPFs that REF the file. I am comtemplating > creating these tables in SQL, and using the CONSTRAINT concept to > block data being placed into this file that doesn't match the required > list of values. This seems to work well, but I don't know > performance-wise if this will cause slowdowns. > > I was wondering, am I missing something, or is there a way to create a > PF using DDS (or Code Designer), such that only certain values are > allowed into a field? > > Thanks! > > > -- > "Enter any 11-digit prime number to continue..." > -- > 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. > > > > -- > 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. > -- > 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. >
As an Amazon Associate we earn from qualifying purchases.
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.