Re: newbie questions about ojb setup with my database

2003-03-30 Thread Oki DZ
On Sun, Mar 30, 2003 at 06:22:07PM -0500, Michael Harrison wrote:
> When I want to use OJB to connect to my own production db, do I need to 
> run the build again, against a new build.xml file; or is it already set 

No, you don't need to run the build again.

> up to use MySQL, and I only have to alter a few configuration files for 
> the new jdbc url, password, etc?

I could get it run in standalone-mode by having the following xml files 
in a directory (the program's home):
repository.xml
repository_database.xml
repository_internal.xml
repository_user.xml

The contents of repository.xml, are basically:

&database;
&internal;
&user;

 
> The file repository_database.xml contains a jdbc-connection-descriptor 
> with attributes like jcd-alias="@JCD_ALIAS@"  I'm not familiar with 
> @foo@ notation--does this mean there is supposed to be a 
> previously-defined value for some JCD_ALIAS token or entity? Or is this 
> a placeholder that I should replace with real values?

You can change it to "default":



  
  

  

Somewhere above, ojbhome was set to the program's home dir.
 
> Also, what is the relationship between the repository_database.xml file 
> and the values I set in mysql.profile before the build? 

It would provide you with a connection defined in the file.

> Is the build  supposed to write this XML file out?

Yes; overwriting it, I mean.

Oki


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: newbie questions about ojb setup with my database

2003-03-30 Thread Lance Eason
Bill,

You're connection descriptor needs to be filled out with real values.  The templated 
version is used by OJB's build process, depending on the database you specify it grabs 
the values from one of the '.profile' files in the profiles directory and generates a 
populated version of repository-database.xml.

-Original Message-
From: Brill Pappin [mailto:[EMAIL PROTECTED]
Sent: Sunday, March 30, 2003 9:50 PM
To: OJB Users List
Subject: Re: newbie questions about ojb setup with my database


I've got a similar questions about those tokens.

I'm at the point of deploying the libs and a few tests to my development
server, however the tests seems to be failing because the tokens are not
being replaced.

I assume in the following (from repository-database.xml) that those values
are supposed to come from the OJB.properties file, however in my test output
it looks like they are not getting parsed.



I imagine this is a common problem, so can anyone tell me where the failure
originates, or how to solve it?

- Brill Pappin

- Original Message -
From: "Michael Harrison" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Sunday, March 30, 2003 6:22 PM
Subject: newbie questions about ojb setup with my database


> Hello, all. I'm very new to OJB, and I'm very excited about it. I've
> been reading the extensive documentation at db.apache.org, and I've
> managed to get OJB set up. I have a question, however, about configuring
> OJB to work with my MySQL database.
>
> I'm not only new to OJB, but new to Ant and building (I've been in the
> interpreted throw-away scripting world for a long time), so part of what
> I need to learn stems from my ignorence there. After I downloaded OJB
> and expanded everything, I followed the instructions at platforms.html
> to set up a test database. I "switched on" the line for the MySQL
> profile. I also edited the mysql.profile with the proper jdbc url info,
> username, password, etc.  I understood that two things were happening at
> once: 1) the build process was creating the necessary OJB internal
> tables, not all of which (or any necessarily?) are required; and 2) the
> build process was creating and populating tables for the example
> database, which simulates an actual production db.
>
> Here are my questions:
>
> When I want to use OJB to connect to my own production db, do I need to
> run the build again, against a new build.xml file; or is it already set
> up to use MySQL, and I only have to alter a few configuration files for
> the new jdbc url, password, etc?
>
> The file repository_database.xml contains a jdbc-connection-descriptor
> with attributes like jcd-alias="@JCD_ALIAS@"  I'm not familiar with
> @foo@ notation--does this mean there is supposed to be a
> previously-defined value for some JCD_ALIAS token or entity? Or is this
> a placeholder that I should replace with real values?
>
> Also, what is the relationship between the repository_database.xml file
> and the values I set in mysql.profile before the build? Is the build
> supposed to write this XML file out?
>
> If I need to rerun the build, how do I avoid creating all the example
> tables?
>
> I apologize for the newbie questions. I'm climbing a steep learning
> curve, and I'm probably not being as patient as I should be. Help me
> out, and I promise I'll find much more interesting questions soon enough.
>
> Best Regards,
>
> Michael
>
> ||
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: newbie questions about ojb setup with my database

2003-03-30 Thread Brill Pappin
I've got a similar questions about those tokens.

I'm at the point of deploying the libs and a few tests to my development
server, however the tests seems to be failing because the tokens are not
being replaced.

I assume in the following (from repository-database.xml) that those values
are supposed to come from the OJB.properties file, however in my test output
it looks like they are not getting parsed.



I imagine this is a common problem, so can anyone tell me where the failure
originates, or how to solve it?

- Brill Pappin

- Original Message -
From: "Michael Harrison" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Sunday, March 30, 2003 6:22 PM
Subject: newbie questions about ojb setup with my database


> Hello, all. I'm very new to OJB, and I'm very excited about it. I've
> been reading the extensive documentation at db.apache.org, and I've
> managed to get OJB set up. I have a question, however, about configuring
> OJB to work with my MySQL database.
>
> I'm not only new to OJB, but new to Ant and building (I've been in the
> interpreted throw-away scripting world for a long time), so part of what
> I need to learn stems from my ignorence there. After I downloaded OJB
> and expanded everything, I followed the instructions at platforms.html
> to set up a test database. I "switched on" the line for the MySQL
> profile. I also edited the mysql.profile with the proper jdbc url info,
> username, password, etc.  I understood that two things were happening at
> once: 1) the build process was creating the necessary OJB internal
> tables, not all of which (or any necessarily?) are required; and 2) the
> build process was creating and populating tables for the example
> database, which simulates an actual production db.
>
> Here are my questions:
>
> When I want to use OJB to connect to my own production db, do I need to
> run the build again, against a new build.xml file; or is it already set
> up to use MySQL, and I only have to alter a few configuration files for
> the new jdbc url, password, etc?
>
> The file repository_database.xml contains a jdbc-connection-descriptor
> with attributes like jcd-alias="@JCD_ALIAS@"  I'm not familiar with
> @foo@ notation--does this mean there is supposed to be a
> previously-defined value for some JCD_ALIAS token or entity? Or is this
> a placeholder that I should replace with real values?
>
> Also, what is the relationship between the repository_database.xml file
> and the values I set in mysql.profile before the build? Is the build
> supposed to write this XML file out?
>
> If I need to rerun the build, how do I avoid creating all the example
> tables?
>
> I apologize for the newbie questions. I'm climbing a steep learning
> curve, and I'm probably not being as patient as I should be. Help me
> out, and I promise I'll find much more interesting questions soon enough.
>
> Best Regards,
>
> Michael
>
> ||
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]