I create the following two tables that only differs the case:
tables.sql:
CREATE TABLE T1 (C1 INTEGER);
INSERT INTO T1 VALUES (1);
CREATE TABLE "t1" (C1 INTEGER);
INSERT INTO "t1" VALUES (2);
CREATE TABLE T2 (C1 INTEGER, "c1" integer);
INSERT INTO T2 VALUES (3, 4);
Command
db2 -tvf tables.sql
When I want to query the tables, directly from the CLP, I cannot differentiate the two types of case. How can I do a query to table T1 and another to table t1. The same for both columns C1 and c1?
In order to query those tables from CLP in Windows, you have to do:
For table T1 (The simplest one):
or (This is the way in Linux because of the *)
For table t1
For the columns is similar
For the other
Make sure that the whole command is involve in quotes. If you issue this command:
It will return C1 instead. The same for this command:
with T1 being returned.