Dear community,
I received this error message when I tried to validated my ODBC connection with the DIXF modul.

I already changed my ODBC configuration to 32/64 Bit, used a system-/user-DSN on AOS and client.
Microsoft SQL Server ODBC Driver Version 06.03.9600
Running connectivity tests...
Attempting connection
Connection established
Verifying option settings
Disconnecting from server
TESTS COMPLETED SUCCESSFULLY!
When I'm using the follwing job there isn't a error message.
static void mod_ODBC_Test(Args _args)
{
LoginProperty loginProperty;
OdbcConnection odbcConnection;
Statement statement;
str sql, criteria;
SqlStatementExecutePermission perm;
;
// Set the information on the ODBC.
loginProperty = new LoginProperty();
loginProperty.setDSN("ODBCTEST");
loginProperty.setDatabase("my database");
//Create a connection to external database.
odbcConnection = new OdbcConnection(loginProperty);
if (odbcConnection)
{
sql = "my sql statement"
//Assert permission for executing the sql string.
perm = new SqlStatementExecutePermission(sql);
perm.assert();
//Prepare the sql statement.
statement = odbcConnection.createStatement();
statement.executeUpdate(sql);
//Close the connection.
statement.close();
}
else
{
error("Failed to log on to the database through ODBC.");
}
}
We are using AX 2012 R3 CU9.
Thanks in advance.
Regards,
Moritz
*This post is locked for comments
I have the same question (0)