Skip to content

Commit

Permalink
fix GetColumns script (#1681)
Browse files Browse the repository at this point in the history
fix this issue: #1680
  • Loading branch information
exitxhu authored May 7, 2024
1 parent eae0f32 commit 9967be5
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion flow/cmd/peer_data.go
Original file line number Diff line number Diff line change
Expand Up @@ -205,11 +205,13 @@ func (h *FlowRequestHandler) GetColumns(
pg_attribute
JOIN
pg_class ON pg_attribute.attrelid = pg_class.oid
JOIN
pg_namespace on pg_class.relnamespace = pg_namespace.oid
LEFT JOIN
pg_constraint ON pg_attribute.attrelid = pg_constraint.conrelid
AND pg_attribute.attnum = ANY(pg_constraint.conkey)
WHERE
relnamespace::regnamespace::text = $1
pg_namespace.nspname = $1
AND
relname = $2
AND pg_attribute.attnum > 0
Expand Down

0 comments on commit 9967be5

Please sign in to comment.