The values assigned to INV_WRITE and INV_READ were reversed in the
tests, which would be confusing when writing tests specific to read or
write operations on LOs.
Author: Yugo Nagata
Discussion: https://postgr.es/m/
20220527153028.
61a4608f66abcd026fd3806f@sraoss.co.jp
BEGIN;
-- lo_open(lobjId oid, mode integer) returns integer
-- The mode parameter to lo_open uses two constants:
--- INV_READ = 0x20000
--- INV_WRITE = 0x40000
+-- INV_WRITE = 0x20000
+-- INV_READ = 0x40000
-- The return value is a file descriptor-like value which remains valid for the
-- transaction.
UPDATE lotest_stash_values SET fd = lo_open(loid, CAST(x'20000' | x'40000' AS integer));
BEGIN;
-- lo_open(lobjId oid, mode integer) returns integer
-- The mode parameter to lo_open uses two constants:
--- INV_READ = 0x20000
--- INV_WRITE = 0x40000
+-- INV_WRITE = 0x20000
+-- INV_READ = 0x40000
-- The return value is a file descriptor-like value which remains valid for the
-- transaction.
UPDATE lotest_stash_values SET fd = lo_open(loid, CAST(x'20000' | x'40000' AS integer));
-- lo_open(lobjId oid, mode integer) returns integer
-- The mode parameter to lo_open uses two constants:
--- INV_READ = 0x20000
--- INV_WRITE = 0x40000
+-- INV_WRITE = 0x20000
+-- INV_READ = 0x40000
-- The return value is a file descriptor-like value which remains valid for the
-- transaction.
UPDATE lotest_stash_values SET fd = lo_open(loid, CAST(x'20000' | x'40000' AS integer));