1

I'm trying to set up an ODBC connection to connect to Sage. The DSN is set up and works via Access and Excel. However using the PHP code below,

I get "SQL state IM002" or "[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified"

$odbc['dsn'] = "SageLine50v19";
$odbc['user'] = "Peachtree";
$odbc['pass'] = "XXXXX";
$mysql['host'] = "localhost";
$mysql['user'] = "root";
$mysql['pass'] = "";
$mysql['dbname'] = "sagetest";
$mysql['idfield'] = "id";
$debug=true;

Thanks

Kinfe
  • 305
  • 1
  • 3
  • 14
  • Maybe you should reading the [PHP Manual](http://php.net/manual/en/function.odbc-connect.php) The dsn parameter is more complex that the one you use as an example – RiggsFolly Oct 08 '14 at 16:38

1 Answers1

0

Deleteing the USER data source name and define it as a SYSTEM data source name.

Control Panel -> Administrative Tools ->Data Sources (ODBC): - User DSN : delete the specified User DSN - System DSN : create a new System DSN

Kinfe
  • 305
  • 1
  • 3
  • 14