change error messages

This commit is contained in:
v-kaywon 2017-10-31 09:41:34 -07:00
parent 631f80a9af
commit 2ce10aceb0
2 changed files with 4 additions and 4 deletions

View file

@ -411,11 +411,11 @@ pdo_error PDO_ERRORS[] = {
}, },
{ {
PDO_SQLSRV_ERROR_CE_DIRECT_QUERY_UNSUPPORTED, PDO_SQLSRV_ERROR_CE_DIRECT_QUERY_UNSUPPORTED,
{ IMSSP, (SQLCHAR*) "Connection with Column Encryption enabled do no support PDO::SQLSRV_ATTR_DIRECT_QUERY with binding parameters.", -81, false } { IMSSP, (SQLCHAR*) "Parameterized statement with attribute PDO::SQLSRV_ATTR_DIRECT_QUERY is not supported in a Column Encryption enabled Connection.", -81, false }
}, },
{ {
PDO_SQLSRV_ERROR_CE_EMULATE_PREPARE_UNSUPPORTED, PDO_SQLSRV_ERROR_CE_EMULATE_PREPARE_UNSUPPORTED,
{ IMSSP, (SQLCHAR*) "Connection with Column Encryption enabled do no support PDO::ATTR_EMULATE_PREPARES with binding parameters.", -82, false } { IMSSP, (SQLCHAR*) "Parameterized statement with attribute PDO::ATTR_EMULATE_PREPARES is not supported in a Column Encryption enabled Connection.", -82, false }
}, },
{ UINT_MAX, {} } { UINT_MAX, {} }
}; };

View file

@ -24,7 +24,7 @@ try {
if (isColEncrypted()) { if (isColEncrypted()) {
if ($error[0] != "IMSSP" || if ($error[0] != "IMSSP" ||
$error[1] != -81 || $error[1] != -81 ||
$error[2] != "Connection with Column Encryption enabled do no support PDO::SQLSRV_ATTR_DIRECT_QUERY with binding parameters.") { $error[2] != "Parameterized statement with attribute PDO::SQLSRV_ATTR_DIRECT_QUERY is not supported in a Column Encryption enabled Connection.") {
echo "An unexpected exception was caught.\n"; echo "An unexpected exception was caught.\n";
var_dump($error); var_dump($error);
} }
@ -43,7 +43,7 @@ try {
if (isColEncrypted()) { if (isColEncrypted()) {
if ($error[0] != "IMSSP" || if ($error[0] != "IMSSP" ||
$error[1] != -82 || $error[1] != -82 ||
$error[2] != "Connection with Column Encryption enabled do no support PDO::ATTR_EMULATE_PREPARES with binding parameters.") { $error[2] != "Parameterized statement with attribute PDO::ATTR_EMULATE_PREPARES is not supported in a Column Encryption enabled Connection.") {
echo "An unexpected exception was caught.\n"; echo "An unexpected exception was caught.\n";
var_dump($error); var_dump($error);
} }