You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@turbine.apache.org by Hugh Brien <hp...@home.com> on 2001/11/10 10:06:04 UTC

Successful Build of Torque

FYI, I have successfully built Torque from the CVS tree and built the
installation.  I am still new to Torque development but I want to stay on
top of it's progress since I am using it as my persistance model.  I would
be willing to participate in development in anyway.  I have become pretty
familiar with building the Turbine-2, Fulcrum and Torque.  I successfully
generated source code and classes with CVS tree code.   My classes compiled
with no problem and I have them working with MySql.  I have Oracle 8.0.5
running on my Linxux box and I plan on testing there next.  When I get my
windows box fixed I will be able to test MSSQL also.

The only problem I have right now is with the database connection.
For example my the Map class for my Product class has the following line :
dbMap = Torque.getDatabaseMap("novusportal-mssql");

however when I set my database connection to the following in my
Torque.properties file  it won't work.

services.DatabaseService.database.novusportal-mssql.driver=org.gjt.mm.mysql.
Driver
services.DatabaseService.database.novusportal-mssql.url=jdbc:mysql://kite:33
06/novusportal
services.DatabaseService.database.novusportal-mssql.username=hbrien
services.DatabaseService.database.novusportal-mssql.password=test


However it does work when I set the database connection to

services.DatabaseService.database.default.driver=org.gjt.mm.mysql.Driver
services.DatabaseService.database.default.url=jdbc:mysql://kite:3306/novuspo
rtal
services.DatabaseService.database.default.username=hbrien
services.DatabaseService.database.default.password=test

Here is the code I wrote for my test

    Torque.init("H:/torque/schema/Torque.properties");
        Vector vector = ProductPeer.doSelect(new Criteria());
        for (int i = 0; i < vector.size(); i++) {
            Product product = (Product)vector.get(i);
            System.out.println(product.getProductName());
        }

If this is not the appropriate place to post this let me know and I can post
to to TurbineUser.

r,
Hugh







--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: Successful Build of Torque

Posted by Hugh Brien <hp...@home.com>.
I am using MySql right now  but I will be testing on MSSQL this week when I
get another windows box.
r,
Hugh
----- Original Message -----
From: "Incze Lajos" <in...@mail.matav.hu>
To: "Turbine Developers List" <tu...@jakarta.apache.org>
Sent: Saturday, November 10, 2001 2:13 PM
Subject: Re: Successful Build of Torque


> >
services.DatabaseService.database.novusportal-mssql.driver=org.gjt.mm.mysql.
>                                                 ^^^^^^^^^^
^^^^^^
>
> Are you using MS SQL or MySQL?
>
> incze
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> For additional commands, e-mail:
<ma...@jakarta.apache.org>
>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: Successful Build of Torque

Posted by Hugh Brien <hp...@home.com>.
I don't think this is the case because I am pretty sure only one version
of the Turbine security code is generated but used with different databases.
The source is the same is the sql that is different.
r,
Hugh
----- Original Message -----
From: "Incze Lajos" <in...@mail.matav.hu>
To: "Turbine Developers List" <tu...@jakarta.apache.org>
Sent: Sunday, November 11, 2001 3:14 PM
Subject: Re: Successful Build of Torque


> On Sat, Nov 10, 2001 at 09:41:48PM -0800, Hugh Brien wrote:
> > Let me clarify what I was doing. I generated my source and sql for
mssql,
> > however since I did not get my new windows box running with SQL Server I
> > just pointed my generated classes at an existing MySql database that I
had
> > created earlier this week.  I just wanted to make sure that I could get
the
> > new build working properly.
> > r,
> > Hugh
> > ----- Original Message -----
> > From: "Incze Lajos" <in...@mail.matav.hu>
> > To: "Turbine Developers List" <tu...@jakarta.apache.org>
> > Sent: Saturday, November 10, 2001 2:13 PM
> > Subject: Re: Successful Build of Torque
> >
> >
> > > >
> >
services.DatabaseService.database.novusportal-mssql.driver=org.gjt.mm.mysql.
> > >                                                 ^^^^^^^^^^
> > ^^^^^^
>
> I may be wrong but think that classes generated for an MS SQL database are
> not supposed to work with a MySQL database.
>
> incze
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> For additional commands, e-mail:
<ma...@jakarta.apache.org>
>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: Successful Build of Torque

