Re: [GENERAL] dbase converter

From: "Patrick Welche" <prlw1(at)newn(dot)cam(dot)ac(dot)uk>
To: phd2(at)earthling(dot)net (Oleg Broytmann)
Cc: jim(at)reptiles(dot)org (Jim Mercer), rems(at)gdansk(dot)sprint(dot)pl (Remigiusz Sokolowski), pgsql-general(at)postgresql(dot)org
Subject: Re: [GENERAL] dbase converter
Date: 1999-04-09 18:39:19
Message-ID: E10VgBT-0003ji-00@quartz.newn.cam.ac.uk
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Thanks to all who responded! As you mentioned Xbase really makes life easy
cf.http://www.startech.keller.tx.us/xbase/xbase.html
Knocked something together using it, and it looks uncannily like pg2xbase,
though the latter seems to need some fixing eg Pointer_to_Mem could be
initialised to prevent a spurious character followed by comma in
INSERT ( ,fieldname1,fieldname2)

Thanks again,

Patrick

Oleg Broytmann wrote on 21 Feb 1999:
> Hello!
>
> Just found on FreshMeat:
>
> http://w3.man.torun.pl/~makler/prog/pg2xbase.html
> Tool to convert Postgres to/from DBF files (required C++ and libxbase
> C++ library).
> Distribution license: GPL

Oleg Broytmann wrote on 8 Apr 1999:
> On Thu, 8 Apr 1999, Patrick Welche wrote:
> > Is there a dbase3 <=> postgresql converter available at all? I found
> > dbf2sql v2.2 which converts to (but not from) Postgres95, with notes such as
> >
> > -p primary:
> > Select the primary key. You have to give the exact
> > field-name. (Only for dbf2msql, Postgres95 doesn't have a primary key)
> >
> > which of course PostgreSQL does. Anyone know of something more recent?
>
> I heared about some project called "xbase". Try to search FreshMeat for
> "xbase", "dbf postgres" or such...

Remigiusz Sokolowski wrote on 9 Apr 1999:
> http://w3.man.torun.pl/~makler/prog/pg2xbase.html
> this address is worth of checking - as I see - there are here utilities
> for convertion from and to postgres.
> Hope this helps
> Rem

Jim Mercer wrote on 8 Apr 1999:
> i used the dbf2sql library to create a utility to dump dbf file into two
> ascii text files.
>
> one file generated is an sql create statement and the other is a series of
> sql insert statements, "insert into table (attr, attr) values (val, val);"
>
> for me, it was easy enough to modify the test files to my tastes with
> external scripts or manual editting, than to rework the code to do actual
> inserts.
>
> feel free to have a look:
>
> ftp://ftp.reptiles.org/pub/pgsql/dbf2sql-2.0-rep.tar.gz
>
> this is the dbf2sql-2.0 stuff, plus the source for my program (mydb).
> the makefile is minimally modified to my tastes.

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Aaron Holtz 1999-04-09 19:51:40 Inet and distinct bug or is it me? (v 6.5beta1)
Previous Message J J 1999-04-09 17:49:28 Win95 and psql - unsupported frontend protocol