sql
-
双引号包裹字段名,表名;否则默认会转成大写
-
query & insert
-- example
INSERT INTO "BASICAIRLINES"("ID", "gfid") VALUES (1, 2);
SELECT COUNT(*) FROM "xxx" LIMIT 10;
- modify field
ALTER TABLE "public"."flightleg_statistics" ALTER COLUMN "ID" TYPE VARCHAR(32);
ALTER TABLE "public"."flightleg_statistics" ADD COLUMN "GFID" VARCHAR(32) NULL;
- function
string1 || string2
substring(from x for y) : [x, x+y)
lower(xx)
upper(xx)
bit_length(xx)
char_length(xx)
character_length()
length(xx)
cast(xx as integer)