Re: JDBC 7.3 dev (Java 2 SDK 1.4.0)

Поиск
Список
Период
Сортировка
От Dave Cramer
Тема Re: JDBC 7.3 dev (Java 2 SDK 1.4.0)
Дата
Msg-id 1031322954.2646.70.camel@inspiron.cramers
обсуждение исходный текст
Ответ на Re: JDBC 7.3 dev (Java 2 SDK 1.4.0)  (snpe <snpe@snpe.co.yu>)
Ответы Re: JDBC 7.3 dev (Java 2 SDK 1.4.0)
Re: JDBC 7.3 dev (Java 2 SDK 1.4.0)
Список pgsql-jdbc
Remove the quotes around id, and let me know what happens

Dave
On Fri, 2002-09-06 at 10:52, snpe wrote:
> Hello Dave,
>   There isn't any error.Program write 'Rows deleted 1', but row hasn't been
> deleted
>
> Thanks
> Haris Peco
> On Friday 06 September 2002 04:05 pm, Dave Cramer wrote:
> > Harris,
> >
> > What error do you get?
> >
> > Also you don't need  the quotes around id
> >
> > Dave
> >
> > On Fri, 2002-09-06 at 10:06, snpe wrote:
> > > Hello,
> > >   I have simple table with column ID and values '4' in this.
> > > I user 7.3 beta1 (from cvs 05.09.2002) and autocommit off in
> > > postgresql.conf. Next program don't work .
> > > I am tried with compiled postgresql.jar form CVS and with
> > > pg73b1jdbc3.jar from 05.09.2002 on jdbc.postgresql.org
> > >
> > > What is wrong ?
> > >
> > > regards
> > > Haris Peco
> > > import java.io.*;
> > > import java.sql.*;
> > > import java.text.*;
> > >
> > > public class PrepStatTest
> > > {
> > >     Connection db;
> > >     String stat="DELETE FROM org_ban WHERE \"id\" = ?";
> > >     String delid = "4";
> > >     public PrepStatTest() throws ClassNotFoundException,
> > > FileNotFoundException, IOException, SQLException
> > >     {
> > >         Class.forName("org.postgresql.Driver");
> > >         db = DriverManager.getConnection("jdbc:postgresql://spnew/snpe",
> > > "snpe", "snpe");
> > >         PreparedStatement st = db.prepareStatement(stat);
> > >             st.setString(1, delid);
> > >             int rowsDeleted = st.executeUpdate();
> > >         System.out.println("Rows deleted " + rowsDeleted);
> > >         db.commit();
> > >         st.close();
> > >         db.close();
> > >     }
> > >
> > >     public static void main(String args[])
> > >     {
> > >         try
> > >         {
> > >             PrepStatTest test = new PrepStatTest();
> > >         }
> > >         catch (Exception ex)
> > >         {
> > >             System.err.println("Exception caught.\n" + ex);
> > >             ex.printStackTrace();
> > >         }
> > >     }
> > > }
> > >
> > >
> > > ---------------------------(end of broadcast)---------------------------
> > > TIP 3: if posting/reading through Usenet, please send an appropriate
> > > subscribe-nomail command to majordomo@postgresql.org so that your
> > > message can get through to the mailing list cleanly
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 2: you can get off all lists at once with the unregister command
>     (send "unregister YourEmailAddressHere" to majordomo@postgresql.org)
>
>




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

Предыдущее
От: snpe
Дата:
Сообщение: Re: JDBC 7.3 dev (Java 2 SDK 1.4.0)
Следующее
От: snpe
Дата:
Сообщение: Re: JDBC 7.3 dev (Java 2 SDK 1.4.0)