any experience getting sapdb+php to run?
sapdb is running, jdbc connection is ok, database instance is created etc...
in /etc/odbc.ini (+ symlink to /(var|usr)/spool/sql/config/odbc.ini and /home/httpd/.odbc):
[TST]
ServerDB=TST
ServerNode=localhost
Driver = /home/sapdb/indep_prog/lib/libsqlod.so
and i get:
Establishing database connection.
Warning: SQL error: [SAP AG][LIBSQLOD SO]Data source name not found and no default driver specified., SQL state IM002 in SQLConnect in /home/httpd/htdocs/test/odbc.php on line 8
Connection failed.
// the php script
putenv("ODBCINSTINI=/etc/odbcinst.ini");
putenv("ODBCINI=/etc/odbc.ini");
phpinfo();
echo "Establishing database connection.";
$conn = odbc_connect("TST;","DBA","DBA") or die ("Connection failed.");
echo "Connection established.";
odbc_close($conn);
echo "Connection closed";
-----------------------
I think, the php has some trouble locating odbc.ini
php was compiled with --with-sapdb=/home/sapdb/indep_prog