pg.ddx.io pgsql-sql@postgresql.org mailing list archive
help / color / mirror / Atom feedDate datatype
4+ messages / 4 participants
[nested] [flat]
* Date datatype
@ 2004-12-20 23:41 Pablo Digonzelli <pdigonze@sa-sanmiguel.com>
0 siblings, 2 replies; 4+ messages in thread
From: Pablo Digonzelli @ 2004-12-20 23:41 UTC (permalink / raw)
To: pgsql-sql
hi all,
Ca anyone send me an example how to update a date datatype?
for example
update table set birthdate = "200-01-01" doesnt work.
TIA
Pablo
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: Date datatype
@ 2004-12-21 06:18 Együd Csaba (Freemail) <csegyud@freemail.hu>
parent: Pablo Digonzelli <pdigonze@sa-sanmiguel.com>
1 sibling, 0 replies; 4+ messages in thread
From: Együd Csaba (Freemail) @ 2004-12-21 06:18 UTC (permalink / raw)
To: Pablo Digonzelli <pdigonze@sa-sanmiguel.com>; pgsql-sql
Hi,
I think the problem is the double quote you use. Try a single quote e.g.:
update yourtable set birthdate='200-01-01' where ...
This man must be a very old one... :)
I tried it using timestamp not date, but I think it should work as well.
bye,
-- cs.
-----Original Message-----
From: pgsql-sql-owner@postgresql.org [mailto:pgsql-sql-owner@postgresql.org]
On Behalf Of Pablo Digonzelli
Sent: Tuesday, December 21, 2004 12:41 AM
To: pgsql-sql@postgresql.org
Subject: [SQL] Date datatype
hi all,
Ca anyone send me an example how to update a date datatype?
for example
update table set birthdate = "200-01-01" doesnt work.
TIA
Pablo
---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
--
No virus found in this incoming message.
Checked by AVG Anti-Virus.
Version: 7.0.296 / Virus Database: 265.6.0 - Release Date: 2004.12.17.
--
No virus found in this incoming message.
Checked by AVG Anti-Virus.
Version: 7.0.296 / Virus Database: 265.6.0 - Release Date: 2004.12.17.
--
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.296 / Virus Database: 265.6.0 - Release Date: 2004.12.17.
--
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.296 / Virus Database: 265.6.0 - Release Date: 2004.12.17.
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: Date datatype
@ 2004-12-21 08:38 Achilleus Mantzios <achill@matrix.gatewaynet.com>
parent: Pablo Digonzelli <pdigonze@sa-sanmiguel.com>
1 sibling, 1 reply; 4+ messages in thread
From: Achilleus Mantzios @ 2004-12-21 08:38 UTC (permalink / raw)
To: Pablo Digonzelli <pdigonze@sa-sanmiguel.com>; +Cc: pgsql-sql
O Pablo Digonzelli Ýãñáøå óôéò Dec 20, 2004 :
> hi all,
> Ca anyone send me an example how to update a date datatype?
> for example
> update table set birthdate = "200-01-01" doesnt work.
# update table set birthdate = '2000-01-01';
>
> TIA
> Pablo
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
>
--
-Achilleus
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: Date datatype
@ 2004-12-21 10:07 Iain <iain@mst.co.jp>
parent: Achilleus Mantzios <achill@matrix.gatewaynet.com>
0 siblings, 0 replies; 4+ messages in thread
From: Iain @ 2004-12-21 10:07 UTC (permalink / raw)
To: Achilleus Mantzios <achill@matrix.gatewaynet.com>; Pablo Digonzelli <pdigonze@sa-sanmiguel.com>; +Cc: pgsql-sql
or,
# update table set birthdate = to_date('2000-01-01','YYYY-MM-DD');
I'm not sure which is better though I tend to do it this way.
regards
Iain
----- Original Message -----
From: "Achilleus Mantzios" <achill@matrix.gatewaynet.com>
To: "Pablo Digonzelli" <pdigonze@sa-sanmiguel.com>
Cc: <pgsql-sql@postgresql.org>
Sent: Tuesday, December 21, 2004 5:38 PM
Subject: Re: [SQL] Date datatype
>O Pablo Digonzelli Ýãñáøå óôéò Dec 20, 2004 :
>
>> hi all,
>> Ca anyone send me an example how to update a date datatype?
>> for example
>> update table set birthdate = "200-01-01" doesnt work.
>
> # update table set birthdate = '2000-01-01';
>
>>
>> TIA
>> Pablo
>>
>>
>> ---------------------------(end of broadcast)---------------------------
>> TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
>>
>
> --
> -Achilleus
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
^ permalink raw reply [nested|flat] 4+ messages in thread
end of thread, other threads:[~2004-12-21 10:07 UTC | newest]
Thread overview: 4+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2004-12-20 23:41 Date datatype Pablo Digonzelli <pdigonze@sa-sanmiguel.com>
2004-12-21 06:18 ` Együd Csaba (Freemail) <csegyud@freemail.hu>
2004-12-21 08:38 ` Achilleus Mantzios <achill@matrix.gatewaynet.com>
2004-12-21 10:07 ` Iain <iain@mst.co.jp>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox