Error M189 Server Returned Error When Using ODBC To Access a Text Database From an On Demand Print Client.
Description
When using ODBC to access a text database from an On Demand Print Client, you receive the following message:
(M189) - Server Returned Error
An unexpected error has occurred on the LPS: Error from ODBC (opening recordset): " " is not a valid name. Make sure that it does not include invalid characters or punctuation and that it is not too long. ODBC Datasource is XXXXX (where XXXXX is the ODBC datasource name).
Explanation
This message has many possible causes, but this article specifically addresses the case where this message is returned by the ODP Client when accessing a text database (.csv, .txt).
Note: This error is not returned if the label is accessed using On Demand Print 32.
To Reproduce
- Create a .csv database.
- Register the.csv file as a text datasource in Data Sources (ODBC) (32 bit).
- Create a label format in design that uses the datasource name created.
- Open the label using the On Demand Print Client.
- The message will be returned once the data lookup is performed.
Solution
Upgrade both the client and the Loftware Print Server to version 10.1.0 or higher, and add the following entry to the llmwdn32.ini file on the client machine.
Navigate to: Start | All Programs | Loftware Clients | System Folders | Configuration | llmwdn32.ini, and add the following line to the ini file.
[ODBC]
useTableName=0
Requirements
Loftware Client version must be version 10.1 or higher for this setting to work.
Result
After making the changes to the ini file, the client will be able to retrieve the data from the database file and print with no issues.
Article Number
2013095
Versions
Any Supported Loftware version
Environment
All supported installation environments.