Is it possible to create a global alias for a table in psql?

Viewed 664

We have a table called Table1, and we want to create an alias for it, e.g. Table2, so that in any query it is understood as Table1. Is it possible in psql?

1 Answers

You can use a view:

create view table2 as
     select * from table1;
Related