X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id A79E13A19E5 for ; Tue, 18 Jan 2005 15:25:27 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 26705-10 for ; Tue, 18 Jan 2005 15:25:08 +0000 (GMT) Received: from rproxy.gmail.com (rproxy.gmail.com [64.233.170.205]) by svr1.postgresql.org (Postfix) with ESMTP id 0E4F63A18AA for ; Tue, 18 Jan 2005 15:25:11 +0000 (GMT) Received: by rproxy.gmail.com with SMTP id b11so10455rne for ; Tue, 18 Jan 2005 07:25:12 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:disposition-notification-to:date:from:user-agent:x-accept-language:mime-version:to:cc:subject:references:in-reply-to:content-type:content-transfer-encoding; b=mkvT6x77url+yWti9lXuxSDAZkuaMcL30SzTzXdA3/SexfqPB29tPGz23ijN8YhHYILJ++p5KXIj5sMbXU4NRwdjegaDFdjgbg+wSknXt8U9AoLFaPAQveJacwk5njZCcwwzkYzN48/KKHORFN9P7pTCqlmaEiD+CfW1IlVlVJM= Received: by 10.38.67.9 with SMTP id p9mr68406rna; Tue, 18 Jan 2005 07:25:11 -0800 (PST) Received: from ?192.168.1.99? ([221.225.154.78]) by smtp.gmail.com with ESMTP id 79sm4256rnc.2005.01.18.07.25.08; Tue, 18 Jan 2005 07:25:11 -0800 (PST) Message-ID: <41ED2A4C.3020703@gmail.com> Date: Tue, 18 Jan 2005 23:25:00 +0800 From: William Lai User-Agent: Mozilla Thunderbird 1.0 (Windows/20041206) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Becerra Lagos Ana Lilian Cc: pgsql-jdbc@postgresql.org Subject: Re: java.lang.NoClassDefFoundError References: <3A568BC085A5794983C7118F1A27CDEC2C7C40@epmarexc03.Entelpcs.Entelcorp.com> In-Reply-To: <3A568BC085A5794983C7118F1A27CDEC2C7C40@epmarexc03.Entelpcs.Entelcorp.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Virus-Scanned: by amavisd-new at hub.org X-Archive-Number: 200501/181 X-Sequence-Number: 12061 Hi, Did you try, java -classpath c:\path\to\pg73jdbc3.jar;. Example2 Have a nice day, William Becerra Lagos Ana Lilian wrote: > Hi, > > > > Could you help me in my program JAVA with jdbc Postgre > > I have my simple code > > > > import java.sql.DriverManager; > > import java.sql.Connection; > > import java.sql.SQLException; > > > > public class Example2 { > > public static void main(String[] argv) { > > System.out.println("Checking if Driver is registered with > DriverManager."); > > > > try { > > Class.forName("org.postgresql.Driver"); > > } catch (ClassNotFoundException cnfe) { > > System.out.println("Couldn't find the driver!"); > > System.out.println("Let's print a stack trace, and exit."); > > cnfe.printStackTrace(); > > System.exit(1); > > } > > } > > } > > > > Then I execute : > > javac Example2.java > > > > Then I execute > > java Example2 > > > > but I get > > Exception in thread "main" java.lang.NoClassDefFoundError: Example > > > > Wich is my error ? > > I copied pg73jdbc3.jar in my path > > C:\j2sdk1.4.1_07\lib\ > > Its have org.postgresql.Driver > > > > Thanks advanted > > ana > > Este correo es dirigido solo a las personas que aparecen como > destinatarios > y puede contener información confidencial o privilegiada. > Si usted recibió este correo por error, por favor notificar > inmediatamente > al emisor y elimine el correo original. Cualquier otro uso de este correo > esta prohibido. > > ****************************************************************************************************** > > > This message is for the designated recipient only and may contain > privileged or > confidential information. If you have received it in error, please > notify the sender > immediately and delete the original. Any other use of the email is > prohibited.