Tom: Be very careful how you mix up the time sequence and the format. Originally we had our sequence as HHMMSS, with a format of HH:MM:SS. We had a piece of program that would extract the max(datetimecol) from a table, and then bring up an edit form "where datetimecol = <value>". Later on, the time format was changed to "HH:MM AP", while the sequence remained as HHMMSS. The program that did the "where" clause then stopped working. I reported it to RBTI thinking it was a bug, but their response was that there was a mismatch between the 2 settings so it wouldn't work. We changed the format back to HH:MM:SS because the sequence was the more important thing for us.
Karen -----Original Message----- From: TOM HART <[email protected]> To: RBASE-L Mailing List <[email protected]> Sent: Sun, Mar 2, 2014 7:46 am Subject: [RBASE-L] - Re: Datetime issue My question is, will either way work as long as they are set to the same HH:MM ap/HHMM or HH:MM:SS/HHMMSS? Tom Hart From: A. Razzak Memon <[email protected]> To: RBASE-L Mailing List <[email protected]> Sent: Saturday, March 1, 2014 7:29 PM Subject: [RBASE-L] - Re: Datetime issue At 12:04 PM 3/1/2014, TOM HART wrote: > .. first thing I checked was the time format and it was HH:MM ap, looking > further I find the time seq is hhmmss. If I change both to the same either > HH:MM:SS and hhmmss, or HH:MM ap and hhmm they will both work. My question > is which is the proper way? Tom, FWIW ... The keyword SEQ (sequence) sets the "data entry" sequence such as HHMMSS while the keyword FOR (format) sets the "display format". This is as simple as it can get. The best practice, to be consistent, is to enforce all database settings, including CHARACTERs, CURRENCY, DATE, and TIME in application start-up file as follows: -- Example -- RBASE.DAT or Application Stat-up File SET QUOTES=NULL SET QUOTES=' IF (SGET(CVAL('VERSION'),2,21)) = '64' THEN SET NAMEWIDTH 32 ENDIF SET QUOTES=NULL SET QUOTES=' SET DELIMIT=NULL SET DELIMIT=',' SET LINEEND=NULL SET LINEEND='^' SET SEMI=NULL SET SEMI=';' SET PLUS=NULL SET PLUS='+' SET SINGLE=NULL SET SINGLE='_' SET MANY=NULL SET MANY='%' SET IDQUOTES=NULL SET IDQUOTES='`' SET CURRENCY '$' PREF 2 B SET DATE FORMAT MM/DD/YYYY SET DATE SEQUENCE MMDDYY SET DATE YEAR 30 SET DATE CENTURY 19 SET TIME FORMAT HH:MM AP SET TIME SEQUENCE HHMM CONNECT dbname IDENTIFIED BY user password -- Now Enforce Database Settings SET QUOTES=NULL SET QUOTES=' SET DELIMIT=NULL SET DELIMIT=',' SET LINEEND=NULL SET LINEEND='^' SET SEMI=NULL SET SEMI=';' SET PLUS=NULL SET PLUS='+' SET SINGLE=NULL SET SINGLE='_' SET MANY=NULL SET MANY='%' SET IDQUOTES=NULL SET IDQUOTES='`' SET CURRENCY '$' PREF 2 B SET DATE FORMAT MM/DD/YYYY SET DATE SEQUENCE MMDDYY SET DATE YEAR 30 SET DATE CENTURY 19 SET TIME FORMAT HH:MM AP SET TIME SEQUENCE HHMM SET NULL ' ' SET AUTOSKIP OFF SET ZERO ON SET WALKMENU ON RETURN You may adapt this technique for all your applications, if you wish. Feel free to modify these settings as you see fit. Using this routine, and enforcing your database specific settings, you will ALWAYS get consistent results. Very Best R:egards, Razzak. www.rbase.com www.facebook.com/rbase -- 31 years of continuous innovation! 16 Years of R:BASE Technologies, Inc. making R:BASE what it is today! --

