RES: [unixODBC-support] php+odbc

Vinicius Dittgen vpd at jppa.com.br
Fri Nov 26 15:46:42 GMT 2004


Nick;

At the moment I do this:

First i install and compile the unixODBC driver with php, and I made
this(like have in the site docs):

In odbcinst.ini file I wrote:
[PostgreSQL]

Driver    = /usr/lib/libodbcpsql.so

Setup   = /usr/lib/libodbcpsqlS.so

FileUsage = 1

 


In odbc.ini file:
[PostgreSQL]

Driver    = PostgreSQL

Trace    = yes

TraceFile = sql.log         

Database = nick

Servername = localhost

UserName =

Password =

Port = 5432

Protocol = 6.4

 
My php:
$con = odbc_connect("PostgreSQL","","") or die("Erro na conexão com o
Database");

and i have this error:  

Warning: odbc_connect(): SQL error: [unixODBC][Driver Manager]Can't open
lib '/usr/lib/libodbcpsql.so' : /usr/lib/libodbcpsql.so: cannot open
shared object file: Arquivo ou diretório não encontrado, SQL state 01000
in SQLConnect in /home/httpd/html/teste/odbc.php on line 3
Erro na conexão com o Database


odbcinst.ini and odbc.ini files are in ../etc/    and   the libs are in
../usr/lib/


Vinicius Dittgen 
Informática
JPPA Gerenciamento e Projetos S/S Ltda
+55 51 2123-9000
www.jppa.com.br

-----Mensagem original-----
De: unixodbc-support-bounces at easysoft.com
[mailto:unixodbc-support-bounces at easysoft.com] Em nome de Nick Gorham
Enviada em: sexta-feira, 26 de novembro de 2004 13:02
Para: Support for the unixODBC project
Assunto: Re: [unixODBC-support] php+odbc

vpd at jppa.com.br wrote:

>not yet.
>and how I can do this???
>sorry but I don't have any experience whith databases, just whith
MySQL, and I
>have to import some informations that are in Paradox, so I think that
the best
>alternative is using ODBC, and now I'm trying to to learn how to do
this!!
>
>if you have some help??
>  
>

Ok, what have you done so far, have you created a DSN, have a look on 
the unixODBC web site and there is a doc there about configuring DSN's 
in odbc.ini odbcinst.ini

-- 
Nick
_______________________________________________
unixODBC-support mailing list
unixODBC-support at easysoft.com
http://mail.easysoft.com/mailman/listinfo/unixodbc-support

-- 
No virus found in this incoming message.
Checked by AVG Anti-Virus.
Version: 7.0.289 / Virus Database: 265.4.2 - Release Date: 24/11/04
 

-- 
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.289 / Virus Database: 265.4.2 - Release Date: 24/11/04
 





More information about the unixODBC-support mailing list