Dump from mssql

Поиск
Список
Период
Сортировка
Искать

Dump from mssql

От:
"Sidar Lopez Cruz" <sidarlopez@hotmail.com>
Дата:
how can i dump plaint text files from mssql to postgresql 7.3
the file format is...
 
"555555555","some people name",3
....
 
the table in mssql is
 
create table people (id varchar(20),name varchar(200),id_document bigint)
and the same in postgresql
 
remember that the file was generated by mssql with data transformation program (DTS)
 
S.O.S. i need to do this... for begin in postgresql?

:-) Sidar Lopez Cruz
- Cero Riesgo, S.A.

Re: Dump from mssql

От:
Robert Treat <xzilla@users.sourceforge.net>
Дата:
If none of your data contains commas, you can load it in with copy,
changing delimiters to , and then update the fields to strip out the "
once the data is loaded. 

If your data does contain commas (,) you'll need to do some awk/sed/perl
magic to better delimit your file (perhaps a @@@ between each field?)
Actually the DTS program might allow you to do this as well.

Robert Treat

On Wed, 2003-02-26 at 13:46, Sidar Lopez Cruz wrote:
> how can i dump plaint text files from mssql to postgresql 7.3
> the file format is...
>  
> "555555555","some people name",3
> ....
>  
> the table in mssql is
>  
> create table people (id varchar(20),name varchar(200),id_document
> bigint)
> and the same in postgresql
>  
> remember that the file was generated by mssql with data transformation
> program (DTS)
>  
> S.O.S. i need to do this... for begin in postgresql?
> 
> :-) Sidar Lopez Cruz
> - Cero Riesgo, S.A.



FAQ