Re: COPY COMMAND - Mailing list pgsql-general

From Savita
Subject Re: COPY COMMAND
Date
Msg-id 3DE34DA9.10A2E178@india.hp.com
Whole thread Raw
In response to Re: COPY COMMAND  ("Shridhar Daithankar" <shridhar_daithankar@persistent.co.in>)
Responses Re: COPY COMMAND  (Tino Wildenhain <tino@wildenhain.de>)
Re: COPY COMMAND  ("Shridhar Daithankar" <shridhar_daithankar@persistent.co.in>)
List pgsql-general
Hi,
I am able to insert the null field using \N in the text file,but while retiving
the data I am not able to retrive it.

After inserting data I tried this select statement

select * from os_customer_master where updated_by=' ';
and
select * from os_customer_master where updated_by=null;

but it gives 0 rows.then how will I select this values.


Shridhar Daithankar wrote:

> On 26 Nov 2002 at 15:20, Savita wrote:
>
> > I would like to know if some field is not present in Text file,then how does
> > COPY command handle it ,specially for date field.
>
> I am not very sure about this, but one thing you can always do is to insert a
> blank field separator, making copy believe that the field value is NULL.. Some
> sed/awk script should do the trick..
>
> HTH
>
> Bye
>  Shridhar
>
> --
> "We all know Linux is great...it does infinite loops in 5 seconds."(Linus
> Torvalds about the superiority of Linux on the AmterdamLinux Symposium)
>
> ---------------------------(end of broadcast)---------------------------
> TIP 5: Have you checked our extensive FAQ?
>
> http://www.postgresql.org/users-lounge/docs/faq.html

--
Best Regards
- Savita
----------------------------------------------------
Hewlett Packard (India)
+91 80 2051288 (Phone)
847 1288 (HP Telnet)
----------------------------------------------------



pgsql-general by date:

Previous
From: Tino Wildenhain
Date:
Subject: Re: ALTER TRIGGER DISABLE/ENABLE
Next
From: Tino Wildenhain
Date:
Subject: Re: COPY COMMAND