doc/development/postgresql_vfs_testdata.sql

Tue, 01 Feb 2022 20:07:42 +0100

author
Olaf Wintermann <olaf.wintermann@gmail.com>
date
Tue, 01 Feb 2022 20:07:42 +0100
branch
webdav
changeset 282
cfb588e27198
parent 281
e9dc53661df4
child 283
25e5b771677d
permissions
-rw-r--r--

add support for getstat parameter in pg readdir

278
38bf7b42b58c implement pg_vfs_open
Olaf Wintermann <olaf.wintermann@gmail.com>
parents:
diff changeset
1
281
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
2 do $$
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
3 declare
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
4 res_id int;
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
5 begin
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
6 insert into Resource (nodename, iscollection) values ('', true);
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
7 res_id := lastval();
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
8
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
9 insert into Resource(parent_id, nodename) values
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
10 (res_id, 'file1.txt'),
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
11 (res_id, 'file2.txt'),
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
12 (res_id, 'file3.txt'),
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
13 (res_id, 'file4.txt');
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
14
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
15 insert into Resource(parent_id, nodename, iscollection) values
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
16 (res_id, 'dir1', true);
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
17 res_id := lastval();
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
18
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
19 insert into Resource(parent_id, nodename, iscollection) values
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
20 (res_id, 'dir2', true);
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
21 res_id := lastval();
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
22
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
23 insert into Resource(parent_id, nodename) values
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
24 (res_id, 'd1file1.txt'),
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
25 (res_id, 'd2file1.txt'),
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
26 (res_id, 'd2file2.txt');
278
38bf7b42b58c implement pg_vfs_open
Olaf Wintermann <olaf.wintermann@gmail.com>
parents:
diff changeset
27
281
e9dc53661df4 add pg vfs stat/fstat implementation
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 278
diff changeset
28 end $$;
278
38bf7b42b58c implement pg_vfs_open
Olaf Wintermann <olaf.wintermann@gmail.com>
parents:
diff changeset
29

mercurial