You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
postgres/contrib/dateformat/test
Bruce Momjian 1c5aec60bb I finish devel. of Oracle compatible DateTime routines TO_CHAR(), 26 years ago
..
Makefile I finish devel. of Oracle compatible DateTime routines TO_CHAR(), 26 years ago
README I finish devel. of Oracle compatible DateTime routines TO_CHAR(), 26 years ago
rand_datetime.c I finish devel. of Oracle compatible DateTime routines TO_CHAR(), 26 years ago
regress.sql I finish devel. of Oracle compatible DateTime routines TO_CHAR(), 26 years ago

README


TO/FROM CHAR tests
~~~~~~~~~~~~~~~~~~

* rand_datetime

The program 'rand_datetime' output a random datetime strings
(with yaer range 0..9999), you can use this for datetime testing.

You can usage this (example) for table filling.

Usage:

./rand_datetime <randfile> <num> <prefix> <postfix>

Example:

./rand_datetime /dev/urandom 2 "INSERT INTO tab VALUES('" "'::datetime);"

INSERT INTO tab VALUES('Sat 27 Jul 13:08:57 19618'::datetime);
INSERT INTO tab VALUES('Wed 25 Aug 20:31:50 27450'::datetime);

* regress

psql < regress.sql (all answers, must be TRUE, for Posgres
datestyle)


--> TO_DATE() is simular as FROM_CHAR(), but convert full datetime
to date ==> needn't test (?).