Posted by Incze Lajos <in...@mail.matav.hu>.
On Sat, Nov 10, 2001 at 09:41:48PM -0800, Hugh Brien wrote:
> Let me clarify what I was doing. I generated my source and sql for mssql,
> however since I did not get my new windows box running with SQL Server I
> just pointed my generated classes at an existing MySql database that I had
> created earlier this week.  I just wanted to make sure that I could get the
> new build working properly.
> r,
> Hugh
> ----- Original Message -----
> From: "Incze Lajos" <in...@mail.matav.hu>
> To: "Turbine Developers List" <tu...@jakarta.apache.org>
> Sent: Saturday, November 10, 2001 2:13 PM
> Subject: Re: Successful Build of Torque
> 
> 
> > >
> services.DatabaseService.database.novusportal-mssql.driver=org.gjt.mm.mysql.
> >                                                 ^^^^^^^^^^
> ^^^^^^

I may be wrong but think that classes generated for an MS SQL database are
not supposed to work with a MySQL database.

incze

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: Successful Build of Torque

Posted by Hugh Brien <hp...@home.com>.
Let me clarify what I was doing. I generated my source and sql for mssql,
however since I did not get my new windows box running with SQL Server I
just pointed my generated classes at an existing MySql database that I had
created earlier this week.  I just wanted to make sure that I could get the
new build working properly.
r,
Hugh
----- Original Message -----
From: "Incze Lajos" <in...@mail.matav.hu>
To: "Turbine Developers List" <tu...@jakarta.apache.org>
Sent: Saturday, November 10, 2001 2:13 PM
Subject: Re: Successful Build of Torque


> >
services.DatabaseService.database.novusportal-mssql.driver=org.gjt.mm.mysql.
>                                                 ^^^^^^^^^^
^^^^^^
>
> Are you using MS SQL or MySQL?
>
> incze
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> For additional commands, e-mail:
<ma...@jakarta.apache.org>
>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: Successful Build of Torque

Posted by Incze Lajos <in...@mail.matav.hu>.
> services.DatabaseService.database.novusportal-mssql.driver=org.gjt.mm.mysql.
                                                ^^^^^^^^^^              ^^^^^^

Are you using MS SQL or MySQL?

incze

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: Successful Build of Torque

Posted by John McNally <jm...@collab.net>.
Try the very latest cvs and let me know if you still have the problem. 
I just checked in a fix to doSelect around noon (pacific) yesterday that
could help.

john mcnally

Hugh Brien wrote:
> 
> FYI, I have successfully built Torque from the CVS tree and built the
> installation.  I am still new to Torque development but I want to stay on
> top of it's progress since I am using it as my persistance model.  I would
> be willing to participate in development in anyway.  I have become pretty
> familiar with building the Turbine-2, Fulcrum and Torque.  I successfully
> generated source code and classes with CVS tree code.   My classes compiled
> with no problem and I have them working with MySql.  I have Oracle 8.0.5
> running on my Linxux box and I plan on testing there next.  When I get my
> windows box fixed I will be able to test MSSQL also.
> 
> The only problem I have right now is with the database connection.
> For example my the Map class for my Product class has the following line :
> dbMap = Torque.getDatabaseMap("novusportal-mssql");
> 
> however when I set my database connection to the following in my
> Torque.properties file  it won't work.
> 
> services.DatabaseService.database.novusportal-mssql.driver=org.gjt.mm.mysql.
> Driver
> services.DatabaseService.database.novusportal-mssql.url=jdbc:mysql://kite:33
> 06/novusportal
> services.DatabaseService.database.novusportal-mssql.username=hbrien
> services.DatabaseService.database.novusportal-mssql.password=test
> 
> However it does work when I set the database connection to
> 
> services.DatabaseService.database.default.driver=org.gjt.mm.mysql.Driver
> services.DatabaseService.database.default.url=jdbc:mysql://kite:3306/novuspo
> rtal
> services.DatabaseService.database.default.username=hbrien
> services.DatabaseService.database.default.password=test
> 
> Here is the code I wrote for my test
> 
>     Torque.init("H:/torque/schema/Torque.properties");
>         Vector vector = ProductPeer.doSelect(new Criteria());
>         for (int i = 0; i < vector.size(); i++) {
>             Product product = (Product)vector.get(i);
>             System.out.println(product.getProductName());
>         }
> 
> If this is not the appropriate place to post this let me know and I can post
> to to TurbineUser.
> 
> r,
> Hugh
> 
> --
> To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: Successful Build of Torque

