Trying to connect to Datafile using ODBC and PHP, error when datafile on network computer

Jim Creak jim at jacsoft.co.nz
Mon Apr 22 22:22:27 EDT 2013


Has any one else attempted to use php and ODBC to access a datafile on the server with success who might be able to help with this problem?

Thanks
Jim

JACSoft Programming Ltd.



On 10/04/2013, at 2:55 PM, Jim Creak wrote:

> Hi All,
> 
> We're wanting to create some html reports for clients for easy viewing of data within their database so that they don't have to do a full log into Omnis to get some basic information. We've been working with php and odbc and things are working without any issues on our testing environment, which is all on the same computer.
> 
> We then moved to testing it more, this time by placing the datafile onto a server, and linking the odbc driver to that datafile. It dies with:
> 
> 	Warning: odbc_connect() [function.odbc-connect]: SQL error: Unable to read disk (bad disk), SQL state 08001 in SQLConnect in C:\xampp\htdocs\jP\includes\database.php on line 22
> 
> The ODBC link works fine with Excel we can look at and read all the records as needed.
> The datafile on the server is a direct copy of the datafile on the local computer, same user name and passwords.
> 
> Line 22 in the php file is 
> 
> 	$odbc_conn =  odbc_connect($name_odbc, $odbc_user, $odbc_pass)
> 
> The user name and password are correct, we've also tried leaving them blank, which works on the local data, but neither work with the remote data.
> 
> The server is sitting on the same network, and we have tried two different servers, with the same result for both.
> 
> Any hints would be appreciated.
> 
> Thanks
> Jim
> 
> JACSoft Programming Ltd.
> 
> 
> 
> _____________________________________________________________
> Manage your list subscriptions at http://lists.omnis-dev.com




More information about the omnisdev-en mailing list