Thread: Dump/Restore of cvs regression database gives invalid timestamp syntax error
Dumping and restoring the regression database in cvs tip gives the following error upon restore: ERROR: invalid input syntax for type timestamp with time zone: "0097-02-16 17:32:01 BC-08" CONTEXT: COPY timestamptz_tbl, line 42, column d1: "0097-02-16 17:32:01 BC-08" Kris Jurka
Re: Dump/Restore of cvs regression database gives invalid timestamp syntax error
From
Tom Lane
Date:
Kris Jurka <books@ejurka.com> writes: > ERROR: invalid input syntax for type timestamp with time zone: > "0097-02-16 17:32:01 BC-08" Thanks for catching this. It never came up before because we never would try to output timezone info for a BC date... We could make it output either of 0097-02-16 17:32:01 BC -08 0097-02-16 17:32:01-08 BC as the input parser will take either. I'm kinda leaning to the latter; any contrary opinions? regards, tom lane
Re: Dump/Restore of cvs regression database gives invalid timestamp syntax error
From
Alvaro Herrera
Date:
On Thu, Jun 24, 2004 at 11:38:59AM -0400, Tom Lane wrote: > Kris Jurka <books@ejurka.com> writes: > > ERROR: invalid input syntax for type timestamp with time zone: > > "0097-02-16 17:32:01 BC-08" > > Thanks for catching this. It never came up before because we never > would try to output timezone info for a BC date... Maybe it's a good idea to routinely test regression dump/restore/dump (and compare both dumps). This could also mean trying to keep the most objects in it so features tested for regression are also tested for recoverability ... -- Alvaro Herrera (<alvherre[a]dcc.uchile.cl>) "El número de instalaciones de UNIX se ha elevado a 10, y se espera que este número aumente" (UPM, 1972)
I assume this is not fixed yet, right? --------------------------------------------------------------------------- Tom Lane wrote: > Kris Jurka <books@ejurka.com> writes: > > ERROR: invalid input syntax for type timestamp with time zone: > > "0097-02-16 17:32:01 BC-08" > > Thanks for catching this. It never came up before because we never > would try to output timezone info for a BC date... > > We could make it output either of > 0097-02-16 17:32:01 BC -08 > 0097-02-16 17:32:01-08 BC > as the input parser will take either. I'm kinda leaning to the latter; > any contrary opinions? > > regards, tom lane > > ---------------------------(end of broadcast)--------------------------- > TIP 2: you can get off all lists at once with the unregister command > (send "unregister YourEmailAddressHere" to majordomo@postgresql.org) > -- Bruce Momjian | http://candle.pha.pa.us pgman@candle.pha.pa.us | (610) 359-1001 + If your life is a hard drive, | 13 Roberts Road + Christ can be your backup. | Newtown Square, Pennsylvania 19073
Bruce Momjian <pgman@candle.pha.pa.us> writes: > I assume this is not fixed yet, right? It is not fixed, but given the lack of objections I'll go ahead and fix it as I proposed. regards, tom lane > --------------------------------------------------------------------------- > Tom Lane wrote: >> Kris Jurka <books@ejurka.com> writes: > ERROR: invalid input syntax for type timestamp with time zone: > "0097-02-16 17:32:01 BC-08" >> >> Thanks for catching this. It never came up before because we never >> would try to output timezone info for a BC date... >> >> We could make it output either of >> 0097-02-16 17:32:01 BC -08 >> 0097-02-16 17:32:01-08 BC >> as the input parser will take either. I'm kinda leaning to the latter; >> any contrary opinions? >> >> regards, tom lane >> >> ---------------------------(end of broadcast)--------------------------- >> TIP 2: you can get off all lists at once with the unregister command >> (send "unregister YourEmailAddressHere" to majordomo@postgresql.org) >> > -- > Bruce Momjian | http://candle.pha.pa.us > pgman@candle.pha.pa.us | (610) 359-1001 > + If your life is a hard drive, | 13 Roberts Road > + Christ can be your backup. | Newtown Square, Pennsylvania 19073 > ---------------------------(end of broadcast)--------------------------- > TIP 5: Have you checked our extensive FAQ? > http://www.postgresql.org/docs/faqs/FAQ.html
Tom just fixed this in CVS. --------------------------------------------------------------------------- Alvaro Herrera wrote: > On Thu, Jun 24, 2004 at 11:38:59AM -0400, Tom Lane wrote: > > Kris Jurka <books@ejurka.com> writes: > > > ERROR: invalid input syntax for type timestamp with time zone: > > > "0097-02-16 17:32:01 BC-08" > > > > Thanks for catching this. It never came up before because we never > > would try to output timezone info for a BC date... > > Maybe it's a good idea to routinely test regression dump/restore/dump > (and compare both dumps). This could also mean trying to keep the most > objects in it so features tested for regression are also tested for > recoverability ... > > -- > Alvaro Herrera (<alvherre[a]dcc.uchile.cl>) > "El n?mero de instalaciones de UNIX se ha elevado a 10, > y se espera que este n?mero aumente" (UPM, 1972) > > > ---------------------------(end of broadcast)--------------------------- > TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org > -- Bruce Momjian | http://candle.pha.pa.us pgman@candle.pha.pa.us | (610) 359-1001 + If your life is a hard drive, | 13 Roberts Road + Christ can be your backup. | Newtown Square, Pennsylvania 19073
Re: Dump/Restore of cvs regression database gives invalid timestamp syntax error
From
Alvaro Herrera
Date:
On Sun, Jul 11, 2004 at 09:02:06AM -0400, Bruce Momjian wrote: > Tom just fixed this in CVS. This particular problem, yes, but maybe we want to detect early this sort of problems in the future. That's why I think a dump/restore/dump and compare both dumps could be a good test. > Alvaro Herrera wrote: > > On Thu, Jun 24, 2004 at 11:38:59AM -0400, Tom Lane wrote: > > > Kris Jurka <books@ejurka.com> writes: > > > > ERROR: invalid input syntax for type timestamp with time zone: > > > > "0097-02-16 17:32:01 BC-08" > > > > > > Thanks for catching this. It never came up before because we never > > > would try to output timezone info for a BC date... > > > > Maybe it's a good idea to routinely test regression dump/restore/dump > > (and compare both dumps). This could also mean trying to keep the most > > objects in it so features tested for regression are also tested for > > recoverability ... -- Alvaro Herrera (<alvherre[a]dcc.uchile.cl>) "La soledad es compañía"