Posted by Jason van Zyl <jv...@zenplex.com>.
On 11/10/01 4:06 AM, "Hugh Brien" <hp...@home.com> wrote:

> FYI, I have successfully built Torque from the CVS tree and built the
> installation.  I am still new to Torque development but I want to stay on
> top of it's progress since I am using it as my persistance model.  I would
> be willing to participate in development in anyway.  I have become pretty
> familiar with building the Turbine-2, Fulcrum and Torque.  I successfully
> generated source code and classes with CVS tree code.   My classes compiled
> with no problem and I have them working with MySql.  I have Oracle 8.0.5
> running on my Linxux box and I plan on testing there next.  When I get my
> windows box fixed I will be able to test MSSQL also.

If you want to help than check a profile into the
jakarta-turbine-torque/profile directory and run the tests for databases
that there are no profiles for yet. MSSQL is one that we don't have a
profile for. You can also try to break Torque in any way you can think, than
fix it and add a test for it. This would be the biggest help at this point
in time. There are many new features that we would like to add to Torque but
the most critical issue to deal with is getting a comprehensive testbed
working so that we can refactor with fear. The testbed also allows people
who are not intimately familiar with Torque to experiment with the code and
know they haven't inadvertently caused a problem.
 
> The only problem I have right now is with the database connection.
> For example my the Map class for my Product class has the following line :
> dbMap = Torque.getDatabaseMap("novusportal-mssql");

You have 'mssql' here ...
 
> however when I set my database connection to the following in my
> Torque.properties file  it won't work.
> 
> services.DatabaseService.database.novusportal-mssql.driver=org.gjt.mm.mysql.
> Driver
> services.DatabaseService.database.novusportal-mssql.url=jdbc:mysql://kite:33
> 06/novusportal

And 'mysql' here ... Are you using MySQL or MS SQL Server?

> services.DatabaseService.database.novusportal-mssql.username=hbrien
> services.DatabaseService.database.novusportal-mssql.password=test
> 
> 
> However it does work when I set the database connection to
> 
> services.DatabaseService.database.default.driver=org.gjt.mm.mysql.Driver
> services.DatabaseService.database.default.url=jdbc:mysql://kite:3306/novuspo
> rtal
> services.DatabaseService.database.default.username=hbrien
> services.DatabaseService.database.default.password=test
> 
> Here is the code I wrote for my test
> 
>   Torque.init("H:/torque/schema/Torque.properties");
>       Vector vector = ProductPeer.doSelect(new Criteria());
>       for (int i = 0; i < vector.size(); i++) {
>           Product product = (Product)vector.get(i);
>           System.out.println(product.getProductName());
>       }
> 
> If this is not the appropriate place to post this let me know and I can post
> to to TurbineUser.

No anything to do with Torque can be posted here. I think the problem you
are having is something John McNally and I discussed yesterday. I'll take a
look but in the mean time making a profile and running the tests would be a
big help.
 
> r,
> Hugh
> 
> 
> 
> 
> 
> 
> 
> --
> To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>

-- 

jvz.

Jason van Zyl

http://tambora.zenplex.org
http://jakarta.apache.org/turbine
http://jakarta.apache.org/velocity
http://jakarta.apache.org/alexandria
http://jakarta.apache.org/commons



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>