Welcome to the new Schneider Electric Community

It's your place to connect with experts and peers, get continuous support, and share knowledge.

  • Explore the new navigation for even easier access to your community.
  • Bookmark and use our new, easy-to-remember address (community.se.com).
  • Get ready for more content and an improved experience.

Contact SchneiderCommunity.Support@se.com if you have any questions.

Invite a Co-worker
Send a co-worker an invite to the Exchange portal.Just enter their email address and we’ll connect them to register. After joining, they will belong to the same company.
Send Invite Cancel

[Imported] ODBC Linked Table does not support NVARCHAR(MAX) from SQL

EcoStruxure Geo SCADA Expert Forum

Find out how SCADA systems and networks, like EcoStruxure Geo SCADA Expert, help industrial organizations maintaining efficiency, processing data for smarter decision making with IoT, RTU and PLC devices.

Janeway Janeway

[Imported] ODBC Linked Table does not support NVARCHAR(MAX) from SQL

>>Message imported from previous forum - Category:Scripts and Tips<<
User: mchartrand, originally posted: 2018-10-23 17:25:39 Id:179
This is a re-posting from the obsoleted (October 2018) "Schneider Electric Telemetry & SCADA" forum.


We have CS2017R2 and we have a linked ODBC table to SQL server. This all works fine, however one of the fields in our SQL table is set to type NVARCHAR(MAX) and contains about 4000 characters in it. The ODBC driver on our ClearSCADA server is the latest driver from microsoft (ODBC driver 17), and when we create a table in a ClearSCADA mimic to show the data, all fields show except for the NVARCHAR(MAX) one....it only shows the column names but does not return the data. Even if we only put say 20 characters in the field in SQL, it still does not appear in ClearSCADA.
Any ideas?_**


Some field types just don't map into ClearSCADA types.
Perhaps create a VIEW on this table for the linked table?


Thanks, but what field data type (containing a few thousand characters) could i create in the SQL view that would work on Clearscada?_**


I believe there may be a limit of 2000 chars - could you create and try a field of limited size?


Thanks, we have tried this with NVARCHAR(MAX) and no character length works at all. The NVARCHAR(2000) will work, but defeats the purpose as our fields will always be greater than 2000 characters. Looks like its a CS limitation that we cant work around for now. thanks for you help._**