Changeset: e329cecfab49 for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=e329cecfab49
Modified Files:
sql/test/orderidx/Tests/smalltable.sql
sql/test/orderidx/Tests/smalltable.stable.out
Branch: default
Log Message:
Testing small tables with ORDERED INDEX
diffs (103 lines):
diff --git a/sql/test/orderidx/Tests/smalltable.sql
b/sql/test/orderidx/Tests/smalltable.sql
--- a/sql/test/orderidx/Tests/smalltable.sql
+++ b/sql/test/orderidx/Tests/smalltable.sql
@@ -1,28 +1,30 @@
-- test robustness against small tables
-create table xtmp2( i integer);
-select schema, table, column, type, mode, count, hashes, phash, "imprints",
sorted, orderidx from storage where "table"= 'xtmp2';
-alter table xtmp2 set read only;
+CREATE TABLE xtmp2(i integer);
+SELECT schema, table, column, type, mode, count, hashes, phash, imprints,
sorted, orderidx FROM storage WHERE "table"= 'xtmp2';
+ALTER TABLE xtmp2 SET read only;
+CREATE ORDERED INDEX sys_xtmp2_i_oidx ON xtmp2(i);
+SELECT schema, table, column, type, mode, count, hashes, phash, imprints,
sorted, orderidx FROM storage WHERE "table"= 'xtmp2';
+SELECT * FROM xtmp2 wHERE i>=0 AND i<8;
---create ordered index sys_xtmp2_i_oidx on xtmp2(i);
-call createorderindex('sys','xtmp2','i');
-select schema, table, column, type, mode, count, hashes, phash, "imprints",
sorted, orderidx from storage where "table"= 'xtmp2';
-select * from xtmp2 where i>=0 and i <8;
+CREATE TABLE xtmp3(i integer);
+INSERT INTO xtmp3 VALUES(3);
+SELECT schema, table, column, type, mode, count, hashes, phash, imprints,
sorted, orderidx FROM storage WHERE "table"= 'xtmp3';
+ALTER TABLE xtmp3 SET read only;
+CREATE ORDERED INDEX sys_xtmp3_i_oidx ON xtmp3(i);
+SELECT schema, table, column, type, mode, count, hashes, phash, imprints,
sorted, orderidx from storage where "table"= 'xtmp3';
+SELECT * FROM xtmp3 WHERE i>=0 AND i<8;
-create table xtmp3( i integer);
-insert into xtmp3 values(3);
-select schema, table, column, type, mode, count, hashes, phash, "imprints",
sorted, orderidx from storage where "table"= 'xtmp3';
+CREATE TABLE xtmp4(i integer);
+INSERT INTO xtmp4 VALUES (3),(0),(2);
+SELECT schema, table, column, type, mode, count, hashes, phash, imprints,
sorted, orderidx FROM storage WHERE "table"= 'xtmp4';
+ALTER TABLE xtmp4 SET read only;
+CREATE ORDERED INDEX sys_xtmp4_i_oidx ON xtmp4(i);
+SELECT schema, table, column, type, mode, count, hashes, phash, imprints,
sorted, orderidx from storage where "table"= 'xtmp4';
+SELECT * FROM xtmp4 WHERE i>=0 AND i<8;
-alter table xtmp3 set read only;
---create ordered index sys_xtmp3_i_oidx on xtmp3(i);
-call createorderindex('sys','xtmp3','i');
-select schema, table, column, type, mode, count, hashes, phash, "imprints",
sorted, orderidx from storage where "table"= 'xtmp3';
-select * from xtmp3 where i>=0 and i <8;
-
-call droporderindex('sys','xtmp2','i');
-call droporderindex('sys','xtmp3','i');
---drop index sys_xtmp2_i_oidx;
---drop index sys_xtmp3_i_oidx;
-
-drop table xtmp2;
-drop table xtmp3;
-
+DROP INDEX sys_xtmp2_i_oidx;
+DROP INDEX sys_xtmp3_i_oidx;
+DROP INDEX sys_xtmp4_i_oidx;
+DROP TABLE xtmp2;
+DROP TABLE xtmp3;
+DROP TABLE xtmp4;
diff --git a/sql/test/orderidx/Tests/smalltable.stable.out
b/sql/test/orderidx/Tests/smalltable.stable.out
--- a/sql/test/orderidx/Tests/smalltable.stable.out
+++ b/sql/test/orderidx/Tests/smalltable.stable.out
@@ -72,10 +72,37 @@ Ready.
% int # type
% 1 # length
[ 3 ]
-#drop index sys_xtmp2_i_oidx;
-#drop index sys_xtmp3_i_oidx;
-#drop table xtmp2;
-#drop table xtmp3;
+#CREATE TABLE xtmp4(i integer);
+#INSERT INTO xtmp4 VALUES (3),(0),(2);
+[ 3 ]
+#SELECT schema, table, column, type, mode, count, hashes, phash, imprints,
sorted, orderidx FROM storage WHERE "table"= 'xtmp4';
+% .storage, .storage, .storage, .storage, .storage,
.storage, .storage, .storage, .storage, .storage,
.storage # table_name
+% schema, table, column, type, mode, count, hashes, phash,
imprints, sorted, orderidx # name
+% clob, clob, clob, clob, clob, bigint, bigint, boolean,
bigint, boolean, bigint # type
+% 3, 5, 1, 3, 8, 1, 1, 5, 1, 5,
1 # length
+[ "sys", "xtmp4", "i", "int", "writable", 3, 0,
false, 0, false, 0 ]
+#ALTER TABLE xtmp4 SET read only;
+#CREATE ORDERED INDEX sys_xtmp4_i_oidx ON xtmp4(i);
+#SELECT schema, table, column, type, mode, count, hashes, phash, imprints,
sorted, orderidx from storage where "table"= 'xtmp4';
+% .storage, .storage, .storage, .storage, .storage,
.storage, .storage, .storage, .storage, .storage,
.storage # table_name
+% schema, table, column, type, mode, count, hashes, phash,
imprints, sorted, orderidx # name
+% clob, clob, clob, clob, clob, bigint, bigint, boolean,
bigint, boolean, bigint # type
+% 3, 5, 1, 3, 8, 1, 1, 5, 1, 5,
2 # length
+[ "sys", "xtmp4", "i", "int", "readonly", 3, 0,
false, 0, false, 40 ]
+#SELECT * FROM xtmp4 WHERE i>=0 AND i<8;
+% sys.xtmp4 # table_name
+% i # name
+% int # type
+% 1 # length
+[ 3 ]
+[ 0 ]
+[ 2 ]
+#DROP INDEX sys_xtmp2_i_oidx;
+#DROP INDEX sys_xtmp3_i_oidx;
+#DROP INDEX sys_xtmp4_i_oidx;
+#DROP TABLE xtmp2;
+#DROP TABLE xtmp3;
+#DROP TABLE xtmp4;
# 11:38:23 >
# 11:38:23 > "Done."
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list