Groups | Blog | Home
all groups > sql server new users > june 2006 >

sql server new users : Make field case sensitive



Greg Larsen
6/19/2006 10:28:02 AM
Yes. Use the COLLATE clause when you create the column to specify what
collation you want on that column.

Defining your column in a table might looks something like this if you want
a case sensative column:

[User_Password] [narchar] (20) COLLATE L_Latin1_General_CP1_CS_AS N

[quoted text, click to view]
Alejandro
6/19/2006 12:52:20 PM
I have an nvarchar field that stores a username, is there a way to make the
field case sensitive ?

A

Alejandro
6/19/2006 3:03:39 PM
The field is already created, is there a way I can make this change from the
Enterprise Manager ?

A


[quoted text, click to view]

Greg Larsen
6/19/2006 4:10:01 PM
Yes. Right click on the table, then select "Design Table". The in the Design
Table pane,click on the column you want to change, the in the column tab at
the bottom of the screen you will see a "Collation" heading. If you took the
default it will say "<database default>", or if you actually set a collation
the collation you set will be displayed. Click in the collation box and
buttoned labeled "..." will be displayed. Click on the "..." button and the
different collations will be displayed. Pick the collation you want, and
then save the table change.

[quoted text, click to view]
aneeshattingal
6/19/2006 10:55:04 PM
You can change the collation of the field to
SQL_Latin_General_CP1_CS_AS -- CS indicates Case Sensitive


[quoted text, click to view]

AddThis Social Bookmark Button