You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: java/connector-node/risingwave-connector-service/src/main/java/com/risingwave/sourcenode/SourceRequestHandler.java
Copy file name to clipboardExpand all lines: java/connector-node/risingwave-connector-service/src/main/resources/validate_sql.properties
+25Lines changed: 25 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -8,3 +8,28 @@ postgres.table=SELECT EXISTS ( SELECT FROM pg_tables WHERE schemaname = ? AND ta
8
8
postgres.pk=SELECT a.attname, format_type(a.atttypid, a.atttypmod) AS data_type FROM pg_index i JOIN pg_attribute a ON a.attrelid = i.indrelid AND a.attnum = ANY(i.indkey) WHERE i.indrelid = ?::regclass AND i.indisprimary
9
9
postgres.table_schema=SELECT column_name, data_type FROM information_schema.columns WHERE table_schema = ? AND table_name = ? ORDER BY ordinal_position
10
10
postgres.slot.check=SELECT slot_name FROM pg_replication_slots WHERE slot_name = ?
11
+
postgres.role.check=SELECT rolreplication OR rolsuper FROM pg_roles WHERE rolname = ?
12
+
postgres.database_privilege.check=SELECT has_database_privilege(?, ?, 'create') FROM pg_roles WHERE rolname = ?
13
+
postgres.table_privilege.check=SELECT (COUNT(*) = 1) FROM information_schema.role_table_grants WHERE table_name = ? AND grantee = ? and privilege_type = 'SELECT'
14
+
postgres.table_owner=SELECT tableowner FROM pg_tables WHERE schemaname = ? and tablename = ?
15
+
postgres.publication_att_exists=SELECT count(*) > 0 FROM information_schema.columns WHERE table_name = 'pg_publication_tables' AND column_name = 'attnames'
16
+
postgres.publication_att=SELECT attnames FROM pg_publication_tables WHERE schemaname = ? AND tablename = ? AND pubname = 'dbz_publication'
17
+
postgres.publication_cnt=SELECT COUNT(*) AS count FROM pg_publication_tables WHERE schemaname = ? AND tablename = ? AND pubname = 'dbz_publication'
18
+
postgres.users_of_group=WITH RECURSIVE base (g, m) AS (( \
19
+
SELECT r1.rolname as group, ARRAY_AGG(DISTINCT(r2.rolname)) as members FROM pg_auth_members am \
20
+
INNER JOIN pg_roles r1 ON r1.oid = am.roleid \
21
+
INNER JOIN pg_roles r2 ON r2.oid = am.member \
22
+
WHERE r1.rolname = ? \
23
+
GROUP BY r1.rolname \
24
+
) \
25
+
UNION ALL ( \
26
+
WITH groups AS (SELECT DISTINCT(UNNEST(m)) AS g FROM base) \
27
+
SELECT r1.rolname as group, ARRAY_AGG(DISTINCT(r2.rolname)) as members FROM pg_auth_members am \
28
+
INNER JOIN pg_roles r1 ON r1.oid = am.roleid \
29
+
INNER JOIN pg_roles r2 ON r2.oid = am.member \
30
+
INNER JOIN groups ON r1.rolname = groups.g \
31
+
GROUP BY r1.rolname \
32
+
) \
33
+
), \
34
+
tmp AS (SELECT DISTINCT(UNNEST(m)) AS members FROM base) \
0 commit comments