Browse Source

Update psql.md

Artem Szubowicz 9 năm trước cách đây
mục cha
commit
f4bd38bd8a
1 tập tin đã thay đổi với 5 bổ sung1 xóa
  1. 5 1
      pages/common/psql.md

+ 5 - 1
pages/common/psql.md

@@ -6,10 +6,14 @@
 
 `psql {{database}}`
 
-- Connect to *database* on given server *host* running on given *port* with *username* given
+- Connect to *database* on given server *host* running on given *port* with *username* given, no password prompt
 
 `psql -h {{host}} -p {{port}} -U {{username}} {{database}}`
 
+- Connect to *database*, user will be prompted for password
+
+`psql -h {{host}} -p {{port}} -U {{username}} -W {{database}}`
+
 - Run single *query* against the given *database*. Note: useful in shell scripts
 
 `psql -c '{{query}}' {{database}}`