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



The date is not stored in ANY format! It is stored as binary value!
Just execute SELECT HEX(MyDate) From MyFile

You'll detect the HEX value of a date has NOTHING to do with any date
format!

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!"


-----Ursprüngliche Nachricht-----
Von: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx] Im Auftrag von Luis Rodriguez
Gesendet: Friday, 21. October 2011 18:56
An: Midrange Systems Technical Discussion
Betreff: Re: SQLRPGLE create table

Raul,

In fact, SQL always store DATE fields in the *ISO format. What you are doing
with SET DATFMT is telling it how to show and accept dates (in your case,
DMY) in that particular program. Me? I would say go ahead and change
everything to *ISO :-)

BTW, "tryed" should be written as "tried" (I don't know you, but I always
appreciate when people correct my English (I'm from Venezuela))

Best Regards,

Luis Rodriguez
IBM Certified Systems Expert ? eServer i5 iSeries
--



On Fri, Oct 21, 2011 at 11:11 AM, Raul A. Jager W. <raul@xxxxxxxxxx> wrote:

Actual version 7.1
I want to re-create a table using SQL, and I want to be able to use the
programs that where compiled before the change. The old table was
created in the 90's using dds.

Mi problem is that a DATE field was defined in the *DMY format, and SQL
insist in creating *ISO. I tryed "set option datfmt=*dmy" I tryed the
parameter in the RUNSQLSTM, the SYSVAL is DMY, in an interactive SQL I
used f13 to set DMY, but "create table" ignores all. I even tryed
"create table like old..."

The reason why I whant to re-create the table now is that when I tryed
to set a constraint I got a message "The table is in use" even when I
had it allocated *EXCL. Digging into messages I found "5 -Object is
damaged" and in the actions it recomends to delete and restore or create.

Is there a way to create a DMY format date using SQL?
Shoul I make the change and re-compile everything?

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