@Bexy Morgan Welcome to Microsoft Q&A forum and thanks for reaching out here.
In Kusto, the equivalent data type for varchar is string. For nvarchar, there is no direct equivalent data type in Kusto. Azure Data Explorer has only one string type and for SQL clients it's encoded as NVARCHAR(MAX).
In case if you have a requirement to limit the string with a specific constant size (similar to that of e.g. NVARCHAR(5000)), Azure Data Explorer offers a different workaround. You can configure Azure Data Explorer to encode all strings as NVARCHAR(n) via a connection string. The language field in the connection string can be used to specify tuning options in the format, language@OptionName1:OptionValue1,OptionName2:OptionValue2.
For example, the following connection string will instruct Azure Data Explorer to encode strings as NVARCHAR(5000).
"Driver={ODBC Driver 17 for SQL Server};Server=mykustocluster.kusto.windows.net;Database=mykustodatabase;Authentication=ActiveDirectoryIntegrated,Language=any@MaxStringSize:5000"
Hope this info helps.
Please don’t forget to Accept Answer
and Yes
for "was this answer helpful" wherever the information provided helps you, this can be beneficial to other community members.