Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Key Definiton using SQL 1

Status
Not open for further replies.

JimReiley

MIS
Dec 10, 2004
58
US
I am define all my tables with sql statements. I can't seem to get the syntax right to create a NON Case Sensitive key. My code is

Create UNIQUE INDEX ByDesc in dictionary ON Zones (ZoneDescription NO CASE,PubNumber,ZoneCode) #

Do I use NO CASE or is there something else I have missed? If I use NO CASE, where does it go in the above so that the ZoneDescription is treated with regard to case?

Thanks.
 
Actually, you set it at the CREATE TABLE level and not the CREATE INDEX. For example:
CREATE TABLE test (f1 char(10) case, f2 char(10))#
create index idxF1 on test (f1)#
create index idxF2 on test (f2)#

The statements above will create a table and will have two indexes. The first will be on F1 and will be case insensisitive while the second will be case sensitive on F2.


Mirtheil
Certified Pervasive Developer
Certified Pervasive Technician
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top