Changeset: 89ebef622a2c for MonetDB URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=89ebef622a2c Modified Files: sql/test/emptydb/Tests/check.stable.out sql/test/emptydb/Tests/check.stable.out.32bit sql/test/emptydb/Tests/check.stable.out.int128 Branch: default Log Message:
Approve output after changeset f4fd43daab84. diffs (truncated from 1332 to 300 lines): diff --git a/sql/test/emptydb/Tests/check.stable.out b/sql/test/emptydb/Tests/check.stable.out --- a/sql/test/emptydb/Tests/check.stable.out +++ b/sql/test/emptydb/Tests/check.stable.out @@ -123,11 +123,13 @@ Ready. \dSv sys.queue \dSv sys.rejects \dSv sys.roles +\dSv sys.schemastorage \dSv sys.sessions \dSv sys.storage \dSv sys.storagemodel \dSv sys.systemfunctions \dSv sys.tables +\dSv sys.tablestorage \dSv sys.tablestoragemodel \dSv sys.tracelog \dSv sys.users @@ -340,7 +342,6 @@ Ready. \dSf sys."stop" \dSf sys."stopmaster" \dSf sys."storage" -\dSf sys."storagemodel" \dSf sys."storagemodelinit" \dSf sys."str_to_date" \dSf sys."str_to_time" @@ -433,11 +434,13 @@ SYSTEM VIEW sys.querylog_history SYSTEM VIEW sys.queue SYSTEM VIEW sys.rejects SYSTEM VIEW sys.roles +SYSTEM VIEW sys.schemastorage SYSTEM VIEW sys.sessions SYSTEM VIEW sys.storage SYSTEM VIEW sys.storagemodel SYSTEM VIEW sys.systemfunctions SYSTEM VIEW sys.tables +SYSTEM VIEW sys.tablestorage SYSTEM VIEW sys.tablestoragemodel SYSTEM VIEW sys.tracelog SYSTEM VIEW sys.users @@ -788,7 +791,6 @@ SYSTEM AGGREGATE sys.stddev_samp SYSTEM PROCEDURE sys.stop SYSTEM PROCEDURE sys.stopmaster SYSTEM FUNCTION sys.storage -SYSTEM FUNCTION sys.storagemodel SYSTEM PROCEDURE sys.storagemodelinit SYSTEM FUNCTION sys.str_to_date SYSTEM FUNCTION sys.str_to_time @@ -859,7 +861,7 @@ CREATE TABLE "sys"."schemas" ("id" INTEG CREATE TABLE "sys"."sequences" ("id" INTEGER, "schema_id" INTEGER, "name" VARCHAR(256), "start" BIGINT, "minvalue" BIGINT, "maxvalue" BIGINT, "increment" BIGINT, "cacheinc" BIGINT, "cycle" BOOLEAN); CREATE TABLE "sys"."spatial_ref_sys" ("srid" INTEGER NOT NULL, "auth_name" VARCHAR(256), "auth_srid" INTEGER, "srtext" VARCHAR(2048), "proj4text" VARCHAR(2048), CONSTRAINT "spatial_ref_sys_srid_pkey" PRIMARY KEY ("srid")); CREATE TABLE "sys"."statistics" ("column_id" INTEGER, "type" CHARACTER LARGE OBJECT, "width" INTEGER, "stamp" TIMESTAMP, "sample" BIGINT, "count" BIGINT, "unique" BIGINT, "nils" BIGINT, "minval" CHARACTER LARGE OBJECT, "maxval" CHARACTER LARGE OBJECT, "sorted" BOOLEAN, "revsorted" BOOLEAN); -CREATE TABLE "sys"."storagemodelinput" ("schema" CHARACTER LARGE OBJECT, "table" CHARACTER LARGE OBJECT, "column" CHARACTER LARGE OBJECT, "type" CHARACTER LARGE OBJECT, "typewidth" INTEGER, "count" BIGINT, "distinct" BIGINT, "atomwidth" INTEGER, "reference" BOOLEAN, "sorted" BOOLEAN, "revsorted" BOOLEAN, "unique" BOOLEAN, "orderidx" BIGINT); +CREATE TABLE "sys"."storagemodelinput" ("schema" VARCHAR(1024) NOT NULL, "table" VARCHAR(1024) NOT NULL, "column" VARCHAR(1024) NOT NULL, "type" VARCHAR(1024) NOT NULL, "typewidth" INTEGER NOT NULL, "count" BIGINT NOT NULL, "distinct" BIGINT NOT NULL, "atomwidth" INTEGER NOT NULL, "reference" BOOLEAN NOT NULL, "sorted" BOOLEAN, "revsorted" BOOLEAN, "unique" BOOLEAN, "orderidxsize" BIGINT NOT NULL); CREATE TABLE "sys"."table_partitions" ("id" INTEGER, "table_id" INTEGER, "column_id" INTEGER, "expression" VARCHAR(2048), "type" TINYINT); CREATE TABLE "sys"."table_types" ("table_type_id" SMALLINT NOT NULL, "table_type_name" VARCHAR(25) NOT NULL, CONSTRAINT "table_types_table_type_id_pkey" PRIMARY KEY ("table_type_id"), CONSTRAINT "table_types_table_type_name_unique" UNIQUE ("table_type_name")); CREATE TABLE "sys"."triggers" ("id" INTEGER, "name" VARCHAR(1024), "table_id" INTEGER, "time" SMALLINT, "orientation" SMALLINT, "event" SMALLINT, "old_name" VARCHAR(1024), "new_name" VARCHAR(1024), "condition" VARCHAR(2048), "statement" VARCHAR(2048)); @@ -909,12 +911,14 @@ create view sys.querylog_history as sele create view sys.queue as select * from sys.queue(); create view sys.rejects as select * from sys.rejects(); create view sys.roles as select id, name, grantor from sys.auths a where a.name not in (select u.name from sys.db_users() u); +create view sys."schemastorage" as select "schema", count(*) as "storages", sum(columnsize) as columnsize, sum(heapsize) as heapsize, sum(hashes) as hashsize, sum("imprints") as imprintsize, sum(orderidx) as orderidxsize from sys."storage"() group by "schema" order by "schema"; create view sys.sessions as select * from sys.sessions(); -create view sys."storage" as select * from sys."storage"(); -create view sys.storagemodel as select * from sys.storagemodel(); +create view sys."storage" as select * from sys."storage"() order by "schema", "table", "column"; +create view sys.storagemodel as select "schema", "table", "column", "type", "count", columnsize("type", "count", "distinct", "atomwidth") as columnsize, heapsize("type", "count", "distinct", "atomwidth") as heapsize, hashsize("reference", "count") as hashsize, imprintsize("type", "count") as imprintsize, cast(8 * "count" as bigint) as orderidxsize, sorted, revsorted, "unique" from sys.storagemodelinput order by "schema", "table", "column"; create view sys.systemfunctions as select id as function_id from sys.functions where system; SELECT "id", "name", "schema_id", "query", CAST(CASE WHEN "system" THEN "type" + 10 ELSE (CASE WHEN "commit_action" = 0 THEN "type" ELSE "type" + 20 END) END AS SMALLINT) AS "type", "system", "commit_action", "access", CASE WHEN (NOT "system" AND "commit_action" > 0) THEN 1 ELSE 0 END AS "temporary" FROM "sys"."_tables" WHERE "type" <> 2 UNION ALL SELECT "id", "name", "schema_id", "query", CAST("type" + 30 AS SMALLINT) AS "type", "system", "commit_action", "access", 1 AS "temporary" FROM "tmp"."_tables"; -create view sys.tablestoragemodel as select "schema","table",max(count) as "count", sum(columnsize) as columnsize, sum(heapsize) as heapsize, sum(hashes) as hashes, sum("imprints") as "imprints", sum(case when sorted = false then 8 * count else 0 end) as auxiliary from sys.storagemodel() group by "schema","table"; +create view sys."tablestorage" as select "schema", "table", max("count") as "rowcount", count(*) as "storages", sum(columnsize) as columnsize, sum(heapsize) as heapsize, sum(hashes) as hashsize, sum("imprints") as imprintsize, sum(orderidx) as orderidxsize from sys."storage"() group by "schema", "table" order by "schema", "table"; +create view sys.tablestoragemodel as select "schema", "table", max("count") as "rowcount", count(*) as "storages", sum(columnsize("type", "count", "distinct", "atomwidth")) as columnsize, sum(heapsize("type", "count", "distinct", "atomwidth")) as heapsize, sum(hashsize("reference", "count")) as hashsize, sum(imprintsize("type", "count")) as imprintsize, sum(cast(8 * "count" as bigint)) as orderidxsize, sum(cast(case when sorted = false then 8 * "count" else 0 end as bigint)) as auxiliary from sys.storagemodelinput group by "schema", "table" order by "schema", "table"; create view sys.tracelog as select * from sys.tracelog(); SELECT u."name" AS "name", ui."fullname", ui."default_schema" FROM db_users() AS u LEFT JOIN "sys"."db_user_info" AS ui ON u."name" = ui."name" ; create view sys.var_values (var_name, value) as select 'cache' as var_name, convert(cache, varchar(10)) as value union all select 'current_role', current_role union all select 'current_schema', current_schema union all select 'current_timezone', current_timezone union all select 'current_user', current_user union all select 'debug', debug union all select 'history', history union all select 'last_id', last_id union all select 'optimizer', optimizer union all select 'pi', pi() union all select 'rowcnt', rowcnt; @@ -927,7 +931,7 @@ create procedure sys.analyze(minmax int, create function sys.bbp () returns table (id int, name string, ttype string, count bigint, refcnt int, lrefcnt int, location string, heat int, dirty string, status string, kind string) external name bbp.get; create function "broadcast" (p inet) returns inet external name inet."broadcast"; create procedure sys.clearrejects() external name sql.copy_rejects_clear; -create function sys.columnsize(nme string, i bigint, d bigint) returns bigint begin case when nme = 'boolean' then return i; when nme = 'char' then return 2*i; when nme = 'smallint' then return 2 * i; when nme = 'int' then return 4 * i; when nme = 'bigint' then return 8 * i; when nme = 'hugeint' then return 16 * i; when nme = 'timestamp' then return 8 * i; when nme = 'varchar' then case when cast(d as bigint) << 8 then return i; when cast(d as bigint) << 16 then return 2 * i; when cast(d as bigint) << 32 then return 4 * i; else return 8 * i; end case; else return 8 * i; end case; end; +create function sys.columnsize(tpe varchar(1024), count bigint, _distinct bigint, avgwidth int) returns bigint begin if tpe = 'tinyint' or tpe = 'boolean' then return count; end if; if tpe = 'smallint' then return 2 * count; end if; if tpe = 'int' or tpe = 'real' or tpe = 'date' or tpe = 'time' or tpe = 'timetz' or tpe = 'sec_interval' or tpe = 'month_interval' then return 4 * count; end if; if tpe = 'bigint' or tpe = 'decimal' or tpe = 'double' or tpe = 'timestamp' or tpe = 'timestamptz' or tpe = 'inet' or tpe = 'oid' then return 8 * count; end if; if tpe = 'hugeint' or tpe = 'uuid' then return 16 * count; end if; if tpe = 'varchar' or tpe = 'char' or tpe = 'clob' or tpe = 'json' or tpe = 'url' then return sys.sql_max(4 * count, 8192 + ((avgwidth + 8) * _distinct)); end if; if tpe = 'blob' then return (avgwidth + 8) * count; end if; return 16 * count; end; create function contains(a geometry, x double, y double) returns boolean external name geom."Contains"; create aggregate corr(e1 bigint, e2 bigint) returns double external name "aggr"."corr"; create aggregate corr(e1 double, e2 double) returns double external name "aggr"."corr"; @@ -985,13 +989,13 @@ create aggregate sys.group_concat(str st create aggregate sys.group_concat(str string, sep string) returns string external name "aggr"."str_group_concat"; create function has_m(info integer) returns integer external name geom."hasM"; create function has_z(info integer) returns integer external name geom."hasZ"; -create function sys.hashsize(b boolean, i bigint) returns bigint begin if b = true then return 8 * i; end if; return 0; end; -create function sys.heapsize(tpe string, i bigint, w int) returns bigint begin if tpe <> 'varchar' and tpe <> 'clob' then return 0; end if; return 10240 + i * w; end; +create function sys.hashsize(b boolean, count bigint) returns bigint begin if b = true then return 8 * count; end if; return 0; end; +create function sys.heapsize(tpe varchar(1024), count bigint, _distinct bigint, avgwidth int) returns bigint begin if tpe = 'varchar' or tpe = 'char' or tpe = 'clob' or tpe = 'json' or tpe = 'url' then return 8192 + ((avgwidth + 8) * _distinct); end if; if tpe = 'blob' then return (avgwidth + 8) * count; end if; return 0; end; create function "host" (p inet) returns clob external name inet."host"; create function "hostmask" (p inet) returns inet external name inet."hostmask"; create filter function "ilike"(val string, pat string) external name algebra."ilike"; create filter function "ilike"(val string, pat string, esc string) external name algebra."ilike"; -create function sys.imprintsize(i bigint, nme string) returns bigint begin if nme = 'boolean' or nme = 'tinyint' or nme = 'smallint' or nme = 'int' or nme = 'bigint' or nme = 'hugeint' or nme = 'decimal' or nme = 'date' or nme = 'timestamp' or nme = 'real' or nme = 'double' then return cast(i * 0.12 as bigint); end if ; return 0; end; +create function sys.imprintsize(tpe varchar(1024), count bigint) returns bigint begin if tpe = 'tinyint' or tpe = 'boolean' then return cast(0.2 * count as bigint); end if; if tpe = 'smallint' then return cast(0.4 * count as bigint); end if; if tpe = 'int' or tpe = 'real' or tpe = 'date' or tpe = 'time' or tpe = 'timetz' or tpe = 'sec_interval' or tpe = 'month_interval' then return cast(0.8 * count as bigint); end if; if tpe = 'bigint' or tpe = 'double' or tpe = 'timestamp' or tpe = 'timestamptz' or tpe = 'oid' then return cast(1.6 * count as bigint); end if; if tpe = 'hugeint' or tpe = 'decimal' then return cast(3.2 * count as bigint); end if; return 0; end; create function internaltransform(geom geometry, srid_src integer, srid_dest integer, proj4_src string, proj4_dest string) returns geometry external name geom."Transform"; create function isaurl(theurl url) returns bool external name url."isaURL"; create function sys.isauuid(s string) returns boolean external name uuid."isaUUID"; @@ -1226,12 +1230,11 @@ create aggregate stddev_samp(val tinyint create procedure sys.stop(tag bigint) external name sql.sysmon_stop; create procedure sys.stop(tag int) external name sql.sysmon_stop; create procedure stopmaster() external name wlc.stopmaster; -create function sys."storage"(sname string) returns table ("schema" string, "table" string, "column" string, "type" string, "mode" string, location string, "count" bigint, typewidth int, columnsize bigint, heapsize bigint, hashes bigint, phash boolean, "imprints" bigint, sorted boolean, revsorted boolean, "unique" boolean, orderidx bigint) external name sql."storage"; -create function sys."storage"(sname string, tname string) returns table ("schema" string, "table" string, "column" string, "type" string, "mode" string, location string, "count" bigint, typewidth int, columnsize bigint, heapsize bigint, hashes bigint, phash boolean, "imprints" bigint, sorted boolean, revsorted boolean, "unique" boolean, orderidx bigint) external name sql."storage"; -create function sys."storage"(sname string, tname string, cname string) returns table ("schema" string, "table" string, "column" string, "type" string, "mode" string, location string, "count" bigint, typewidth int, columnsize bigint, heapsize bigint, hashes bigint, phash boolean, "imprints" bigint, sorted boolean, revsorted boolean, "unique" boolean, orderidx bigint) external name sql."storage"; -create function sys."storage"() returns table ("schema" string, "table" string, "column" string, "type" string, "mode" string, location string, "count" bigint, typewidth int, columnsize bigint, heapsize bigint, hashes bigint, phash boolean, "imprints" bigint, sorted boolean, revsorted boolean, "unique" boolean, orderidx bigint) external name sql."storage"; -create function sys.storagemodel() returns table ("schema" string, "table" string, "column" string, "type" string, "count" bigint, columnsize bigint, heapsize bigint, hashes bigint, "imprints" bigint, sorted boolean, revsorted boolean, "unique" boolean, orderidx bigint) begin return select i."schema", i."table", i."column", i."type", i."count", columnsize(i."type", i.count, i."distinct"), heapsize(i."type", i."distinct", i."atomwidth"), hashsize(i."reference", i."count"), imprintsize(i."count",i."type"), i.sorted, i.revsorted, i."unique", i.orderidx from sys.storagemodelinput i; end; -create procedure sys.storagemodelinit() begin delete from sys.storagemodelinput; insert into sys.storagemodelinput select x."schema", x."table", x."column", x."type", x.typewidth, x.count, 0, x.typewidth, false, x.sorted, x.revsorted, x."unique", x.orderidx from sys."storage"() x; update sys.storagemodelinput set reference = true where concat(concat("schema","table"), "column") in (select concat(concat("fkschema"."name", "fktable"."name"), "fkkeycol"."name") from "sys"."keys" as "fkkey", "sys"."objects" as "fkkeycol", "sys"."tables" as "fktable", "sys"."schemas" as "fkschema" where "fktable"."id" = "fkkey"."table_id" and "fkkey"."id" = "fkkeycol"."id" and "fkschema"."id" = "fktable"."schema_id" and "fkkey"."rkey" > -1); update sys.storagemodelinput set "distinct" = "count" where "type" = 'varchar' or "type"='clob'; end; +create function sys."storage"() returns table ("schema" varchar(1024), "table" varchar(1024), "column" varchar(1024), "type" varchar(1024), "mode" varchar(15), location varchar(1024), "count" bigint, typewidth int, columnsize bigint, heapsize bigint, hashes bigint, phash boolean, "imprints" bigint, sorted boolean, revsorted boolean, "unique" boolean, orderidx bigint) external name sql."storage"; +create function sys."storage"(sname varchar(1024)) returns table ("schema" varchar(1024), "table" varchar(1024), "column" varchar(1024), "type" varchar(1024), "mode" varchar(15), location varchar(1024), "count" bigint, typewidth int, columnsize bigint, heapsize bigint, hashes bigint, phash boolean, "imprints" bigint, sorted boolean, revsorted boolean, "unique" boolean, orderidx bigint) external name sql."storage"; +create function sys."storage"(sname varchar(1024), tname varchar(1024)) returns table ("schema" varchar(1024), "table" varchar(1024), "column" varchar(1024), "type" varchar(1024), "mode" varchar(15), location varchar(1024), "count" bigint, typewidth int, columnsize bigint, heapsize bigint, hashes bigint, phash boolean, "imprints" bigint, sorted boolean, revsorted boolean, "unique" boolean, orderidx bigint) external name sql."storage"; +create function sys."storage"(sname varchar(1024), tname varchar(1024), cname varchar(1024)) returns table ("schema" varchar(1024), "table" varchar(1024), "column" varchar(1024), "type" varchar(1024), "mode" varchar(15), location varchar(1024), "count" bigint, typewidth int, columnsize bigint, heapsize bigint, hashes bigint, phash boolean, "imprints" bigint, sorted boolean, revsorted boolean, "unique" boolean, orderidx bigint) external name sql."storage"; +create procedure sys.storagemodelinit() begin delete from sys.storagemodelinput; insert into sys.storagemodelinput select "schema", "table", "column", "type", typewidth, "count", 0, typewidth, false, sorted, revsorted, "unique", orderidx from sys."storage"() where ("schema", "table") in (select sch."name", tbl."name" from sys."_tables" as tbl join sys."schemas" as sch on tbl.schema_id = sch.id where tbl."system" = false) order by "schema", "table", "column"; update sys.storagemodelinput set "distinct" = "count" where "unique" = true or "type" in ('varchar', 'char', 'clob', 'blob', 'json', 'url'); update sys.storagemodelinput set reference = true where ("schema", "table", "column") in (select fkschema."name", fktable."name", fkkeycol."name" from sys."keys" as fkkey, sys."objects" as fkkeycol, sys."tables" as fktable, sys."schemas" as fkschema where fktable."id" = fkkey."table_id" and fkkey."id" = fkkeycol."id" and fkschema."id" = fktable."schema_id" and fkkey."rkey" > -1); end; create function str_to_date(s string, format string) returns date external name mtime."str_to_date"; create function str_to_time(s string, format string) returns time external name mtime."str_to_time"; create function str_to_timestamp(s string, format string) returns timestamp external name mtime."str_to_timestamp"; @@ -1418,18 +1421,20 @@ drop function pcre_replace(string, strin [ "sys", "rejects", "create view sys.rejects as select * from sys.rejects();", "VIEW", true, "COMMIT", "WRITABLE" ] [ "sys", "roles", "create view sys.roles as select id, name, grantor from sys.auths a where a.name not in (select u.name from sys.db_users() u);", "VIEW", true, "COMMIT", "WRITABLE" ] [ "sys", "schemas", NULL, "TABLE", true, "COMMIT", "WRITABLE" ] +[ "sys", "schemastorage", "create view sys.\"schemastorage\" as select \"schema\", count(*) as \"storages\", sum(columnsize) as columnsize, sum(heapsize) as heapsize, sum(hashes) as hashsize, sum(\"imprints\") as imprintsize, sum(orderidx) as orderidxsize from sys.\"storage\"() group by \"schema\" order by \"schema\";", "VIEW", true, "COMMIT", "WRITABLE" ] [ "sys", "sequences", NULL, "TABLE", true, "COMMIT", "WRITABLE" ] [ "sys", "sessions", "create view sys.sessions as select * from sys.sessions();", "VIEW", true, "COMMIT", "WRITABLE" ] [ "sys", "spatial_ref_sys", NULL, "TABLE", true, "COMMIT", "WRITABLE" ] [ "sys", "statistics", NULL, "TABLE", true, "COMMIT", "WRITABLE" ] -[ "sys", "storage", "create view sys.\"storage\" as select * from sys.\"storage\"();", "VIEW", true, "COMMIT", "WRITABLE" ] -[ "sys", "storagemodel", "create view sys.storagemodel as select * from sys.storagemodel();", "VIEW", true, "COMMIT", "WRITABLE" ] +[ "sys", "storage", "create view sys.\"storage\" as select * from sys.\"storage\"() order by \"schema\", \"table\", \"column\";", "VIEW", true, "COMMIT", "WRITABLE" ] +[ "sys", "storagemodel", "create view sys.storagemodel as select \"schema\", \"table\", \"column\", \"type\", \"count\", columnsize(\"type\", \"count\", \"distinct\", \"atomwidth\") as columnsize, heapsize(\"type\", \"count\", \"distinct\", \"atomwidth\") as heapsize, hashsize(\"reference\", \"count\") as hashsize, imprintsize(\"type\", \"count\") as imprintsize, cast(8 * \"count\" as bigint) as orderidxsize, sorted, revsorted, \"unique\" from sys.storagemodelinput order by \"schema\", \"table\", \"column\";", "VIEW", true, "COMMIT", "WRITABLE" ] [ "sys", "storagemodelinput", NULL, "TABLE", true, "COMMIT", "WRITABLE" ] [ "sys", "systemfunctions", "create view sys.systemfunctions as select id as function_id from sys.functions where system;", "VIEW", true, "COMMIT", "WRITABLE" ] [ "sys", "table_partitions", NULL, "TABLE", true, "COMMIT", "WRITABLE" ] [ "sys", "table_types", NULL, "TABLE", true, "COMMIT", "READONLY" ] [ "sys", "tables", "SELECT \"id\", \"name\", \"schema_id\", \"query\", CAST(CASE WHEN \"system\" THEN \"type\" + 10 /* system table/view */ ELSE (CASE WHEN \"commit_action\" = 0 THEN \"type\" /* table/view */ ELSE \"type\" + 20 /* global temp table */ END) END AS SMALLINT) AS \"type\", \"system\", \"commit_action\", \"access\", CASE WHEN (NOT \"system\" AND \"commit_action\" > 0) THEN 1 ELSE 0 END AS \"temporary\" FROM \"sys\".\"_tables\" WHERE \"type\" <> 2 UNION ALL SELECT \"id\", \"name\", \"schema_id\", \"query\", CAST(\"type\" + 30 /* local temp table */ AS SMALLINT) AS \"type\", \"system\", \"commit_action\", \"access\", 1 AS \"temporary\" FROM \"tmp\".\"_tables\";", "VIEW", true, "COMMIT", "WRITABLE" ] -[ "sys", "tablestoragemodel", "create view sys.tablestoragemodel as select \"schema\",\"table\",max(count) as \"count\", sum(columnsize) as columnsize, sum(heapsize) as heapsize, sum(hashes) as hashes, sum(\"imprints\") as \"imprints\", sum(case when sorted = false then 8 * count else 0 end) as auxiliary from sys.storagemodel() group by \"schema\",\"table\";", "VIEW", true, "COMMIT", "WRITABLE" ] +[ "sys", "tablestorage", "create view sys.\"tablestorage\" as select \"schema\", \"table\", max(\"count\") as \"rowcount\", count(*) as \"storages\", sum(columnsize) as columnsize, sum(heapsize) as heapsize, sum(hashes) as hashsize, sum(\"imprints\") as imprintsize, sum(orderidx) as orderidxsize from sys.\"storage\"() group by \"schema\", \"table\" order by \"schema\", \"table\";", "VIEW", true, "COMMIT", "WRITABLE" ] +[ "sys", "tablestoragemodel", "create view sys.tablestoragemodel as select \"schema\", \"table\", max(\"count\") as \"rowcount\", count(*) as \"storages\", sum(columnsize(\"type\", \"count\", \"distinct\", \"atomwidth\")) as columnsize, sum(heapsize(\"type\", \"count\", \"distinct\", \"atomwidth\")) as heapsize, sum(hashsize(\"reference\", \"count\")) as hashsize, sum(imprintsize(\"type\", \"count\")) as imprintsize, sum(cast(8 * \"count\" as bigint)) as orderidxsize, sum(cast(case when sorted = false then 8 * \"count\" else 0 end as bigint)) as auxiliary from sys.storagemodelinput group by \"schema\", \"table\" order by \"schema\", \"table\";", "VIEW", true, "COMMIT", "WRITABLE" ] [ "sys", "tracelog", "create view sys.tracelog as select * from sys.tracelog();", "VIEW", true, "COMMIT", "WRITABLE" ] [ "sys", "triggers", NULL, "TABLE", true, "COMMIT", "WRITABLE" ] [ "sys", "types", NULL, "TABLE", true, "COMMIT", "WRITABLE" ] @@ -1894,6 +1899,13 @@ drop function pcre_replace(string, strin [ "schemas", "authorization", "int", 32, 0, NULL, true, 2, NULL ] [ "schemas", "owner", "int", 32, 0, NULL, true, 3, NULL ] [ "schemas", "system", "boolean", 1, 0, NULL, true, 4, NULL ] +[ "schemastorage", "schema", "varchar", 1024, 0, NULL, true, 0, NULL ] +[ "schemastorage", "storages", "bigint", 64, 0, NULL, true, 1, NULL ] +[ "schemastorage", "columnsize", "bigint", 64, 0, NULL, true, 2, NULL ] +[ "schemastorage", "heapsize", "bigint", 64, 0, NULL, true, 3, NULL ] +[ "schemastorage", "hashsize", "bigint", 64, 0, NULL, true, 4, NULL ] +[ "schemastorage", "imprintsize", "bigint", 64, 0, NULL, true, 5, NULL ] +[ "schemastorage", "orderidxsize", "bigint", 64, 0, NULL, true, 6, NULL ] [ "sequences", "id", "int", 32, 0, NULL, true, 0, NULL ] [ "sequences", "schema_id", "int", 32, 0, NULL, true, 1, NULL ] [ "sequences", "name", "varchar", 256, 0, NULL, true, 2, NULL ] @@ -1933,12 +1945,12 @@ drop function pcre_replace(string, strin [ "statistics", "maxval", "clob", 0, 0, NULL, true, 9, NULL ] [ "statistics", "sorted", "boolean", 1, 0, NULL, true, 10, NULL ] [ "statistics", "revsorted", "boolean", 1, 0, NULL, true, 11, NULL ] -[ "storage", "schema", "clob", 0, 0, NULL, true, 0, NULL ] -[ "storage", "table", "clob", 0, 0, NULL, true, 1, NULL ] -[ "storage", "column", "clob", 0, 0, NULL, true, 2, NULL ] -[ "storage", "type", "clob", 0, 0, NULL, true, 3, NULL ] -[ "storage", "mode", "clob", 0, 0, NULL, true, 4, NULL ] -[ "storage", "location", "clob", 0, 0, NULL, true, 5, NULL ] +[ "storage", "schema", "varchar", 1024, 0, NULL, true, 0, NULL ] +[ "storage", "table", "varchar", 1024, 0, NULL, true, 1, NULL ] +[ "storage", "column", "varchar", 1024, 0, NULL, true, 2, NULL ] +[ "storage", "type", "varchar", 1024, 0, NULL, true, 3, NULL ] +[ "storage", "mode", "varchar", 15, 0, NULL, true, 4, NULL ] +[ "storage", "location", "varchar", 1024, 0, NULL, true, 5, NULL ] [ "storage", "count", "bigint", 64, 0, NULL, true, 6, NULL ] [ "storage", "typewidth", "int", 32, 0, NULL, true, 7, NULL ] [ "storage", "columnsize", "bigint", 64, 0, NULL, true, 8, NULL ] @@ -1950,32 +1962,32 @@ drop function pcre_replace(string, strin [ "storage", "revsorted", "boolean", 1, 0, NULL, true, 14, NULL ] [ "storage", "unique", "boolean", 1, 0, NULL, true, 15, NULL ] [ "storage", "orderidx", "bigint", 64, 0, NULL, true, 16, NULL ] -[ "storagemodel", "schema", "clob", 0, 0, NULL, true, 0, NULL ] -[ "storagemodel", "table", "clob", 0, 0, NULL, true, 1, NULL ] -[ "storagemodel", "column", "clob", 0, 0, NULL, true, 2, NULL ] -[ "storagemodel", "type", "clob", 0, 0, NULL, true, 3, NULL ] +[ "storagemodel", "schema", "varchar", 1024, 0, NULL, true, 0, NULL ] +[ "storagemodel", "table", "varchar", 1024, 0, NULL, true, 1, NULL ] +[ "storagemodel", "column", "varchar", 1024, 0, NULL, true, 2, NULL ] +[ "storagemodel", "type", "varchar", 1024, 0, NULL, true, 3, NULL ] [ "storagemodel", "count", "bigint", 64, 0, NULL, true, 4, NULL ] [ "storagemodel", "columnsize", "bigint", 64, 0, NULL, true, 5, NULL ] [ "storagemodel", "heapsize", "bigint", 64, 0, NULL, true, 6, NULL ] -[ "storagemodel", "hashes", "bigint", 64, 0, NULL, true, 7, NULL ] -[ "storagemodel", "imprints", "bigint", 64, 0, NULL, true, 8, NULL ] -[ "storagemodel", "sorted", "boolean", 1, 0, NULL, true, 9, NULL ] -[ "storagemodel", "revsorted", "boolean", 1, 0, NULL, true, 10, NULL ] -[ "storagemodel", "unique", "boolean", 1, 0, NULL, true, 11, NULL ] -[ "storagemodel", "orderidx", "bigint", 64, 0, NULL, true, 12, NULL ] -[ "storagemodelinput", "schema", "clob", 0, 0, NULL, true, 0, NULL ] -[ "storagemodelinput", "table", "clob", 0, 0, NULL, true, 1, NULL ] -[ "storagemodelinput", "column", "clob", 0, 0, NULL, true, 2, NULL ] -[ "storagemodelinput", "type", "clob", 0, 0, NULL, true, 3, NULL ] -[ "storagemodelinput", "typewidth", "int", 32, 0, NULL, true, 4, NULL ] -[ "storagemodelinput", "count", "bigint", 64, 0, NULL, true, 5, NULL ] -[ "storagemodelinput", "distinct", "bigint", 64, 0, NULL, true, 6, NULL ] -[ "storagemodelinput", "atomwidth", "int", 32, 0, NULL, true, 7, NULL ] -[ "storagemodelinput", "reference", "boolean", 1, 0, NULL, true, 8, NULL ] +[ "storagemodel", "hashsize", "bigint", 64, 0, NULL, true, 7, NULL ] +[ "storagemodel", "imprintsize", "bigint", 64, 0, NULL, true, 8, NULL ] +[ "storagemodel", "orderidxsize", "bigint", 63, 0, NULL, true, 9, NULL ] +[ "storagemodel", "sorted", "boolean", 1, 0, NULL, true, 10, NULL ] +[ "storagemodel", "revsorted", "boolean", 1, 0, NULL, true, 11, NULL ] +[ "storagemodel", "unique", "boolean", 1, 0, NULL, true, 12, NULL ] +[ "storagemodelinput", "schema", "varchar", 1024, 0, NULL, false, 0, NULL ] +[ "storagemodelinput", "table", "varchar", 1024, 0, NULL, false, 1, NULL ] +[ "storagemodelinput", "column", "varchar", 1024, 0, NULL, false, 2, NULL ] +[ "storagemodelinput", "type", "varchar", 1024, 0, NULL, false, 3, NULL ] +[ "storagemodelinput", "typewidth", "int", 32, 0, NULL, false, 4, NULL ] +[ "storagemodelinput", "count", "bigint", 64, 0, NULL, false, 5, NULL ] +[ "storagemodelinput", "distinct", "bigint", 64, 0, NULL, false, 6, NULL ] +[ "storagemodelinput", "atomwidth", "int", 32, 0, NULL, false, 7, NULL ] +[ "storagemodelinput", "reference", "boolean", 1, 0, NULL, false, 8, NULL ] [ "storagemodelinput", "sorted", "boolean", 1, 0, NULL, true, 9, NULL ] [ "storagemodelinput", "revsorted", "boolean", 1, 0, NULL, true, 10, NULL ] [ "storagemodelinput", "unique", "boolean", 1, 0, NULL, true, 11, NULL ] -[ "storagemodelinput", "orderidx", "bigint", 64, 0, NULL, true, 12, NULL ] +[ "storagemodelinput", "orderidxsize", "bigint", 64, 0, NULL, false, 12, NULL ] [ "systemfunctions", "function_id", "int", 32, 0, NULL, true, 0, NULL ] [ "table_partitions", "id", "int", 32, 0, NULL, true, 0, NULL ] [ "table_partitions", "table_id", "int", 32, 0, NULL, true, 1, NULL ] @@ -1993,14 +2005,25 @@ drop function pcre_replace(string, strin [ "tables", "commit_action", "smallint", 16, 0, NULL, true, 6, NULL ] [ "tables", "access", "smallint", 16, 0, NULL, true, 7, NULL ] [ "tables", "temporary", "smallint", 16, 0, NULL, true, 8, NULL ] -[ "tablestoragemodel", "schema", "clob", 0, 0, NULL, true, 0, NULL ] -[ "tablestoragemodel", "table", "clob", 0, 0, NULL, true, 1, NULL ] -[ "tablestoragemodel", "count", "bigint", 64, 0, NULL, true, 2, NULL ] -[ "tablestoragemodel", "columnsize", "bigint", 64, 0, NULL, true, 3, NULL ] -[ "tablestoragemodel", "heapsize", "bigint", 64, 0, NULL, true, 4, NULL ] -[ "tablestoragemodel", "hashes", "bigint", 64, 0, NULL, true, 5, NULL ] -[ "tablestoragemodel", "imprints", "bigint", 64, 0, NULL, true, 6, NULL ] -[ "tablestoragemodel", "auxiliary", "bigint", 64, 0, NULL, true, 7, NULL ] +[ "tablestorage", "schema", "varchar", 1024, 0, NULL, true, 0, NULL ] +[ "tablestorage", "table", "varchar", 1024, 0, NULL, true, 1, NULL ] +[ "tablestorage", "rowcount", "bigint", 64, 0, NULL, true, 2, NULL ] +[ "tablestorage", "storages", "bigint", 64, 0, NULL, true, 3, NULL ] +[ "tablestorage", "columnsize", "bigint", 64, 0, NULL, true, 4, NULL ] +[ "tablestorage", "heapsize", "bigint", 64, 0, NULL, true, 5, NULL ] +[ "tablestorage", "hashsize", "bigint", 64, 0, NULL, true, 6, NULL ] +[ "tablestorage", "imprintsize", "bigint", 64, 0, NULL, true, 7, NULL ] +[ "tablestorage", "orderidxsize", "bigint", 64, 0, NULL, true, 8, NULL ] +[ "tablestoragemodel", "schema", "varchar", 1024, 0, NULL, true, 0, NULL ] +[ "tablestoragemodel", "table", "varchar", 1024, 0, NULL, true, 1, NULL ] +[ "tablestoragemodel", "rowcount", "bigint", 64, 0, NULL, true, 2, NULL ] +[ "tablestoragemodel", "storages", "bigint", 64, 0, NULL, true, 3, NULL ] +[ "tablestoragemodel", "columnsize", "bigint", 64, 0, NULL, true, 4, NULL ] +[ "tablestoragemodel", "heapsize", "bigint", 64, 0, NULL, true, 5, NULL ] +[ "tablestoragemodel", "hashsize", "bigint", 64, 0, NULL, true, 6, NULL ] +[ "tablestoragemodel", "imprintsize", "bigint", 64, 0, NULL, true, 7, NULL ] +[ "tablestoragemodel", "orderidxsize", "bigint", 64, 0, NULL, true, 8, NULL ] +[ "tablestoragemodel", "auxiliary", "bigint", 64, 0, NULL, true, 9, NULL ] [ "tracelog", "event", "int", 32, 0, NULL, true, 0, NULL ] [ "tracelog", "clk", "varchar", 20, 0, NULL, true, 1, NULL ] [ "tracelog", "pc", "varchar", 50, 0, NULL, true, 2, NULL ] @@ -2076,7 +2099,7 @@ drop function pcre_replace(string, strin % .s, .f, .L4, .L6, .f, .fl, .ft, .f, .f, .f, .L16, .L20, .L22, .L24, .L26, .L30, .L32, .L34, .L36, .L40, .L42, .L44, .L46, .L50, .L52, .L54, .L56, .L60, .L62, .L64, .L66, .L70, .L72, .L74, .L76, .L100, .L102, .L104, .L106, .L110, .L112, .L114, .L116, .L120, .L122, .L124, .L126, .L130, .L132, .L134, .L136, .L140, .L142, .L144, .L146, .L150, .L152, .L154, .L156, .L160, .L162, .L164, .L166, .L170, .L172, .L174, .L176, .L200, .L202, .L204, .L206, .L210, .L212, .L214, .L216, .L220, .L222, .L224, .L226, .L230, .L232, .L234, .L236, .L240, .L242, .L244, .L246, .L250, .L252, .L254 # table_name % name, name, system, query, mod, language_name, function_type_name, side_effect, varres, vararg, name0, type0, type_digits0, type_scale0, inout0, name1, type1, type_digits1, type_scale1, inout1, name2, type2, type_digits2, type_scale2, inout2, name3, type3, type_digits3, type_scale3, inout3, name4, type4, type_digits4, type_scale4, inout4, name5, type5, type_digits5, type_scale5, inout5, name6, type6, type_digits6, type_scale6, inout6, name7, type7, type_digits7, type_scale7, inout7, name8, type8, type_digits8, type_scale8, inout8, name9, type9, type_digits9, type_scale9, inout9, name10, type10, type_digits10, type_scale10, inout10, name11, type11, type_digits11, type_scale11, inout11, name12, type12, type_digits12, type_scale12, inout12, name13, type13, type_digits13, type_scale13, inout13, name14, type14, type_digits14, type_scale14, inout14, name15, type15, type_digits15, type_scale15, inout15 # name % varchar, varchar, char, varchar, varchar, varchar, varchar, boolean, boolean, boolean, varchar, varchar, int, int, char, varchar, varchar, int, int, char, varchar, varchar, int, int, char, varchar, varchar, int, int, char, varchar, varchar, int, int, char, varchar, varchar, int, int, char, varchar, varchar, int, int, char, varchar, varchar, int, int, char, varchar, varchar, int, int, char, varchar, varchar, int, int, char, varchar, varchar, int, int, char, varchar, varchar, int, int, char, varchar, varchar, int, int, char, varchar, varchar, int, int, char, varchar, varchar, int, int, char, varchar, varchar, int, int, char # type -% 8, 24, 6, 831, 9, 10, 26, 5, 5, 5, 11, 14, 4, 1, 3, 16, 14, 4, 1, 3, 16, 14, 2, 1, 3, 27, 12, 2, 1, 3, 12, 7, 2, 1, 3, 10, 7, 2, 1, 3, 8, 7, 2, 1, 3, 9, 6, 2, 1, 3, 10, 6, 2, 1, 3, 8, 7, 2, 1, 3, 9, 7, 2, 1, 3, 6, 7, 2, 1, 3, 8, 6, 2, 1, 3, 6, 7, 1, 1, 3, 9, 7, 1, 1, 3, 6, 7, 1, 1, 3 # length +% 8, 24, 6, 991, 9, 10, 26, 5, 5, 5, 11, 14, 4, 1, 3, 16, 14, 4, 1, 3, 16, 14, 4, 1, 3, 27, 12, 4, 1, 3, 12, 7, 2, 1, 3, 10, 7, 4, 1, 3, 8, 7, 2, 1, 3, 9, 6, 2, 1, 3, 10, 6, 2, 1, 3, 8, 6, 2, 1, 3, 6, 6, 2, 1, 3, 6, 7, 2, 1, 3, 8, 6, 2, 1, 3, 6, 7, 1, 1, 3, 9, 7, 1, 1, 3, 6, 7, 1, 1, 3 # length [ "bam", "bam_drop_file", "SYSTEM", "create procedure bam.bam_drop_file(file_id bigint, dbschema smallint) external name bam.bam_drop_file;", "bam", "MAL", "Procedure", true, false, false, "file_id", "bigint", 64, 0, "in", "dbschema", "smallint", 16, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] [ "bam", "bam_export", "SYSTEM", "create procedure bam.bam_export(output_path string) external name bam.bam_export;", "bam", "MAL", "Procedure", true, false, false, "output_path", "clob", 0, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] [ "bam", "bam_flag", "SYSTEM", "create function bam.bam_flag(flag smallint, name string) returns boolean external name bam.bam_flag;", "bam", "MAL", "Scalar function", false, false, false, "result", "boolean", 1, 0, "out", "flag", "smallint", 16, 0, "in", "name", "clob", 0, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] @@ -2217,7 +2240,7 @@ drop function pcre_replace(string, strin [ "sys", "code", "SYSTEM", "unicode", "str", "Internal C", "Scalar function", false, false, false, "res_0", "char", 0, 0, "out", "arg_1", "int", 32, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] [ "sys", "code", "SYSTEM", "unicode", "str", "Internal C", "Scalar function", false, false, false, "res_0", "clob", 0, 0, "out", "arg_1", "int", 32, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] [ "sys", "code", "SYSTEM", "unicode", "str", "Internal C", "Scalar function", false, false, false, "res_0", "varchar", 0, 0, "out", "arg_1", "int", 32, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] -[ "sys", "columnsize", "SYSTEM", "create function sys.columnsize(nme string, i bigint, d bigint) returns bigint begin case when nme = 'boolean' then return i; when nme = 'char' then return 2*i; when nme = 'smallint' then return 2 * i; when nme = 'int' then return 4 * i; when nme = 'bigint' then return 8 * i; when nme = 'hugeint' then return 16 * i; when nme = 'timestamp' then return 8 * i; when nme = 'varchar' then case when cast(d as bigint) << 8 then return i; when cast(d as bigint) << 16 then return 2 * i; when cast(d as bigint) << 32 then return 4 * i; else return 8 * i; end case; else return 8 * i; end case; end;", "user", "SQL", "Scalar function", false, false, false, "result", "bigint", 64, 0, "out", "nme", "clob", 0, 0, "in", "i", "bigint", 64, 0, "in", "d", "bigint", 64, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] +[ "sys", "columnsize", "SYSTEM", "create function sys.columnsize(tpe varchar(1024), count bigint, _distinct bigint, avgwidth int) returns bigint begin if tpe = 'tinyint' or tpe = 'boolean' then return count; end if; if tpe = 'smallint' then return 2 * count; end if; if tpe = 'int' or tpe = 'real' or tpe = 'date' or tpe = 'time' or tpe = 'timetz' or tpe = 'sec_interval' or tpe = 'month_interval' then return 4 * count; end if; if tpe = 'bigint' or tpe = 'decimal' or tpe = 'double' or tpe = 'timestamp' or tpe = 'timestamptz' or tpe = 'inet' or tpe = 'oid' then return 8 * count; end if; if tpe = 'hugeint' or tpe = 'uuid' then return 16 * count; end if; if tpe = 'varchar' or tpe = 'char' or tpe = 'clob' or tpe = 'json' or tpe = 'url' then return sys.sql_max(4 * count, 8192 + ((avgwidth + 8) * _distinct)); end if; if tpe = 'blob' then return (avgwidth + 8) * count; end if; return 16 * count; end;", "user", "SQL", "Scalar function", false, false, false, "result", "bigint", 64, 0, "out", "t pe", "varchar", 1024, 0, "in", "count", "bigint", 64, 0, "in", "_distinct", "bigint", 64, 0, "in", "avgwidth", "int", 32, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] [ "sys", "concat", "SYSTEM", "+", "calc", "Internal C", "Scalar function", false, false, false, "res_0", "char", 0, 0, "out", "arg_1", "char", 0, 0, "in", "arg_2", "char", 0, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] [ "sys", "concat", "SYSTEM", "+", "calc", "Internal C", "Scalar function", false, false, false, "res_0", "clob", 0, 0, "out", "arg_1", "clob", 0, 0, "in", "arg_2", "clob", 0, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] [ "sys", "concat", "SYSTEM", "+", "calc", "Internal C", "Scalar function", false, false, false, "res_0", "varchar", 0, 0, "out", "arg_1", "varchar", 0, 0, "in", "arg_2", "varchar", 0, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] @@ -2319,8 +2342,8 @@ drop function pcre_replace(string, strin [ "sys", "has_m", "SYSTEM", "create function has_m(info integer) returns integer external name geom.\"hasM\";", "geom", "MAL", "Scalar function", false, false, false, "result", "int", 32, 0, "out", "info", "int", 32, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] [ "sys", "has_z", "SYSTEM", "create function has_z(info integer) returns integer external name geom.\"hasZ\";", "geom", "MAL", "Scalar function", false, false, false, "result", "int", 32, 0, "out", "info", "int", 32, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] [ "sys", "hash", "SYSTEM", "hash", "mkey", "Internal C", "Scalar function", false, false, false, "res_0", "bigint", 64, 0, "out", "arg_1", "any", 0, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] -[ "sys", "hashsize", "SYSTEM", "create function sys.hashsize(b boolean, i bigint) returns bigint begin if b = true then return 8 * i; end if; return 0; end;", "user", "SQL", "Scalar function", false, false, false, "result", "bigint", 64, 0, "out", "b", "boolean", 1, 0, "in", "i", "bigint", 64, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] -[ "sys", "heapsize", "SYSTEM", "create function sys.heapsize(tpe string, i bigint, w int) returns bigint begin if tpe <> 'varchar' and tpe <> 'clob' then return 0; end if; return 10240 + i * w; end;", "user", "SQL", "Scalar function", false, false, false, "result", "bigint", 64, 0, "out", "tpe", "clob", 0, 0, "in", "i", "bigint", 64, 0, "in", "w", "int", 32, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] +[ "sys", "hashsize", "SYSTEM", "create function sys.hashsize(b boolean, count bigint) returns bigint begin if b = true then return 8 * count; end if; return 0; end;", "user", "SQL", "Scalar function", false, false, false, "result", "bigint", 64, 0, "out", "b", "boolean", 1, 0, "in", "count", "bigint", 64, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] +[ "sys", "heapsize", "SYSTEM", "create function sys.heapsize(tpe varchar(1024), count bigint, _distinct bigint, avgwidth int) returns bigint begin if tpe = 'varchar' or tpe = 'char' or tpe = 'clob' or tpe = 'json' or tpe = 'url' then return 8192 + ((avgwidth + 8) * _distinct); end if; if tpe = 'blob' then return (avgwidth + 8) * count; end if; return 0; end;", "user", "SQL", "Scalar function", false, false, false, "result", "bigint", 64, 0, "out", "tpe", "varchar", 1024, 0, "in", "count", "bigint", 64, 0, "in", "_distinct", "bigint", 64, 0, "in", "avgwidth", "int", 32, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] [ "sys", "host", "SYSTEM", "create function \"host\" (p inet) returns clob external name inet.\"host\";", "inet", "MAL", "Scalar function", false, false, false, "result", "clob", 0, 0, "out", "p", "inet", 0, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] [ "sys", "hostmask", "SYSTEM", "create function \"hostmask\" (p inet) returns inet external name inet.\"hostmask\";", "inet", "MAL", "Scalar function", false, false, false, "result", "inet", 0, 0, "out", "p", "inet", 0, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] [ "sys", "hour", "SYSTEM", "hours", "mtime", "Internal C", "Scalar function", false, false, false, "res_0", "int", 32, 0, "out", "arg_1", "sec_interval", 13, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] @@ -2332,7 +2355,7 @@ drop function pcre_replace(string, strin [ "sys", "ifthenelse", "SYSTEM", "ifthenelse", "calc", "Internal C", "Scalar function", false, false, false, "res_0", "any", 0, 0, "out", "arg_1", "boolean", 1, 0, "in", "arg_2", "any", 0, 0, "in", "arg_3", "any", 0, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] [ "sys", "ilike", "SYSTEM", "create filter function \"ilike\"(val string, pat string) external name algebra.\"ilike\";", "algebra", "MAL", "Filter function", false, false, false, "val", "clob", 0, 0, "in", "pat", "clob", 0, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] [ "sys", "ilike", "SYSTEM", "create filter function \"ilike\"(val string, pat string, esc string) external name algebra.\"ilike\";", "algebra", "MAL", "Filter function", false, false, false, "val", "clob", 0, 0, "in", "pat", "clob", 0, 0, "in", "esc", "clob", 0, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] -[ "sys", "imprintsize", "SYSTEM", "create function sys.imprintsize(i bigint, nme string) returns bigint begin if nme = 'boolean' or nme = 'tinyint' or nme = 'smallint' or nme = 'int' or nme = 'bigint' or nme = 'hugeint' or nme = 'decimal' or nme = 'date' or nme = 'timestamp' or nme = 'real' or nme = 'double' then return cast(i * 0.12 as bigint); end if ; return 0; end;", "user", "SQL", "Scalar function", false, false, false, "result", "bigint", 64, 0, "out", "i", "bigint", 64, 0, "in", "nme", "clob", 0, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] +[ "sys", "imprintsize", "SYSTEM", "create function sys.imprintsize(tpe varchar(1024), count bigint) returns bigint begin if tpe = 'tinyint' or tpe = 'boolean' then return cast(0.2 * count as bigint); end if; if tpe = 'smallint' then return cast(0.4 * count as bigint); end if; if tpe = 'int' or tpe = 'real' or tpe = 'date' or tpe = 'time' or tpe = 'timetz' or tpe = 'sec_interval' or tpe = 'month_interval' then return cast(0.8 * count as bigint); end if; if tpe = 'bigint' or tpe = 'double' or tpe = 'timestamp' or tpe = 'timestamptz' or tpe = 'oid' then return cast(1.6 * count as bigint); end if; if tpe = 'hugeint' or tpe = 'decimal' then return cast(3.2 * count as bigint); end if; return 0; end;", "user", "SQL", "Scalar function", false, false, false, "result", "bigint", 64, 0, "out", "tpe", "varchar", 1024, 0, "in", "count", "bigint", 64, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] [ "sys", "in", "SYSTEM", "in", "calc", "Internal C", "Scalar function", false, false, false, "res_0", "boolean", 1, 0, "out", "arg_1", "any", 0, 0, "in", "arg_2", "any", 0, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] [ "sys", "index", "SYSTEM", "index", "calc", "Internal C", "Scalar function", false, false, false, "res_0", "int", 32, 0, "out", "arg_1", "char", 0, 0, "in", "arg_2", "boolean", 1, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] [ "sys", "index", "SYSTEM", "index", "calc", "Internal C", "Scalar function", false, false, false, "res_0", "int", 32, 0, "out", "arg_1", "clob", 0, 0, "in", "arg_2", "boolean", 1, 0, "in", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL ] _______________________________________________ checkin-list mailing list checkin-list@monetdb.org https://www.monetdb.org/mailman/listinfo/checkin-list