Skip to content

Commit

Permalink
chore: add name column back in pg_user for backward compatibility (#1…
Browse files Browse the repository at this point in the history
  • Loading branch information
yezizp2012 authored Feb 26, 2024
1 parent 1eec69e commit e10c687
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion e2e_test/batch/catalog/pg_user.slt.part
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
query ITTT
SELECT * FROM pg_catalog.pg_user order by usesysid;
SELECT usesysid, usename, usecreatedb, usesuper, passwd FROM pg_catalog.pg_user order by usesysid;
----
1 root t t ********
2 postgres t t ********
2 changes: 2 additions & 0 deletions src/frontend/src/catalog/system_catalog/pg_catalog/pg_user.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ use risingwave_frontend_macro::system_catalog;
"pg_catalog.pg_user",
"SELECT id AS usesysid,
name,
name AS usename,
create_db AS usecreatedb,
is_super AS usesuper,
'********' AS passwd
Expand All @@ -30,6 +31,7 @@ use risingwave_frontend_macro::system_catalog;
#[derive(Fields)]
struct PgUser {
usesysid: i32,
name: String, // FIXME: For backward compatibility, remove it when the cloud update it.
usename: String,
usecreatedb: bool,
usesuper: bool,
Expand Down

0 comments on commit e10c687

Please sign in to comment.