Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1Ztc0o-0003yN-8m for pgsql-jdbc@arkaria.postgresql.org; Tue, 03 Nov 2015 13:52:34 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84) (envelope-from ) id 1Ztc0n-000685-Hx for pgsql-jdbc@arkaria.postgresql.org; Tue, 03 Nov 2015 13:52:33 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84) (envelope-from ) id 1Ztc0I-0005WU-ML for pgsql-jdbc@postgresql.org; Tue, 03 Nov 2015 13:52:02 +0000 Received: from plane.gmane.org ([80.91.229.3]) by magus.postgresql.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.84) (envelope-from ) id 1Ztc0F-0006uo-MJ for pgsql-jdbc@postgresql.org; Tue, 03 Nov 2015 13:52:02 +0000 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1Ztc0B-0007sB-HN for pgsql-jdbc@postgresql.org; Tue, 03 Nov 2015 14:51:55 +0100 Received: from 185.40.248.10 ([185.40.248.10]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 03 Nov 2015 14:51:55 +0100 Received: from spam_eater by 185.40.248.10 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 03 Nov 2015 14:51:55 +0100 X-Injected-Via-Gmane: http://gmane.org/ To: pgsql-jdbc@postgresql.org From: Thomas Kellerer Subject: Re: Problem in getting column names from DatabaseMetadata Object Date: Tue, 3 Nov 2015 14:51:49 +0100 Lines: 10 Message-ID: References: <1446556997253-5872498.post@n5.nabble.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 185.40.248.10 User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.23) Gecko/20090812 Thunderbird/2.0.0.23 Mnenhy/0.7.6.666 In-Reply-To: <1446556997253-5872498.post@n5.nabble.com> X-Pg-Spam-Score: 0.1 (/) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-jdbc Precedence: bulk Sender: pgsql-jdbc-owner@postgresql.org > I am using the following code to get the column names of my postgres table > but it fails. My database name is "employee" and table name is "employee". But you are connecting to a database called "data_gen": > DriverManager.getConnection("jdbc:postgresql://sampel.db:5432/data_gen", "postgres" Also: what exactly does "it fails" mean? Do you get an exception? If yes, what is the exception? Thomas -- Sent via pgsql-jdbc mailing list (pgsql-jdbc@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-jdbc