Determine if a SQL table column has any unicode

Trying to reduce database-table-size by changing nvarchar to varchar where there is no unicode

http://answers.microsoft.com/en-us/ie/forum/ie9-windows_vista/only-secure-content-is-displayed/b5b31a5b-0b6f-4b6d-bf28-741ad30e9f37

SELECT TheColumn
FROM MyTable
WHERE TheColumn<>CONVERT(nvarchar(100),CONVERT(varchar(100),TheColumn))

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: