You are viewing a plain text version of this content. The canonical link for it is here.
Posted to soap-user@ws.apache.org by Isaac Wieder <is...@interactive-voice.com> on 2002/01/28 14:21:45 UTC

Mysql

Hi,

I am trying to run a webservice that uses a mysql database.  The service
runs fine through the connection, but when I try to query the database it
seems to die and a I get a Fault String indicating that the return object
is null.  If an exception is thrown I would not get a null return
object.  I am using mm.mysql-2.0.10.bin.jar package to provide my driver.
Are there any special issues with mysql?

thanks for your help,

Isaac


Re: Mysql

Posted by Fred Meredith <fm...@nc.rr.com>.

> Hi,
>
> I am trying to run a webservice that uses a mysql database.  The service
> runs fine through the connection, but when I try to query the database it
> seems to die and a I get a Fault String indicating that the return object
> is null.  If an exception is thrown I would not get a null return
> object.  I am using mm.mysql-2.0.10.bin.jar package to provide my driver.
> Are there any special issues with mysql?
>
> thanks for your help,
>
> Isaac
>

I've used MySQL as a database for many of my SOAP interfaces.  I'm using the
mm.mysql-2.0.2.bin.jar package.  Here is some sample code that I use:

String driver="org.gjt.mm.mysql.Driver";
String url="jdbc:mysql://localhost/dbname?user=root";

Class.forName(driver);
connection = DriverManager.getConnection(url);

Statement statement = connection.createStatement();
String qrySelect="SELECT * FROM tablename";
ResultSet result =statement.executeQuery(qrySelect);

while (result.next()) {

--- some processing here ---

}

--- and then some clean up code here ---

I'm not sure how much help that is...




Re: Mysql

Posted by Fred Meredith <fm...@nc.rr.com>.

> Hi,
>
> I am trying to run a webservice that uses a mysql database.  The service
> runs fine through the connection, but when I try to query the database it
> seems to die and a I get a Fault String indicating that the return object
> is null.  If an exception is thrown I would not get a null return
> object.  I am using mm.mysql-2.0.10.bin.jar package to provide my driver.
> Are there any special issues with mysql?
>
> thanks for your help,
>
> Isaac
>

I've used MySQL as a database for many of my SOAP interfaces.  I'm using the
mm.mysql-2.0.2.bin.jar package.  Here is some sample code that I use:

String driver="org.gjt.mm.mysql.Driver";
String url="jdbc:mysql://localhost/dbname?user=root";

Class.forName(driver);
connection = DriverManager.getConnection(url);

Statement statement = connection.createStatement();
String qrySelect="SELECT * FROM tablename";
ResultSet result =statement.executeQuery(qrySelect);

while (result.next()) {

--- some processing here ---

}

--- and then some clean up code here ---

I'm not sure how much help that is...