![]() | |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
Good day, Environment: DB2 Express-C 9.7 on Windows XP. From what I understood by a web search, DB2 compares the tables data always in a case sensitive way and can not be changed in this behaviour by default. (MS SQL Server could) Now my questions: 1) How do I best avoid invalid data in a primary key column. Say country_code should always be upper cased. Should a CHECK constraint be used? Are there other / better ways? 2) If I need to do a JOIN on some other (not constained) columns, what is the best way to enforce a comparison in a case insensitive way. Say 'Netherlands' and 'netherlands' and 'NETHERLANDS' should all JOIN in the same way. Should UCASE / LCASE put into the JOIN condition? What about the performance then? Other options here? Thanks and brgds Philipp Post Philipp, Actually you can create the database with a case insensitive |
#3
| |||
| |||
|
![]() |
| Thread Tools | |
| Display Modes | |
| |