database.sarang.net
UserID
Passwd
Database
DBMS
MySQL
ㆍPostgreSQL
Firebird
Oracle
Informix
Sybase
MS-SQL
DB2
Cache
CUBRID
LDAP
ALTIBASE
Tibero
DB 문서들
스터디
Community
공지사항
자유게시판
구인|구직
DSN 갤러리
도움주신분들
Admin
운영게시판
최근게시물
PostgreSQL Q&A 3687 게시물 읽기
No. 3687
Re: 자문자답~^^
작성자
헌터^^
작성일
2001-11-23 14:03
조회수
1,945

Usage:

psql [options] [dbname [username]]

 

Options:

-a Echo all input from script

-A Unaligned table output mode (-P format=unaligned)

-c <query> Run only single query (or slash command) and exit

-d <dbname> Specify database name to connect to (default: postgres)

-e Echo queries sent to backend

-E Display queries that internal commands generate

-f <filename> Execute queries from file, then exit

-F <string> Set field separator (default: "|") (-P fieldsep=)

-h <host> Specify database server host (default: domain socket)

-H HTML table output mode (-P format=html)

-l List available databases, then exit

-n Disable readline

-o <filename> Send query output to filename (or |pipe)

-p <port> Specify database server port (default: hardwired)

-P var[=arg] Set printing option 'var' to 'arg' (see \pset command)

-q Run quietly (no messages, only query output)

-R <string> Set record separator (default: newline) (-P recordsep=)

-s Single step mode (confirm each query)

-S Single line mode (newline terminates query)

-t Print rows only (-P tuples_only)

-T text Set HTML table tag options (width, border) (-P tableattr=)

-U <username> Specify database username (default: postgres)

-v name=val Set psql variable 'name' to 'value'

-V Show version information and exit

-W Prompt for password (should happen automatically)

-x Turn on expanded table output (-P expanded)

-X Do not read startup file (~/.psqlrc)

 

-- 헌터^^ 님이 쓰신 글:

>> pgSQL 에서 MySQL의 show databases 와 같은 기능을 하는 명령어를 알고싶은데... 넘 쉬워서 그런건지 잘 찾아지지가 않네요. ㅠㅠ

>>

>> 그리구요, 처음 pgSQL 실행할때

>> $ ./psql DB_name

>> 이라고 DB 이름을 선택하고 들어가잖아요..

>> 그냥, 일단 들어가서 DB 리스트를 볼수는 없을까요?

>>

>> 만약 안된다면, 옛날에 만들어 뒀던 DB 들의 이름을 모조리 까먹었을때는 어떻게 DB를 볼수가 있는거죠?

[Top]
No.
제목
작성자
작성일
조회
3693여러 테이블의 데이타를 한번에 넣는 방법???
산타할멈
2001-11-27
1679
3691POSTGRES에서 동시 사용자수 제안 [2]
궁금증
2001-11-23
1626
3684php에서 원격으로 postgreSQL 연결할때... [1]
헌터^^
2001-11-23
4705
3690┕>Re: php에서 원격으로 postgreSQL 연결할때... [1]
정재익
2001-11-23 14:45:40
4599
3692┕>Re: php에서 원격으로 postgreSQL 연결할때...
박성철
2001-11-27 12:28:33
4113
3683MySQL의 show databases 와 같은 기능의 명령어는? [2]
헌터^^
2001-11-23
1985
3685┕>Re: MySQL의 show databases 와 같은 기능의 명령어는?
우하하
2001-11-23 13:58:30
1353
3687┕>Re: 자문자답~^^
헌터^^
2001-11-23 14:03:59
1945
3689 ┕>Re: Re: 자문자답~^^
정재익
2001-11-23 14:24:32
1912
3705┕>Re: MySQL의 show databases 와 같은 기능의 명령어는?
김대성
2001-12-04 20:27:22
2298
3680양/음력 변환함수가 있었던거 같은데요...
김종진
2001-11-22
2336
3682┕>Re: 양/음력 변환함수가 있었던거 같은데요...
정재익
2001-11-22 23:42:17
1802
3678postgresql의 일본어 지원
김명수
2001-11-22
2047
3679┕>올바른 답변이 되지는 않을 것 같습니다만.. -.-
순돌이
2001-11-22 19:05:15
1865
3686 ┕>아닙니다..찾아주신 것만 해도 감사합니다(내용무)
김명수
2001-11-23 13:59:39
1775
3677libpq.dll 에대해서
쫑아리
2001-11-22
1929
Valid XHTML 1.0!
All about the DATABASE... Copyleft 1999-2024 DSN, All rights reserved.
작업시간: 0.018초, 이곳 서비스는
	PostgreSQL v16.2로 자료를 관리합니다