Closed perdodi closed 9 years ago
PDO connection.php throws exception when setting charset ("SET NAMES") on Ms Access:
PDOException [ 42000 ]: SQLSTATE[42000]: Syntax error or access violation: -3500 [Microsoft][ODBC Microsoft Access Driver] Invalid SQL statement; expected 'DELETE', 'INSERT', 'PROCEDURE', 'SELECT', or 'UPDATE'. (SQLExecDirect[-3500] at ext\pdo_odbc\odbc_driver.c:247)
and SQLite:
PDOException [ HY000 ]: SQLSTATE[HY000]: General error: 1 near "SET": syntax error
Where database settings are:
'dsn' => 'odbc:Driver={Microsoft Access Driver (*.mdb)};Dbq=database.mdb;Uid=',
and
'dsn' => 'sqlite:database.sqlite',
On SQLite PRAGMA encoding = ... would help instead of SET NAMES, but I don't know what to do with MsAccess.
PRAGMA encoding = ...
SET NAMES
MS what? ;-)
I guess you PR has fixed this?
Guess it did...
PDO connection.php throws exception when setting charset ("SET NAMES") on Ms Access:
and SQLite:
Where database settings are:
and
On SQLite
PRAGMA encoding = ...
would help instead ofSET NAMES
, but I don't know what to do with MsAccess.