Received: from relay14.jaring.my (relay14.jaring.my [192.228.128.125]) by hub.org (8.9.2/8.9.1) with ESMTP id MAA11193; Sat, 6 Mar 1999 12:20:02 -0500 (EST) (envelope-from hoelc@pd.jaring.my) Received: from pd.jaring.my (j29.byb31.jaring.my [161.142.146.223]) by relay14.jaring.my (8.8.8/8.8.7) with ESMTP id BAA15913; Sun, 7 Mar 1999 01:19:28 +0800 (MYT) Message-ID: <36E163D7.CD95C55A@pd.jaring.my> Date: Sun, 07 Mar 1999 01:20:23 +0800 From: hoelc Reply-To: hoelc@pd.jaring.my X-Mailer: Mozilla 4.05 [en] (Win95; I) MIME-Version: 1.0 To: pgsql-admin@hub.org, pgsql-admin@postgreSQL.org, pgsql-general@hub.org Subject: date & time Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Hello, Can some one please tell me how to set the date&time in the PostgreSQL system? I try to use date('now') and time('now') to keep tract of the data and time when the data is inserted or updated. When I use sql " insert into table (data1, date_chg, time_chg) values ('abc',date('now'),time('now')) " to insert the date and time data, the data successfully inserted but when I retrive the data, it shows that the date and time is always " 01-01-2000 " and " 08:00:00 " , now is of couse not year 2000 and the time is also not 8 o'clock. Why? How should I correct this? I am using PostgreSQL in Linux system, and the date & time for Linux system are correct. One more question, what is the common data type for storing address? Thank you very much. Regards .... lch