[Keystone Slip # 16] pg_dump, psql CURRENT_DATE problems - Mailing list pgsql-bugs

From webmaster@postgreSQL.org
Subject [Keystone Slip # 16] pg_dump, psql CURRENT_DATE problems
Date
Msg-id 199907261643.MAA10986@hub.org
Whole thread Raw
List pgsql-bugs
---------------------------------------------------------------------------
Slip number -----: 16
Problem ---------: pg_dump, psql CURRENT_DATE problems
Opened by -------: guybrush@icon.co.za on 07/25/99 15:19
Assigned To -----: thomas
---------------------------------------------------------------------------
Summary:
pg_dump dumps the following table:

CREATE TABLE t (d datetime DEFAULT CURRENT_DATE NOT NULL);

as follow:

connect - postgres
DROP TABLE "t";
CREATE TABLE "t" (
        "d" datetime DEFAULT date( 'current'::datetime + '0 sec') NOT NULL);

When trying to restore the table with psql it would typically result in the following error:

QUERY: CREATE TABLE "t" (
        "d" datetime DEFAULT date( 'current'::datetime + '0 sec') NOT NULL);
ERROR:  parser: parse error at or near "'"


---------------------------------------------------------------------------
History:
07/26/99 12:43 by scrappy:
Dependency changed to 0 from
Current tech changed to thomas from
Status changed to O from U
Contact changed to  from ANONYMOUS
Summary changed to pg_dump dumps the following table:

CREATE TABLE t (d datetime DEFAULT CURRENT_DATE NOT NULL);

as follow:

connect - postgres
DROP TABLE "t";
CREATE TABLE "t" (
        "d" datetime DEFAULT date( 'current'::datetime + '0 sec') NOT NULL);

When trying to restore the table with psql it would typically result in the following error:

QUERY: CREATE TABLE "t" (
        "d" datetime DEFAULT date( 'current'::datetime + '0 sec') NOT NULL);
ERROR:  parser: parse error at or near "'"

 from pg_dump dumps the following table:

CREATE TABLE t (d datetime DEFAULT CURRENT_DATE NOT NULL);

as follow:

connect - postgres
DROP TABLE "t";
CREATE TABLE "t" (
        "d" datetime DEFAULT date( 'current'::datetime + '0 sec') NOT NULL);

When trying to restore the table with psql it would typically result in the following error:

QUERY: CREATE TABLE "t" (
        "d" datetime DEFAULT date( 'current'::datetime + '0 sec') NOT NULL);
ERROR:  parser: parse error at or near "'"


Scheduled Close Date changed to 0 from
Scheduled Open Date changed to 0 from
Public setting changed to 1 from 0
Policy changed to 0

---------------------------------------------------------------------------


          Full information on this slip is available at:
http://www.postgresql.org/bugs/visitor.php3?sid=16&v_func=zoom

---------------------------------------------------------------------------
This message was generated automatically by Keystone at http://www.postgresql.org


pgsql-bugs by date:

Previous
From: webmaster@postgresql.org
Date:
Subject: [Keystone Slip # 10] make of 6.5.1 failed with flex 2.5.4
Next
From: webmaster@postgreSQL.org
Date:
Subject: [Keystone Slip # 17] Nameclash between PG and MS ERROR macros