mirror of
https://github.com/ivuorinen/cheatsheet-tldr.git
synced 2026-02-16 17:49:13 +00:00
Update cheatsheets
This commit is contained in:
29
tldr/dropuser
Normal file
29
tldr/dropuser
Normal file
@@ -0,0 +1,29 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, common]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# dropuser
|
||||
|
||||
> Remove an existing PostgreSQL user (role).
|
||||
> More information: <https://www.postgresql.org/docs/current/app-dropuser.html>.
|
||||
|
||||
- Prompt for confirmation and the username before user removal:
|
||||
|
||||
`dropuser {{[-i|--interactive]}}`
|
||||
|
||||
- Remove user instantly:
|
||||
|
||||
`dropuser {{username}}`
|
||||
|
||||
- No error if the user to be removed doesn't exist:
|
||||
|
||||
`dropuser --if-exists {{username}}`
|
||||
|
||||
- Remove a user on the server with address 127.0.0.1 on port 4321:
|
||||
|
||||
`dropuser {{[-h|--host]}} 127.0.0.1 {{[-p|--port]}} 4321 {{username}}`
|
||||
|
||||
- Remove a user on the server with address 127.0.0.1 on port 4321 as user "admin" :
|
||||
|
||||
`dropuser {{[-U|--username]}} admin {{[-h|--host]}} 127.0.0.1 {{[-p|--port]}} 4321 {{username}}`
|
||||
Reference in New Issue
Block a user