Reputation: 37
I am working with SQL Server 2008 and have a select query that I am trying to create a Null column in.
The query is being used to create a tab delimited text file to be imported by a different system. I am using
Select data1 as col1, data2 as col2, '' as col3, data4 as col4
The problem apparently is that the other system does not see Col3 as NULL even though when I open it in Notepad++ it shows a NULL in that column. The vendor says there is something in that column. I assume they are seeing it as an empty string and not null.
What is a different/better way to put that NULL column in?
Thanks,
Upvotes: 0
Views: 69
Reputation: 2169
Select data1 as col1, data2 as col2, NULL as col3, data4 as col4 FROM tamble_name
Upvotes: 2