Article View: borland.public.jbuilder.java.api
Article #2624Re: Oracle Database : table creating Problem
From: J.T. Wenting
Date: Tue, 22 Aug 2000 00:00
Date: Tue, 22 Aug 2000 00:00
43 lines
1826 bytes
1826 bytes
try executeUpdate(String) instead...
"Ban" <ban@cae.wisc.edu> wrote in message news:39a067f9$1_1@dnews...
> I am using JBuilder3.5, Oracle 8.05 to develop a program to create a
table,
> below is the codes:
>
> Statement stmt=null;
> String dburl="jdbc:odbc:chan";
> Connection con=null;
> String s=null;
> try
> {
> Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
> con =
DriverManager.getConnection(dburl,"webresource","textreport");
> stmt=con.createStatement();
> s = "CREATE TABLE myTable " +
> "(myID VARCHAR2(10), myTYPE VARCHAR2(4), mycontent VARCHAR2(10) )";
> stmt.executeQuery(s);
>
> }
> catch(SQLException e)
> {
> System.out.println(e);
> }
>
>
> But, when running ,there is an SQLException which is "No ResultSet
> Produced".
> I don't know why. Please give me a hand.
> Thanks in advance.
>
> Xuegang Ban
> Department of Civil and Environmental Engineering
> University of Wisconsin at Madison
>
> Email: ban@cae.wsic.edu
> Tel: 608-260-9123 (H)
> 608-262-3967 (O)
>
>
>
Technical Details
Message-ID:
<966955415.24116.0.pluto.d4ee2b61@news.demon.nl>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailReferences:
<39a067f9$1_1@dnews>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 1089d0,4f4725c9f78b86d4 X-Google-Attributes: gid1089d0,public From: "J.T. Wenting" <jwenting@bigfoot.com> Subject: Re: Oracle Database : table creating Problem Date: 2000/08/22 Message-ID: <966955415.24116.0.pluto.d4ee2b61@news.demon.nl> X-Deja-AN: 661149582 X-NNTP-Posting-Host: hornet.demon.nl:212.238.43.97 References: <39a067f9$1_1@dnews> X-Priority: 3 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400 X-Complaints-To: abuse@nl.demon.net X-Trace: news.demon.nl 966955415 pluto:24116 NO-IDENT hornet.demon.nl:212.238.43.97 X-MSMail-Priority: Normal Newsgroups: borland.public.jbuilder.java.api