2024年4月2日

摘要: 背景 Oracle 的 Raw 类型可以进行位操作,在 lightdb 24.1 中,对其中的函数:bit_and, bit_or, bit_xor, bit_complement 四个函数进行了改进:这些函数有了 strict 属性,即输入参数如果有 null, 则直接返回 null。 用例 bi 阅读全文
posted @ 2024-04-02 20:42 winter-loo 阅读(12) 评论(0) 推荐(0) 编辑

2024年3月26日

摘要: SQL CREATE TABLE measurement ( city_id int not null, logdate date not null, data text ) PARTITION BY RANGE (logdate); CREATE TABLE p1 PARTITION OF mea 阅读全文
posted @ 2024-03-26 00:33 winter-loo 阅读(10) 评论(0) 推荐(0) 编辑

2024年3月23日

摘要: Overview In this article, I will inspect the postgresql code to find out the implementation of alter table command, specifically, the add column subco 阅读全文
posted @ 2024-03-23 18:37 winter-loo 阅读(3) 评论(0) 推荐(0) 编辑

2024年3月12日

摘要: 背景 Oracle 的 timestamp_to_scn 函数能根据时间戳返回一个 SCN(System Change Number). scn 与事务有关,当系统有事务提交后,最新的 scn 就会变更成一个更大的值。 ORA_ROWSCN 在 Oracle 中记录了每一行提交后的 scn. 在 L 阅读全文
posted @ 2024-03-12 16:17 winter-loo 阅读(17) 评论(0) 推荐(0) 编辑

2024年3月8日

摘要: The SQL select xmin::text::int8; grammar a_expr: a_expr TYPECAST Typename { $$ = makeTypeCast($1, $3, @2); } static Node * makeTypeCast(Node *arg, Typ 阅读全文
posted @ 2024-03-08 09:20 winter-loo 阅读(3) 评论(0) 推荐(0) 编辑

2024年3月6日

摘要: 开启行级别改变记录 create table foo3(a int) rowdependencies; 插入数据 insert into foo3 values (1); insert into foo3 values (2); -- 结果为 null select ora_rowscn from 阅读全文
posted @ 2024-03-06 15:42 winter-loo 阅读(7) 评论(0) 推荐(0) 编辑

2024年2月29日

摘要: ![image](https://img2024.cnblogs.com/blog/731236/202402/731236-20240229204346235-1972136754.png) 阅读全文
posted @ 2024-02-29 20:44 winter-loo 阅读(2) 评论(0) 推荐(0) 编辑

2024年2月22日

摘要: 背景 Oracle 的 create view 语句可以带有 WITH READ ONLY 选项。为了使 Oracle 的 sql 代码更方便迁移到 LightDB 中,24.1 版本中新增了 WITH READ ONLY 语法。目前用户不能在只读视图上执行 update/insert 操作更新基表 阅读全文
posted @ 2024-02-22 15:58 winter-loo 阅读(5) 评论(0) 推荐(0) 编辑

2024年2月21日

摘要: 背景 lightdb 为兼容 Oracle 的存储过程创建了 plorsql 核心插件。在 lightdb 23.4 及之前版本,plorasql 存储过程只支持基本的语法校验(check_function_bodies = on 时)。从 lightdb 24.1 版本开始,lightdb 新增 阅读全文
posted @ 2024-02-21 18:11 winter-loo 阅读(4) 评论(0) 推荐(0) 编辑

2024年2月6日

摘要: based on postgres commit b96115acb8a0e08a46877c2b8ef2a7b5560b371b The SQL CREATE OR REPLACE FUNCTION demo_fors() RETURNS VOID AS $$ DECLARE a RECORD; 阅读全文
posted @ 2024-02-06 12:10 winter-loo 阅读(7) 评论(0) 推荐(0) 编辑

导航