Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1YdjPV-0006u3-Kh for pgsql-jdbc@arkaria.postgresql.org; Thu, 02 Apr 2015 18:00:09 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1YdjPV-0003fs-40 for pgsql-jdbc@arkaria.postgresql.org; Thu, 02 Apr 2015 18:00:09 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1YdjPU-0003ei-3h for pgsql-jdbc@postgresql.org; Thu, 02 Apr 2015 18:00:08 +0000 Received: from hogranch.com ([75.101.82.47]) by makus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1YdjPQ-0005r8-TJ for pgsql-jdbc@postgresql.org; Thu, 02 Apr 2015 18:00:06 +0000 Received: from [192.168.0.2] (porker [192.168.0.2]) by hogranch.com (8.11.6/8.11.6) with ESMTP id t32HxtH21865 for ; Thu, 2 Apr 2015 10:59:55 -0700 Message-ID: <551D8396.90907@hogranch.com> Date: Thu, 02 Apr 2015 10:59:50 -0700 From: John R Pierce User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:31.0) Gecko/20100101 Thunderbird/31.5.0 MIME-Version: 1.0 To: pgsql-jdbc@postgresql.org Subject: Re: how to get JDBC driver version from command line References: <1427991994768-5844478.post@n5.nabble.com> In-Reply-To: <1427991994768-5844478.post@n5.nabble.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-HawgScanner-Information: Please contact the ISP for more information X-HawgScanner: Found to be clean X-Pg-Spam-Score: -1.9 (-) 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 On 4/2/2015 9:26 AM, akshunj wrote: > Is there a way to get the JDBC driver version from the command line? I'd > like to make the name generic for various administrative reasons. > > I suspect this could be done using something along the lines of: > > java -cp ./postgresql.jdbc4.jar org.postgresql.Driver -version > > I'm not fluent in Java, so I would appreciate any help. pretty sure you'd need a java application that calls the getMajorVersion() and getMinorVersion() methods of the driver. don't think there's any way to do that from a command line. -- john r pierce, recycling bits in santa cruz -- Sent via pgsql-jdbc mailing list (pgsql-jdbc@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-jdbc