diff options
author | udovichenko-r <udovichenko-r@yandex-team.com> | 2024-11-19 14:11:52 +0300 |
---|---|---|
committer | udovichenko-r <udovichenko-r@yandex-team.com> | 2024-11-19 14:22:01 +0300 |
commit | 72b3cd51dc3fb9d16975d353ea82fd85701393cc (patch) | |
tree | 318141940b8bf6bdb37ad6154e745e2ebfe3613f /yql/essentials/tests/postgresql/original/cases/oid.sql | |
parent | 223625eed56ec3e2808c010eac46dba1c9a64d13 (diff) | |
download | ydb-72b3cd51dc3fb9d16975d353ea82fd85701393cc.tar.gz |
YQL-19206 Move contrib/ydb/library/yql/tests/postgresql -> yql/essentials/tests/postgresql
commit_hash:46fdf59714b20cf2b61233a06e58365227d3c8b2
Diffstat (limited to 'yql/essentials/tests/postgresql/original/cases/oid.sql')
-rw-r--r-- | yql/essentials/tests/postgresql/original/cases/oid.sql | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/yql/essentials/tests/postgresql/original/cases/oid.sql b/yql/essentials/tests/postgresql/original/cases/oid.sql new file mode 100644 index 0000000000..25b4b68a6a --- /dev/null +++ b/yql/essentials/tests/postgresql/original/cases/oid.sql @@ -0,0 +1,43 @@ +-- +-- OID +-- + +CREATE TABLE OID_TBL(f1 oid); + +INSERT INTO OID_TBL(f1) VALUES ('1234'); +INSERT INTO OID_TBL(f1) VALUES ('1235'); +INSERT INTO OID_TBL(f1) VALUES ('987'); +INSERT INTO OID_TBL(f1) VALUES ('-1040'); +INSERT INTO OID_TBL(f1) VALUES ('99999999'); +INSERT INTO OID_TBL(f1) VALUES ('5 '); +INSERT INTO OID_TBL(f1) VALUES (' 10 '); +-- leading/trailing hard tab is also allowed +INSERT INTO OID_TBL(f1) VALUES (' 15 '); + +-- bad inputs +INSERT INTO OID_TBL(f1) VALUES (''); +INSERT INTO OID_TBL(f1) VALUES (' '); +INSERT INTO OID_TBL(f1) VALUES ('asdfasd'); +INSERT INTO OID_TBL(f1) VALUES ('99asdfasd'); +INSERT INTO OID_TBL(f1) VALUES ('5 d'); +INSERT INTO OID_TBL(f1) VALUES (' 5d'); +INSERT INTO OID_TBL(f1) VALUES ('5 5'); +INSERT INTO OID_TBL(f1) VALUES (' - 500'); +INSERT INTO OID_TBL(f1) VALUES ('32958209582039852935'); +INSERT INTO OID_TBL(f1) VALUES ('-23582358720398502385'); + +SELECT * FROM OID_TBL; + +SELECT o.* FROM OID_TBL o WHERE o.f1 = 1234; + +SELECT o.* FROM OID_TBL o WHERE o.f1 <> '1234'; + +SELECT o.* FROM OID_TBL o WHERE o.f1 <= '1234'; + +SELECT o.* FROM OID_TBL o WHERE o.f1 < '1234'; + +SELECT o.* FROM OID_TBL o WHERE o.f1 >= '1234'; + +SELECT o.* FROM OID_TBL o WHERE o.f1 > '1234'; + +DROP TABLE OID_TBL; |