1
0
This commit is contained in:
2025-11-04 21:34:48 +08:00
parent afaa00c056
commit ed8630d100
2 changed files with 33 additions and 0 deletions

View File

@@ -24,3 +24,14 @@ ALTER DATABASE kt_shop REFRESH COLLATION VERSION;
-- 重置某表的某列的自增序列 [表名]_[列名]_seq
ALTER SEQUENCE person_id_seq RESTART WITH 4284858;
-- ctid 会返回一个元组,元组中第一个数字是 page number, 第二个是 slot number。
select r.ctid, r.* from study.r;
-- 得到
-- "(0,1)",1,101
-- "(0,2)",2,102
-- "(0,3)",3,103
-- 删除一条
delete from study.r where id = 101;
-- 得到