Closed jchappelow closed 1 day ago
Alternative to https://github.com/kwilteam/kwil-db/pull/1088 Resolves https://github.com/kwilteam/kwil-db/issues/1084
action get_post($id) public view { SELECT *, @block_timestamp as stamp, @height as height FROM posts WHERE id = $id; }
$ kwil-cli database call -i xc4503ccf15daada96e36cbbacf641f48ebc6226e28906c8757866b91 -a get_post 'id:3' | content | height | id | stamp | title | user_id | +---------+--------+----+------------+--------+---------+ | hihi | 842 | 3 | 1732569623 | title2 | 1 | $ kwil-cli database call -i xc4503ccf15daada96e36cbbacf641f48ebc6226e28906c8757866b91 -a get_post 'id:3' | content | height | id | stamp | title | user_id | +---------+--------+----+------------+--------+---------+ | hihi | 843 | 3 | 1732569630 | title2 | 1 |
@jchappelow could you also backport to preview?
preview
Sure, just a sec.
Alternative to https://github.com/kwilteam/kwil-db/pull/1088 Resolves https://github.com/kwilteam/kwil-db/issues/1084