Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Let functions return varchar instead of nvarchar (implicitly) for Fabric Data Warehouse

When running an "SELECT ... INTO" or "CTAS" query, the command fails:

CREATE TABLE TESTTABLE AS
SELECT JSON_VALUE(x, '$.test') as x
FROM (SELECT '{"test":"test"}' as x) as u

 

You have to wrap each JSON_VALUE function, or other functions returning an nvarchar with a CAST/CONVERT to not get this error.

Since the nvarchar data type does not exist for tables since they're always stored the same, please just convert it for us on the go.

Status: New