Wednesday, May 4, 2022

PostgreSQL \d commands versus MySQL's SHOW commands

One type of databases is pretty much the same as any other type of database base, right? 

Well, at one high abstract level that may be true.  But at the level where you have to use the database then things can be radically different.  

For the past several years I have mainly bee focusing on MySQL but my new job is letting me explore PostgreSQL.  I have used PostgreSQL in the past but it has been over a decade since I have done any production work.  And as such I am re-learning some basic commands.

When using the MySQL cli or shell I am used to typing SHOW SCHEMAS; or SHOW DATABASES; when I want to know which schemas/databases are on a given server.  PostgreSQL's psql uses \l.

There are an entire series of \d commands. A \d by itself shows the tables, sequences, and views in a schema.  You use \dt to see the tables, \ds to see the sequences, and \dv to see the views. And \du displays the users.

MySQL uses \g at the end of the command to mark the end of the SQL while in PostgreSQL \g by itself executes the last command. 

And you can have that output in an aligned format or unaligned by toggling the \a command or use \H to see the output in HTML.

Friday, April 22, 2022

Percona Live 2022 Tutorials

 

Looking to get smarter? Well, Percona Live is next month in Austin and there is a full day of tutorials just waiting for you in Austin.  And I hope to see you there!


Monday, May 16
 

9:00am CDT

1:30pm CDT

 

PostgreSQL Sessions at Percona Live

 I hope to see you next month in Austin at Percona Live.  The schedule lists two rooms of PG talks.


Room 1

Tuesday, May 17
 

10:30am CDT

11:30am CDT

1:30pm CDT

2:30pm CDT

4:00pm CDT

5:00pm CDT

 

Wednesday, May 18
 

9:30am CDT

10:50am CDT

11:50am CDT

2:00pm CDT

3:00pm CDT



Room 2


Tuesday, May 17
 

10:30am CDT

11:30am CDT

1:30pm CDT

2:30pm CDT

4:00pm CDT

5:00pm CDT

 

Wednesday, May 18
 

9:30am CDT

10:50am CDT

11:50am CDT

2:00pm CDT

3:00pm CDT



Percona Live MySQL Sessions

Percona Live's schedule has very interesting MySQL talks.  This is an in person event in Austin Texas and one of the rooms will be livestreamed.  Please note there are TWO rooms to chose from.

Room 1 

 Tuesday, May 17