I am new to Azure and I have this field in my table in Azure SQL Data Warehouse:
[AnnotationText] varchar(MAX) NULL,
Based on what I read from https://docs.microsoft.com/en-us/sql/t-sql/data-types/char-and-varchar-transact-sql?view=sql-server-2017:
- varchar [ ( n | max ) ] Variable-size string data. Use n to define the string size in bytes and can be a value from 1 through 8,000 or use max to indicate a column constraint size up to a maximum storage of 2^31-1 bytes (2 GB).
But what I am seeing is the size of 8000 with this type of error message:
Too long string in column [-1]: Actual len = [11054]. MaxLEN=[8000]
I tried to hardcode the size but any number bigger than 8000 isn't working as written in the document.
Also I found some docs saying that HEAP or CLUSTERED INDEX type should be used in the table creation but it didn't help either
Any idea what went wrong?