postgresQL 명령어

Nicholas·2022년 6월 24일
0

DATABASE

목록 보기
4/4

접속

  • AWS RDS
    psql --host=[AWS_RDS EndPoint] --port=[port number] --username=[RDS username] --password
  • local
    psql [databasename] -U [username]

사용자 조회

  • \du

DB 목록

  • \l

데이터베이스 접속 (변경)

  • \c [DB_name]

스키마 조회

  • \dn

스키마 접속 (변경)

  • set search_path to [schema_name];

테이블 조회

  • \dt 

테이블 정보 상세조회

-\d [Table name]

종료

  • \q
profile
WEB Developer

0개의 댓글