1C:Enterprise platform integration capabilities and techniques

#1
People who like this: 0 Yes / 0 No
Just came
Rating: 1
Joined: Apr 24, 2026
Company:

Hello!

I'm facing an issue with 1C:Enterprise 8.3 (Linux) trying to connect to an external SAP HANA DB (version 2.00.042.00) via ODBC.

Sympthoms:

In the 1C Designer, the required tables from the SAPABAP1 schema are not visible at all, and the few visible from other schemas show no columns.

Creating the table and columns manually in 1C does not resolve the error.

In the 1C Tech Log (techlog, events EDS/EXCP), the generated SQL queries look perfectly fine.

BUT: In the ODBC trace log (odbc_trace.log), the query is truncated to a single [S] character, followed by SQLSTATE 42000, error 257: syntax error near "S".

isql utility successfully connects via the same DSN, lists tables/columns, and runs any query.

The DSN (/etc/odbc.ini), encoding, and system locale (UTF-8) are all set up correctly. Tech Logs show 1C attempts to send a correct SQL query, but it gets corrupted into a single [S] in the ODBC traces.

My Hypothesis:

The 1C platform, when working with an external source, first tries to retrieve metadata (table columns) by calling the ODBC function SQLColumns. In our specific SAP HANA version (2.00.042), the standard system views (SYS.COLUMNS, PUBLIC.COLUMNS) are either missing or inaccessible to the user. Because 1C fails to obtain the table structure, it cannot form a correct final SQL query, and the driver ends up receiving only the first letter of the command (SELECT -> S), leading to the syntax error.

The success of isql supports this, as it does not make such a preliminary SQLColumns call to display the structure.

Has anyone encountered this and knows a solution? Any help would be greatly appreciated.

 
#2
People who like this: 0 Yes / 0 No
Administrator
Rating: 31
Joined: Oct 3, 2019
Company:

Hello Max!

Interesting case!

It is quite difficult to identify the exact cause of the issue immediately, but as a first step I would suggest testing the connection with iusql instead of isql.

The reason is that isql may use a simpler ANSI ODBC path, while iusql checks the Unicode/Wide ODBC path. The 1C platform on Linux may use Unicode ODBC functions such as SQLExecDirectW, SQLPrepareW, or SQLColumnsW.

So if the connection or queries fail with iusql but work with isql, then the problem is most likely related to the ODBC driver...

One more question: have you just started the project for data exchange between 1C and HANA?

If you are still at the beginning of the project, I would advise you not to rely on external data sources in 1C. In my opinion, this mechanism is somewhat outdated.

I would rather consider using HTTP services, REST API, or something similar for this kind of integration.

 
#3
People who like this: 0 Yes / 0 No
Just came
Rating: 1
Joined: Apr 24, 2026
Company:

Aleksandr, thank you for your detailed response and valuable advice!

I will definitely test the connection using iusql – this is a very helpful point, as I wasn't aware of the difference between isql and iusql regarding the Unicode path.

I will also check the encoding settings – both in the DSN and in the 1C server environment.

Regarding your recommendation not to rely on external data sources in 1C – you are right, the mechanism is not the most modern. Our other database (Oracle) works stably via external sources, so I would still like to get to the bottom of the issue with HANA. But if I cannot make ODBC work, then I will seriously consider switching to HTTP/REST (OData or a custom service).

Thank you again for your help. I will report back after testing with iusql.

 
Subscribe
Users browsing this topic (guests: 2, registered: 0, hidden: 0)