[HACKERS] Getting error while trying to insert date with the format 'dd-month-yyyy' , 'day-mm-yyyy' etc..

2009-06-10 Thread Rushabh Lathia
Getting error while trying to insert date with the format 'dd-month-' , 'day-mm-' (format which add the space in between the date ) etc.. Testcase: postgres=# \d t Table public.t Column | Type | Modifiers +--+--- a | date | postgres=# insert into

Re: [HACKERS] Getting error while trying to insert date with the format 'dd-month-yyyy' , 'day-mm-yyyy' etc..

2009-06-10 Thread Tom Lane
Rushabh Lathia rushabh.lat...@gmail.com writes: Getting error while trying to insert date with the format 'dd-month-' , 'day-mm-' (format which add the space in between the date ) etc.. 1. Why are you bothering with the completely pointless to_char call at all? 2. It is not a bug that

Re: [HACKERS] Getting error while trying to insert date with the format 'dd-month-yyyy' , 'day-mm-yyyy' etc..

2009-06-10 Thread Peter Eisentraut
On Wednesday 10 June 2009 17:10:42 Tom Lane wrote: Rushabh Lathia rushabh.lat...@gmail.com writes: Getting error while trying to insert date with the format 'dd-month-' , 'day-mm-' (format which add the space in between the date ) etc.. 1. Why are you bothering with the completely

Re: [HACKERS] Getting error while trying to insert date with the format 'dd-month-yyyy' , 'day-mm-yyyy' etc..

2009-06-10 Thread Rushabh Lathia
On Thu, Jun 11, 2009 at 12:02 AM, Peter Eisentraut pete...@gmx.net wrote: On Wednesday 10 June 2009 17:10:42 Tom Lane wrote: Rushabh Lathia rushabh.lat...@gmail.com writes: Getting error while trying to insert date with the format 'dd-month-' , 'day-mm-' (format which add the

Re: [HACKERS] Getting error while trying to insert date with the format 'dd-month-yyyy' , 'day-mm-yyyy' etc..

2009-06-10 Thread Tom Lane
Rushabh Lathia rushabh.lat...@gmail.com writes: I thought when we are providing the different format into to_char for datetime then standard datetime input converters should also have the capability to read that format. to_char is designed to support a near-infinite number of output formats,