I made some test with hbpgsql on Linux i found with the harbour/contrib/hbpgsql/tests/test.prg
to make test.prg  working with postgresql 8.x i must change the row:

res := PQexec('drop table products')
to
res := PQexec(conn, 'drop table products')

res := PQexec('create table products ( product_no numeric(10), name varchar(20), price numeric(10,2) )')
to
res := PQexec(conn, 'create table products ( product_no numeric(10), name varchar(20), price numeric(10,2) )')


Also can we put some instructions to compile the hbcontrib lib under Linux at the end of the readme.txt file

Thank you.


Here my suggestion:

LINUX GCC
----------
On Linux you will need link libpq or references by pq.
For full api documentation look at:
http://www.postgresql.org/docs/current/static/libpq.html

Please set and export the env variable HB_CONTRIBLIBS=hbpgsql
export HB_CONTRIBLIBS=hbpgsql
change directory to the harbour/contrib/hbpgsql
compile with:
../../make_gnu.sh
then install library with:
../../make_gnu.sh install
to compile add the hbpgsql and pq lib into your library compile command line ( -lhbpgsql -lpq )

FILES:
postgres.c - Low level api
tpostgre.prg - Class implementation, it's to be seems like TMysql.
tests\simple.prg - Simple test class
tests\stress.prg - Stress test
tests\cache.prg - Show hot to use .dbf as pg cache, like TDataset for Delphi.
tests\Makefile -
tests\async.prg - ....
tests\bld_b32.bat - ....
tests\dbf2pg.prg -
tests\test.prg - Connect to server drop, create and insert record in a table ( products )
tests\tstpgrdd.prg


TODO:

That's all folks and sorry my poor english

Rodrigo Moreno - [EMAIL PROTECTED]
_______________________________________________
Harbour mailing list
Harbour@harbour-project.org
http://lists.harbour-project.org/mailman/listinfo/harbour

Reply via email to