postgresql
postgresql on linux comes with a default "repl" used by invoking
it has alot of nice features, more than mysql
https://www.postgresql.org/docs/current/sql-createdatabase.html
BROKEN sql
GRANT ALL PRIVILEGES ON DATABASE EXAMPLE_DB TO EXAMPLE_USER;
GRANT ALL ON SCHEMA public TO EXAMPLE_USER;
ALTER USER user WITH PASSWORD 'password';
psql -U username -d myDataBase -a -f myInsertFile
psql-17 -U postgres -d gramsci -a -f ~Downloadsgramsci_mock_complete_02.11.25.sql
BROKEN
psql
it has alot of nice features, more than mysql
the
[cite:@postgresql_161 chapter 23 managing databases]
psql program's \l meta-command and -l command-line option are also useful for listing the existing databases.
[cite:@postgresql_161 chapter 23 managing databases]
database creation
create database <name>https://www.postgresql.org/docs/current/sql-createdatabase.html
list databases
\lERROR: template database "template1" has a collation version mismatch
sudo -u postgres psql
alter database template1 refresh collation version;
https://stackoverflow.com/questions/75746179/template-database-template1-has-a-collation-version-but-no-actual-collation-v
alter database template1 refresh collation version;
https://stackoverflow.com/questions/75746179/template-database-template1-has-a-collation-version-but-no-actual-collation-v
execute sql file
psql --username=<db_user_name> databasename < myfile.sql
https://stackoverflow.com/questions/6842393/import-sql-dump-into-postgresql-database
https://stackoverflow.com/questions/6842393/import-sql-dump-into-postgresql-database
postgresql cheatsheet
https://wiki.archlinux.org/title/PostgreSQLBROKEN sql
GRANT ALL PRIVILEGES ON DATABASE EXAMPLE_DB TO EXAMPLE_USER;
GRANT ALL ON SCHEMA public TO EXAMPLE_USER;
ALTER USER user WITH PASSWORD 'password';
psql -U username -d myDataBase -a -f myInsertFile
psql-17 -U postgres -d gramsci -a -f ~Downloadsgramsci_mock_complete_02.11.25.sql
BROKEN