Windows下PostgreSQL命令行執行SQL查詢語句



C:\Program Files (x86)\PostgreSQL\9.5\bin>psql -d wf -U postgres -c "select * from public.wfeCasCard"
錯誤:  關係 "public.wfecascard" 不存在
第1行select * from public.wfeCasCard
                   ^

C:\Program Files (x86)\PostgreSQL\9.5\bin>psql -d wf -U postgres -c "select * from public."wfeCasCard""
錯誤:  關係 "public.wfecascard" 不存在
第1行select * from public.wfeCasCard
                   ^

C:\Program Files (x86)\PostgreSQL\9.5\bin>psql -d wf -U postgres -c "select * from ""wfeCard"""
錯誤:  關係 "wfeCard" 不存在
第1行select * from "wfeCard"
                   ^

C:\Program Files (x86)\PostgreSQL\9.5\bin>psql -d wf -U postgres -c "select * from public.""wfeCasCard"""
 EnterDate  |    DSN     |      CardID
------------+------------+------------------
 2015-12-11 |   12345689 |
 2015-12-11 |   12345689 |
 2015-12-11 |   12345689 |
 2015-12-11 |   12345689 |
 2015-12-11 |   12345689 |
 2015-12-11 |   12345689 |
 2015-12-11 |   12345689 | ACDE1234
 2015-12-11 |   12345689 | ACDE1234
 2015-12-11 | 1233345689 | ACDE1234
 2015-12-11 | 1233444455 | ACDE1234
 2015-12-11 | 1233444455 | ACDE1234
 2015-12-11 | 1233444455 | ACDE123411a
 2015-12-11 | 1233444455 | ACDE123411a
(13 行記錄)sql


C:\Program Files (x86)\PostgreSQL\9.5\bin>psql -d wf -U postgres -c "select * from ""wfeCasCard"""post

 EnterDate  |    DSN     |      CardID
------------+------------+------------------
 2015-12-11 |   12345689 |
 2015-12-11 |   12345689 |
 2015-12-11 |   12345689 |
 2015-12-11 |   12345689 |
 2015-12-11 |   12345689 |
 2015-12-11 |   12345689 |
 2015-12-11 |   12345689 | ACDE1234
 2015-12-11 |   12345689 | ACDE1234
 2015-12-11 | 1233345689 | ACDE1234
 2015-12-11 | 1233444455 | ACDE1234
 2015-12-11 | 1233444455 | ACDE1234
 2015-12-11 | 1233444455 | ACDE123411a
 2015-12-11 | 1233444455 | ACDE123411a
(13 行記錄)

spa

相關文章
相關標籤/搜索