A simple example:
CREATE TABLE People (
personID int not null
, name nvarchar(50) not null
, addrLine1 nvarchar(50) null
, addrLine2 nvarchar(50) null
, suburb nvarchar(30) not null
, xmlRawInput ntext not null
, xmlRawOutput ntext null
)
GO
INSERT People (
personID
, name
, addrLine1
, addrLine2
, suburb
, xmlRawInput
, xmlRawOutput
)
SELECT
101 AS personID
, 'george benson' AS name
, '123 help st' AS addrLine1
, NULL AS addrLine2
, 'los angeles' AS suburb
, '<example>record<example>' AS xmlRawInput
, 'I LOVE MICROSOFT' AS xmlRawOutput
GO
This works fine; Notice Null can easily be inserted into addrLine2 column; But if i change 'I Love Microsoft' to NULL on the ntext column, i get following error: The conversion is not supported. [ Type to convert from (if known) = int, Type to convert to (if known) = ntext ]
Insert fails for below; any ideas? I am using CE version 3.5.8080.0.
INSERT People (
personID
, name
, addrLine1
, addrLine2
, suburb
, xmlRawInput
, xmlRawOutput
)
SELECT
101 AS personID
, 'george benson' AS name
, '123 help st' AS addrLine1
, NULL AS addrLine2
, 'los angeles' AS suburb
, '<example>record<example>' AS xmlRawInput
, NULL AS xmlRawOutput
GO