Re: Ver. 12.1 successfully installed on Win 10 but having troublewith jdbc jar

Поиск
Список
Период
Сортировка
От Laurenz Albe
Тема Re: Ver. 12.1 successfully installed on Win 10 but having troublewith jdbc jar
Дата
Msg-id 45d8549f99c0bad714a7fa8fbac3a002bcbcdbd0.camel@cybertec.at
обсуждение исходный текст
Ответ на Ver. 12.1 successfully installed on Win 10 but having trouble withjdbc jar  (CR20 <mez283em23e2ze2@yahoo.com>)
Список pgsql-admin
On Sun, 2020-01-19 at 19:24 -0500, CR20 wrote:
> ...which compiled successfully but when I go to run it, with postgresql-42.2.9.jar stored in path C:\PostgreSQL\libs,
likeas follows:
 
> 
> java -cp C:\PostgreSQL\libs . CreateTable
> 
> ...the command line returns:
> 
> Error: Could not find or load main class .
> 
> Some of this is my limited knowledge of Java.

Indeed.  You have to treat the JAR file as if it were a directory,
that is, put the file itself on the class path:

  java -cp C:\PostgreSQL\libs\postgresql-42.2.9.jar;. CreateTable

Yours,
Laurenz Albe
-- 
Cybertec | https://www.cybertec-postgresql.com




В списке pgsql-admin по дате отправления:

Предыдущее
От: Scott Ribe
Дата:
Сообщение: Re: pg_upgrade from 9.5.10 to 12 fails with encoding issue
Следующее
От: Joni Ruuskanen
Дата:
Сообщение: Restore fails if using multiple threads and database is dumpedthrough pipe