Re: Change od Schema during Runtime

2006-03-09 Thread Armin Waibel

Hi Guido,

Guido Beutler wrote:

Hello,

I would like to copy complex objects from schema A to schema B.


I suppose you mean copy data from one DB to another or from table A to 
table B within the same DB.



This would run in a managed environment (JBoss EJB Server)
The schema is configured at the XML Mapping, can I change this during runtime 
like
1) read data from schema A
2) change schema
3) store the same objects to schema B
Is the change of the schema only for this transaction?


With default OJB settings no.

Because the mapping 
configured at repository XML will be used by other transactions while the copy is running.




Exactly that's the problem. By default OJB use the same object metadata 
for all transactions/threads, so metadata changes will immediately 
noticed by all threads.
A PB instance can only "use" one metadata mapping, it's not possible to 
use different metadata mapping parallel with same PB instance.


But it's possible to use different metadata mapping on per thread base. 
Thus you can read the object using default schema A, then close current 
PB, load metadata profile B (using the MetadataManager), lookup a new PB 
instance (now associated with schema B).

http://db.apache.org/ojb/docu/guides/metadata.html#Per+thread+metadata+changes

regards,
Armin


best regards,

Guido



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



Change od Schema during Runtime

2006-03-09 Thread Guido Beutler
Hello,

I would like to copy complex objects from schema A to schema B.
This would run in a managed environment (JBoss EJB Server)
The schema is configured at the XML Mapping, can I change this during runtime 
like
1) read data from schema A
2) change schema
3) store the same objects to schema B
Is the change of the schema only for this transaction? Because the mapping 
configured at repository XML will be used by other transactions while the copy 
is running.

best regards,

Guido


Re: looking for a tool to transform ojb schema to xdoc

2005-09-06 Thread Thomas Dudziak
On 9/6/05, Christopher Cheng <[EMAIL PROTECTED]> wrote:

> I am looking for a tool or XLS schema to transform ojb schema file to xdoc
> format to put in Maven.
> 
> Is there such a thing?

Not that I know of. However XSLT is not so difficult, at least not
with an XML file as easy as an OJB repository file. Eg. have a look at

http://www.zvon.org/xxl/XSLTutorial/Books/Book1/

for XSLT info and samples.

As for generating the output file, there is an Ant task called style
that applies a stylesheet to an XML document:

http://ant.apache.org/manual/CoreTasks/style.html

I don't know anything about Maven, but I think you should be able to
use this ant task or something similar provided by Maven.

Tom

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



looking for a tool to transform ojb schema to xdoc

2005-09-05 Thread Christopher Cheng
I am looking for a tool or XLS schema to transform ojb schema file to xdoc
format to put in Maven. 

Is there such a thing?



RE: REPOST: OJB's support for object migration: [e.g torque table schema- how to alter existing table ]

2004-09-21 Thread Ajitesh Das

Brian: 
I am getting this error while trying to run tests. 
-
C:\dbmigrator\migratosaur>%JAVA_HOME%\bin\java -classpath
"lib\ant.jar;lib\bsh-1.2b7.jar;lib\commons-collections.jar;lib\hsqldb.ja
r;lib\jdom.jar;lib\junit.jar" -Djhome=%JAVA_HOME%
org.apache.tools.ant.Main run
%JAVA_HOME%\bin\java -classpath
"lib\ant.jar;lib\bsh-1.2b7.jar;lib\commons-collections.jar;lib\hsqldb.ja
r;lib\jdom.jar;lib\junit.jar" -Djhome=%JAVA_HOME%
org.apache.tools.ant.Main run
Buildfile: build.xml

run:
 [java] Whee
 [java] java.lang.NullPointerException
 [java] at
org.skife.migrate.loaders.XMLStepLoader.(Unknown Source)
 [java] at
org.skife.migrate.loaders.XMLStepLoader.(Unknown Source)
 [java] at org.skife.migrate.exec.Driver.main(Unknown Source)
 [java] Exception in thread "main" 
 [java] Java Result: 1

BUILD SUCCESSFUL
Total time: 1 second

C:\dbmigrator\migratosaur>



-Original Message-
From: Brian McCallister [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, September 21, 2004 5:06 PM
To: OJB Users List
Subject: Re: REPOST: OJB's support for object migration: [e.g torque
table schema- how to alter existing table ]

There aren't many docs. best way to get it is to build from CVS. There 
are samples and some docs included in the cvs download. Is not a *big* 
project, and I'd be happy to help you figure out how to use it.

Best way to get started is to pull from CVS (is always stable) and look 
at the samples. If you think of something it needs, I'll prolly be 
happy to put it in. I use this thing pretty much every day.

-Brian

On Sep 21, 2004, at 7:13 PM, Ajitesh Das wrote:

>
> Brian:
> I am not able to d'load the project or able to find any docs.
> Can u send me the pointer?
> ~ajitesh
>
> -Original Message-
> From: Brian McCallister [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, September 21, 2004 3:03 PM
> To: OJB Users List
> Subject: Re: REPOST: OJB's support for object migration: [e.g torque
> table schema- how to alter existing table ]
>
> OJB doesn't transparently migrate data -- I don't know of any good
> high-level general purpose tool which can do that. I wrote an
> incremental data-migration oriented tool a while back, but it doesn't
> use an o/r mapping. Simple is a dependency resolver with convenience
> features for database migrations.
>
> http://migratosaur.dev.java.net
>
> Nothing fancy about it, but it is maintained and works well for me =)
> No automated schema change discovery and guesswork -- no way to *know*
> the intention of changes, unfortunately. Any migration requires some
> human integration.
>
> I can imagine a "database refactoring browser" with a
> drag/click-and-act/etc type thing which encapsulates the actions into
a
> serializable thing to automate this, but to my knowledge no one has
> written one.
>
> -Brian
>
> On Sep 21, 2004, at 5:57 PM, Ajitesh Das wrote:
>
>> Reposting again. Let's see if anybody has any recommendation.
>>
>> -Original Message-
>>  Hi List:
>> I like to know if anybody who uses OJB platform in his product has
> done
>> anything on object model migration. This seems to be a missing piece
> in
>> OJB project. Am I missing something?
>> Example Scenario:
>> I have an existing application that uses OJB as OR platform contains
a
>> set of business objects.
>> In this new release, we are altering the definition of business
object
>> by adding new fields for some objects and deleting some fields for
>> others. I would like to know how other users are handling the two
>> situations: (a) When you add a new field to an existing object and
(b)
>> when you delete a field in an existing object. So that the old data
> can
>> be kept and properly defaulted.
>>
>> I have searched the Wiki ,docs and mail archive but could not find
any
>> recommendation/reference from the OJB developers/gurus or reference
to
>> some design patterns.
>>
>> Regds
>>  Ajitesh
>>
>>
>>
>> -
>> 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]
>
>



-
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: REPOST: OJB's support for object migration: [e.g torque table schema- how to alter existing table ]

2004-09-21 Thread Brian McCallister
There aren't many docs. best way to get it is to build from CVS. There 
are samples and some docs included in the cvs download. Is not a *big* 
project, and I'd be happy to help you figure out how to use it.

Best way to get started is to pull from CVS (is always stable) and look 
at the samples. If you think of something it needs, I'll prolly be 
happy to put it in. I use this thing pretty much every day.

-Brian
On Sep 21, 2004, at 7:13 PM, Ajitesh Das wrote:
Brian:
I am not able to d'load the project or able to find any docs.
Can u send me the pointer?
~ajitesh
-Original Message-
From: Brian McCallister [mailto:[EMAIL PROTECTED]
Sent: Tuesday, September 21, 2004 3:03 PM
To: OJB Users List
Subject: Re: REPOST: OJB's support for object migration: [e.g torque
table schema- how to alter existing table ]
OJB doesn't transparently migrate data -- I don't know of any good
high-level general purpose tool which can do that. I wrote an
incremental data-migration oriented tool a while back, but it doesn't
use an o/r mapping. Simple is a dependency resolver with convenience
features for database migrations.
http://migratosaur.dev.java.net
Nothing fancy about it, but it is maintained and works well for me =)
No automated schema change discovery and guesswork -- no way to *know*
the intention of changes, unfortunately. Any migration requires some
human integration.
I can imagine a "database refactoring browser" with a
drag/click-and-act/etc type thing which encapsulates the actions into a
serializable thing to automate this, but to my knowledge no one has
written one.
-Brian
On Sep 21, 2004, at 5:57 PM, Ajitesh Das wrote:
Reposting again. Let's see if anybody has any recommendation.
-Original Message-
 Hi List:
I like to know if anybody who uses OJB platform in his product has
done
anything on object model migration. This seems to be a missing piece
in
OJB project. Am I missing something?
Example Scenario:
I have an existing application that uses OJB as OR platform contains a
set of business objects.
In this new release, we are altering the definition of business object
by adding new fields for some objects and deleting some fields for
others. I would like to know how other users are handling the two
situations: (a) When you add a new field to an existing object and (b)
when you delete a field in an existing object. So that the old data
can
be kept and properly defaulted.
I have searched the Wiki ,docs and mail archive but could not find any
recommendation/reference from the OJB developers/gurus or reference to
some design patterns.
Regds
 Ajitesh

-
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]


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


RE: REPOST: OJB's support for object migration: [e.g torque table schema- how to alter existing table ]

2004-09-21 Thread Ajitesh Das

Brian: 
I am not able to d'load the project or able to find any docs. 
Can u send me the pointer? 
~ajitesh

-Original Message-
From: Brian McCallister [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, September 21, 2004 3:03 PM
To: OJB Users List
Subject: Re: REPOST: OJB's support for object migration: [e.g torque
table schema- how to alter existing table ]

OJB doesn't transparently migrate data -- I don't know of any good 
high-level general purpose tool which can do that. I wrote an 
incremental data-migration oriented tool a while back, but it doesn't 
use an o/r mapping. Simple is a dependency resolver with convenience 
features for database migrations.

http://migratosaur.dev.java.net

Nothing fancy about it, but it is maintained and works well for me =) 
No automated schema change discovery and guesswork -- no way to *know* 
the intention of changes, unfortunately. Any migration requires some 
human integration.

I can imagine a "database refactoring browser" with a 
drag/click-and-act/etc type thing which encapsulates the actions into a 
serializable thing to automate this, but to my knowledge no one has 
written one.

-Brian

On Sep 21, 2004, at 5:57 PM, Ajitesh Das wrote:

> Reposting again. Let's see if anybody has any recommendation.
>
> -Original Message-
>  Hi List:
> I like to know if anybody who uses OJB platform in his product has
done
> anything on object model migration. This seems to be a missing piece
in
> OJB project. Am I missing something?
> Example Scenario:
> I have an existing application that uses OJB as OR platform contains a
> set of business objects.
> In this new release, we are altering the definition of business object
> by adding new fields for some objects and deleting some fields for
> others. I would like to know how other users are handling the two
> situations: (a) When you add a new field to an existing object and (b)
> when you delete a field in an existing object. So that the old data
can
> be kept and properly defaulted.
>
> I have searched the Wiki ,docs and mail archive but could not find any
> recommendation/reference from the OJB developers/gurus or reference to
> some design patterns.
>
> Regds
>  Ajitesh
>
>
>
> -
> 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: REPOST: OJB's support for object migration: [e.g torque table schema- how to alter existing table ]

2004-09-21 Thread Brian McCallister
OJB doesn't transparently migrate data -- I don't know of any good 
high-level general purpose tool which can do that. I wrote an 
incremental data-migration oriented tool a while back, but it doesn't 
use an o/r mapping. Simple is a dependency resolver with convenience 
features for database migrations.

http://migratosaur.dev.java.net
Nothing fancy about it, but it is maintained and works well for me =) 
No automated schema change discovery and guesswork -- no way to *know* 
the intention of changes, unfortunately. Any migration requires some 
human integration.

I can imagine a "database refactoring browser" with a 
drag/click-and-act/etc type thing which encapsulates the actions into a 
serializable thing to automate this, but to my knowledge no one has 
written one.

-Brian
On Sep 21, 2004, at 5:57 PM, Ajitesh Das wrote:
Reposting again. Let's see if anybody has any recommendation.
-Original Message-
 Hi List:
I like to know if anybody who uses OJB platform in his product has done
anything on object model migration. This seems to be a missing piece in
OJB project. Am I missing something?
Example Scenario:
I have an existing application that uses OJB as OR platform contains a
set of business objects.
In this new release, we are altering the definition of business object
by adding new fields for some objects and deleting some fields for
others. I would like to know how other users are handling the two
situations: (a) When you add a new field to an existing object and (b)
when you delete a field in an existing object. So that the old data can
be kept and properly defaulted.
I have searched the Wiki ,docs and mail archive but could not find any
recommendation/reference from the OJB developers/gurus or reference to
some design patterns.
Regds
 Ajitesh

-
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]


REPOST: OJB's support for object migration: [e.g torque table schema- how to alter existing table ]

2004-09-21 Thread Ajitesh Das
Reposting again. Let's see if anybody has any recommendation. 

-Original Message-
 Hi List:
I like to know if anybody who uses OJB platform in his product has done
anything on object model migration. This seems to be a missing piece in 
OJB project. Am I missing something? 
Example Scenario:
I have an existing application that uses OJB as OR platform contains a
set of business objects. 
In this new release, we are altering the definition of business object
by adding new fields for some objects and deleting some fields for
others. I would like to know how other users are handling the two
situations: (a) When you add a new field to an existing object and (b)
when you delete a field in an existing object. So that the old data can
be kept and properly defaulted. 

I have searched the Wiki ,docs and mail archive but could not find any
recommendation/reference from the OJB developers/gurus or reference to
some design patterns. 

Regds 
 Ajitesh



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



OJB's support for object migration: [e.g torque table schema- how to alter existing table ]

2004-09-20 Thread Ajitesh Das
Hi List:
I like to know if anybody who uses OJB platform in his product has done
anything on object model migration. This seems to be a missing piece in 
OJB project. Am I missing something? 
Example Scenario:
I have an existing application that uses OJB as OR platform contains a
set of business objects. 
In this new release, we are altering the definition of business object
by adding new fields for some objects and deleting some fields for
others. I would like to know how other users are handling the two
situations: (a) When you add a new field to an existing object and (b)
when you delete a field in an existing object. So that the old data can
be kept and properly defaulted. 

I have searched the Wiki ,docs and mail archive but could not find any
recommendation/reference from the OJB developers/gurus or reference to
some design patterns. 

Regds 
 Ajitesh



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



Re: OJB XDoclet generating torque table schema

2004-09-20 Thread Thomas Dudziak
Thomas Paradies wrote:
While using the xdoclet ojb module (v1.0.0) I'm running into the same problem
as described in an older message from 2003 - see 
http://nagoya.apache.org/eyebrowse/[EMAIL PROTECTED]&msgNo=7009.

Following the thread I found an response - but no solution... In resumption 
of this thread I append a short example with two classes and the resulting 
schemas. As you can see there are no foreign key in torque schema. BTW, i 
got no error messages from XDoclet. Maybe, I'm wrong, sorry for inconvenience.
Currently the generation of foreignkeys for collections is not supported 
because of the involved difficulties (e.g. indirection tables, 
inheritance, mapping to the same table). See also this (short) thread:

http://nagoya.apache.org/eyebrowse/[EMAIL PROTECTED]&by=thread&from=827465
Tom
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


OJB XDoclet generating torque table schema

2004-09-20 Thread Thomas Paradies
While using the xdoclet ojb module (v1.0.0) I'm running into the same problem
as described in an older message from 2003 - see 
http://nagoya.apache.org/eyebrowse/[EMAIL PROTECTED]&msgNo=7009.

Following the thread I found an response - but no solution... In resumption 
of this thread I append a short example with two classes and the resulting 
schemas. As you can see there are no foreign key in torque schema. BTW, i 
got no error messages from XDoclet. Maybe, I'm wrong, sorry for inconvenience.
 
Thanks in advance,
Thomas

---
CLASSES
---
/**
 * @ojb.class table="A"
 */
public class A {
/**
 * @ojb.field column="ID" primarykey="true" autoincrement="ojb"  
 */
private int id;
/**
 * @ojb.collection element-class-ref="B" foreignkey="aId"
 */
private Collection bs;
}

/**
 * @ojb.class table="B"
 */
public class B {
/**
 * ojb.field column="ID" primarykey="true" autoincrement="ojb"
 */
private int id;
/**
 * @ojb.field name="aId" column="AID"
 */
private int aId;
}
---
REPOSITORY_USER
---












-
TORQUE-SCHEMA
-










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



RE: generating sql for internal tables and schema

2004-05-18 Thread Thomas Dudziak
On Tue, 18 May 2004, Bartosz Jankiewicz wrote:

> I've seen it in the XDoclet module docs in the "Usage" chapter.
> 
>   
>   
>destinationFile="project_schema.xml"/>
> 
> 
> In the same document there are also some deprecated targets in
> build-torque.xml. I could help you with the documentation after I tackle
> these problems.

Ups, a typo. I fixed this in CVS.
 
> One more question. build-torque.xml target "id-table-init-sql" generates
> sql for ID table:
>   insert into ID_TABLE (id_table_id, table_name, next_id,
> quantity) VALUES (...
> but I noticed the structure of table for high-low sequence manager looks
> different. I used ojbcore-schema.xml to create DDL for internal tables.
> Shall I fill these tables with initial data, or the sequence manager
> will do that?

Please be aware that OJB and Torque are two different things. OJB uses
Torque solely to generate table-creation sql from database-independent
schemas, and this only for its unit tests. In addition, it is encouraged
for users to use Torque to the same end.
This means that OJB uses these Torque targets only: sql, create-db,
datasql, insert-sql. Any other targets are Torque specific, as in your
case id-table-init-sql.

When you require the internal OJB tables (for the sequence manager or for
ODMG) then you simply include the corresponding schema
(src/schema/ojbcore-schema.xml) in the call to create-db (i.e. copy this
schema to the directory where Torque expects the schema files). Thats all,
OJB will fill these tables on its own.

Tom


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



RE: generating sql for internal tables and schema

2004-05-18 Thread Bartosz Jankiewicz
>
> On Tue, 18 May 2004, Bartosz Jankiewicz wrote:
>
> > Finally I've solved the problem. Default suffix for torque
> schema files
> > is "-schema.xml" so ant hasn't found my project_schema.xml
> file. This
> > case is now obvious to me but still hasn't been mentioned in
> > documentation shipped with OJB RC6, the documentation says to create
> > project_schema.xml. Please tell me if I'm using wrong version of
> > documentation or reverse engineering is the only way of
> learning OJB?
>
> Could you point me to the place in the documentation where it says to
> generate "project_schema.xml" so that I can fix it ?
> The problem is that the Torque build file is difficult to use at
> best, even for us developers. So there is no documentation as
> such (that
> I'm aware of) of how to use Torque with OJB because,
> eventually, we'd like
> to update to Torque 3.1/3.2 where the usage got somewhat
> easier, and we'd
> perhaps even provide the database setup within OJB (a
> supported wrapper
> around Torque or similar).
> So for now, yes, setting up your database with Torque will possibly
> require studying the Torque build file (and getting support from the
> Torque guys via their mailing list).
>

Ok, thank you for the tip. I still believe that OJB is worth that effort
;)

I've seen it in the XDoclet module docs in the "Usage" chapter.






In the same document there are also some deprecated targets in
build-torque.xml. I could help you with the documentation after I tackle
these problems.

One more question. build-torque.xml target "id-table-init-sql" generates
sql for ID table:
insert into ID_TABLE (id_table_id, table_name, next_id,
quantity) VALUES (...
but I noticed the structure of table for high-low sequence manager looks
different. I used ojbcore-schema.xml to create DDL for internal tables.
Shall I fill these tables with initial data, or the sequence manager
will do that?

Greetings,
Bartosz


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



RE: generating sql for internal tables and schema

2004-05-18 Thread Thomas Dudziak
On Tue, 18 May 2004, Bartosz Jankiewicz wrote:

> Finally I've solved the problem. Default suffix for torque schema files
> is "-schema.xml" so ant hasn't found my project_schema.xml file. This
> case is now obvious to me but still hasn't been mentioned in
> documentation shipped with OJB RC6, the documentation says to create
> project_schema.xml. Please tell me if I'm using wrong version of
> documentation or reverse engineering is the only way of learning OJB?

Could you point me to the place in the documentation where it says to
generate "project_schema.xml" so that I can fix it ?
The problem is that the Torque build file is difficult to use at
best, even for us developers. So there is no documentation as such (that
I'm aware of) of how to use Torque with OJB because, eventually, we'd like
to update to Torque 3.1/3.2 where the usage got somewhat easier, and we'd
perhaps even provide the database setup within OJB (a supported wrapper
around Torque or similar).
So for now, yes, setting up your database with Torque will possibly
require studying the Torque build file (and getting support from the
Torque guys via their mailing list).

Tom


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



RE: generating sql for internal tables and schema

2004-05-17 Thread Bartosz Jankiewicz
> After few days I managed to generate repository and torque schema with
> XDoclet module and now I stucked trying to generate SQL for internal
> tables and my model tables.
> I use following target from my build file:
>
> 
>   antfile="build-torque.xml"
>  target="sql-classpath">
>  value="mysql.profile" />
> 
> 
> 
> 
>
> and I get following error:
>
> [torque-sql] Generating to file
> C:\Projekty\CWP\build\sql\report.cwp.sql.generation
>   [ant] Exiting C:\Projekty\CWP\build-torque.xml.
> BUILD FAILED: C:\Projekty\CWP\build.xml:44: Following error occured
> while executing this line
> C:\Projekty\CWP\build-torque.xml:207: Exception thrown by
> 'properties.load'. For more information consult the velocity log, or
> invoke ant with the -debug flag.
>
> velocity.log shows nothing more:
> Method load threw exception for reference $properties in template
> sql/base/Control.vm at  [2,19]
>
> I've found some posts refering to this error, but they didn't give any
> tip.
>
> -Original Message-
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED]
> Sent: Monday, May 17, 2004 3:04 PM
> To: OJB Users List
> Subject: RE: generating sql for internal tables and schema
>
>
> I have an error like this when I use the torque maven plugin.
> The reason
> of my error was that I didn't set the properties :
> torque.database = mysql
> Torque need the db kind the generate sql from the schema.
>
> Nicolas,

Finally I've solved the problem. Default suffix for torque schema files
is "-schema.xml" so ant hasn't found my project_schema.xml file. This
case is now obvious to me but still hasn't been mentioned in
documentation shipped with OJB RC6, the documentation says to create
project_schema.xml. Please tell me if I'm using wrong version of
documentation or reverse engineering is the only way of learning OJB?

Bartosz


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



RE: generating sql for internal tables and schema

2004-05-17 Thread Bartosz Jankiewicz
Thanks, it helped with the error message but the only thing I get are empty sqldb.map 
and empty report :(

Bartosz

> -Original Message-
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] 
> Sent: Monday, May 17, 2004 3:04 PM
> To: OJB Users List
> Subject: RE: generating sql for internal tables and schema
> 
> 
> I have an error like this when I use the torque maven plugin. 
> The reason 
> of my error was that I didn't set the properties : 
> torque.database = mysql
> Torque need the db kind the generate sql from the schema.
> 
> Nicolas,
> 
> 
> 
> 
> 
> "Bartosz Jankiewicz" <[EMAIL PROTECTED]>
> 17/05/2004 15:53
> Veuillez répondre à "OJB Users List"
> 
>  
>     Pour :  <[EMAIL PROTECTED]>
> cc : 
> Objet : generating sql for internal tables and schema
> 
> 
> Hello,
> 
> After few days I managed to generate repository and torque schema with
> XDoclet module and now I stucked trying to generate SQL for internal
> tables and my model tables.
> I use following target from my build file:
> 
> 
>   antfile="build-torque.xml"
>  target="sql-classpath">
>  value="mysql.profile" />
> 
> 
> 
> 
> 
> and I get following error:
> 
> [torque-sql] Generating to file
> C:\Projekty\CWP\build\sql\report.cwp.sql.generation
>   [ant] Exiting C:\Projekty\CWP\build-torque.xml.
> BUILD FAILED: C:\Projekty\CWP\build.xml:44: Following error occured
> while executing this line
> C:\Projekty\CWP\build-torque.xml:207: Exception thrown by
> 'properties.load'. For more information consult the velocity log, or
> invoke ant with the -debug flag.
> 
> velocity.log shows nothing more:
> Method load threw exception for reference $properties in template
> sql/base/Control.vm at  [2,19] 
> 
> I've found some posts refering to this error, but they didn't give any
> tip.
> 
> What am I doing wrong? 
> 
> Bartosz
> 
> 
> -
> 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: generating sql for internal tables and schema

2004-05-17 Thread Nicolas . CHALUMEAU
I have an error like this when I use the torque maven plugin. The reason 
of my error was that I didn't set the properties : 
torque.database = mysql
Torque need the db kind the generate sql from the schema.

Nicolas,





"Bartosz Jankiewicz" <[EMAIL PROTECTED]>
17/05/2004 15:53
Veuillez répondre à "OJB Users List"

 
Pour :  <[EMAIL PROTECTED]>
cc : 
Objet : generating sql for internal tables and schema


Hello,

After few days I managed to generate repository and torque schema with
XDoclet module and now I stucked trying to generate SQL for internal
tables and my model tables.
I use following target from my build file:









and I get following error:

[torque-sql] Generating to file
C:\Projekty\CWP\build\sql\report.cwp.sql.generation
  [ant] Exiting C:\Projekty\CWP\build-torque.xml.
BUILD FAILED: C:\Projekty\CWP\build.xml:44: Following error occured
while executing this line
C:\Projekty\CWP\build-torque.xml:207: Exception thrown by
'properties.load'. For more information consult the velocity log, or
invoke ant with the -debug flag.

velocity.log shows nothing more:
Method load threw exception for reference $properties in template
sql/base/Control.vm at  [2,19] 

I've found some posts refering to this error, but they didn't give any
tip.

What am I doing wrong? 

Bartosz


-
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]



generating sql for internal tables and schema

2004-05-17 Thread Bartosz Jankiewicz
Hello,

After few days I managed to generate repository and torque schema with
XDoclet module and now I stucked trying to generate SQL for internal
tables and my model tables.
I use following target from my build file:









and I get following error:

[torque-sql] Generating to file
C:\Projekty\CWP\build\sql\report.cwp.sql.generation
  [ant] Exiting C:\Projekty\CWP\build-torque.xml.
BUILD FAILED: C:\Projekty\CWP\build.xml:44: Following error occured
while executing this line
C:\Projekty\CWP\build-torque.xml:207: Exception thrown by
'properties.load'. For more information consult the velocity log, or
invoke ant with the -debug flag.

velocity.log shows nothing more:
Method load threw exception for reference $properties in template
sql/base/Control.vm at  [2,19] 

I've found some posts refering to this error, but they didn't give any
tip.

What am I doing wrong? 

Bartosz


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



RE: problem with xdoclet generating torque schema

2004-05-17 Thread Bartosz Jankiewicz


> -Original Message-
> From: Thomas Dudziak [mailto:[EMAIL PROTECTED] 
> Sent: Monday, May 17, 2004 10:13 AM
> To: OJB Users List
> Subject: Re: problem with xdoclet generating torque schema
> 
> 
> On Mon, 17 May 2004, Bartosz Jankiewicz wrote:
> 
> > Hello,
> > 
> > I've searched archives of the group and didn't find any 
> sollution to my
> > problem.
> > 
> > I coppied necessary files after XDoclet module 
> documentation, XDoclet
> > module generates repository_user.xml but throws exceptions when
> > generating torque schema (project_schema.xml).
> 
> Please specify the XDoclet module version (e.g. from RC5, 
> RC6, CVS), and
> also the javadoc tags for the classes where the problem occurs (at
> least two classes as the problem occurs while handling an indirection
> table for a collection). The XDoclet module should print out 
> which class
> it processes when the error occurs (if not then your XDoclet 
> module is too
> old, and you should use the module from CVS - only the 
> module, no need to
> update OJB - which you can get from the CVS view on OJB's website).
> 
> Tom
> 
> 

I've found the reason of my problem. I have wrongly typed primarykey
attribute in one of the classes, so there was no primary field to link
with. My further questions will refer to database generation :)

bye


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



RE: problem with xdoclet generating torque schema

2004-05-17 Thread Bartosz Jankiewicz


> -Original Message-
> From: Thomas Dudziak [mailto:[EMAIL PROTECTED] 
> Sent: Monday, May 17, 2004 10:13 AM
> To: OJB Users List
> Subject: Re: problem with xdoclet generating torque schema
> 
> 
> On Mon, 17 May 2004, Bartosz Jankiewicz wrote:
> 
> > Hello,
> > 
> > I've searched archives of the group and didn't find any 
> sollution to my
> > problem.
> > 
> > I coppied necessary files after XDoclet module 
> documentation, XDoclet
> > module generates repository_user.xml but throws exceptions when
> > generating torque schema (project_schema.xml).
> 
> Please specify the XDoclet module version (e.g. from RC5, 
> RC6, CVS), and
> also the javadoc tags for the classes where the problem occurs (at
> least two classes as the problem occurs while handling an indirection
> table for a collection). The XDoclet module should print out 
> which class
> it processes when the error occurs (if not then your XDoclet 
> module is too
> old, and you should use the module from CVS - only the 
> module, no need to
> update OJB - which you can get from the CVS view on OJB's website).
> 
> Tom
> 


Thank's for quick response. I'm using version 1.2 of the module shipped
with OJB RC6 and I executed and with -v option and set verbose="true" in
torque task definition, still I don't see class names being processed,
so I gotta downlad newer version.

Bartosz


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



Re: problem with xdoclet generating torque schema

2004-05-17 Thread Thomas Dudziak
On Mon, 17 May 2004, Bartosz Jankiewicz wrote:

> Hello,
> 
> I've searched archives of the group and didn't find any sollution to my
> problem.
> 
> I coppied necessary files after XDoclet module documentation, XDoclet
> module generates repository_user.xml but throws exceptions when
> generating torque schema (project_schema.xml).

Please specify the XDoclet module version (e.g. from RC5, RC6, CVS), and
also the javadoc tags for the classes where the problem occurs (at
least two classes as the problem occurs while handling an indirection
table for a collection). The XDoclet module should print out which class
it processes when the error occurs (if not then your XDoclet module is too
old, and you should use the module from CVS - only the module, no need to
update OJB - which you can get from the CVS view on OJB's website).

Tom


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



problem with xdoclet generating torque schema

2004-05-17 Thread Bartosz Jankiewicz
Hello,

I've searched archives of the group and didn't find any sollution to my
problem.

I coppied necessary files after XDoclet module documentation, XDoclet
module generates repository_user.xml but throws exceptions when
generating torque schema (project_schema.xml).

Some parts of stack trace:

[ojbdoclet] (TemplateEngine.invokeMethod 573 ) Invoking method
failed: xdoclet.modules.ojb.OjbTagsHandler.createTorqueSchema, line=6 of
template file:
jar:file:C:\Projekty\CWP\lib\xdoclet-ojb-module-1.2.jar!/xdoclet/modules
/ojb/resources/torque_xml.xdt
[ojbdoclet] java.lang.reflect.InvocationTargetException


[ojbdoclet] Caused by: java.lang.IndexOutOfBoundsException: Index: 0,
Size: 0
[ojbdoclet] at java.util.ArrayList.RangeCheck(ArrayList.java:507)
[ojbdoclet] at java.util.ArrayList.get(ArrayList.java:324)
[ojbdoclet] at
xdoclet.modules.ojb.model.TorqueModelDef.addIndirectionTable(TorqueModel
Def.java:365)
[ojbdoclet] at
xdoclet.modules.ojb.model.TorqueModelDef.addTableFor(TorqueModelDef.java
:174)



Thanks in advance!

Janek


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



Re: xdoclet-ojb for torque schema generation is not adding the 'documentation' attribute

2004-05-07 Thread Mike Traum
Wow - your speedy!!! Thanks a million!

mike

On Thu, 2004-05-06 at 18:29, Thomas Dudziak wrote:

> On Wed, 5 May 2004, Mike Traum wrote:
> 
> > That would be great!  That's the main reason I'm generating the torque
> > schema - for automatic database documentation generation.
> 
> Done in CVS.
> 
> > I assume that's simply a small change to torque_xml.xdt?
> 
> Not quite, but almost. Since the torque meta model is generated by
> transformation from the ojb meta model within the xdoclet module, there
> were some code changes necessary as well. And of course, adaption of the
> unit tests :-)
> 
> Tom
> 
> 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]

-- 

Mike Traum
--
JGroup Expert 
Expresso Core Developer 
Providing support and development services - Available Now!


Re: xdoclet-ojb for torque schema generation is not adding the 'documentation' attribute

2004-05-06 Thread Thomas Dudziak
On Wed, 5 May 2004, Mike Traum wrote:

> That would be great!  That's the main reason I'm generating the torque
> schema - for automatic database documentation generation.

Done in CVS.

> I assume that's simply a small change to torque_xml.xdt?

Not quite, but almost. Since the torque meta model is generated by
transformation from the ojb meta model within the xdoclet module, there
were some code changes necessary as well. And of course, adaption of the
unit tests :-)

Tom



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



Re: xdoclet-ojb for torque schema generation is not adding the 'documentation' attribute

2004-05-05 Thread Mike Traum
On Wed, 2004-05-05 at 04:12, Thomas Dudziak wrote:
> On Wed, 5 May 2004, Mike Traum wrote:
> 
> > According to http://db.apache.org/ojb/xdoclet-module.html, a
> > 'documentation' attribute for @ojb.class and @ojb.field will result in
> > the  tag being generated in the torque schema. This
> > isn't happening for me. 
> > 
> > Anyone know why? 
> 
> This is because the documentation attribute is only used for the
> repository descriptor, not for the torque schema (and I couldn't find any
> statement in the docs saying differently).
>  
> I can however add support for the description attribute in those torque
> schema tags that support it (table, column), if you require it ?
> 
> Tom
> 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]

That would be great!  That's the main reason I'm generating the torque
schema - for automatic database documentation generation.

I assume that's simply a small change to torque_xml.xdt?

thanks,
mike



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



Re: xdoclet-ojb for torque schema generation is not adding the 'documentation' attribute

2004-05-05 Thread Thomas Dudziak
On Wed, 5 May 2004, Mike Traum wrote:

> According to http://db.apache.org/ojb/xdoclet-module.html, a
> 'documentation' attribute for @ojb.class and @ojb.field will result in
> the  tag being generated in the torque schema. This
> isn't happening for me. 
> 
> Anyone know why? 

This is because the documentation attribute is only used for the
repository descriptor, not for the torque schema (and I couldn't find any
statement in the docs saying differently).
 
I can however add support for the description attribute in those torque
schema tags that support it (table, column), if you require it ?

Tom


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



xdoclet-ojb for torque schema generation is not adding the 'documentation' attribute

2004-05-05 Thread Mike Traum
According to http://db.apache.org/ojb/xdoclet-module.html, a
'documentation' attribute for @ojb.class and @ojb.field will result in
the  tag being generated in the torque schema. This
isn't happening for me. 

Anyone know why? 

I tried to look in the bug database, but can't seem to access it. Is
there a migration to scarab going on right now?


Here's my javadoc and the generated project_schema.xml:
 BEGIN JAVADOC 
/**
 * Normal text blah blah...
 * 
 *  @ojb.class table="ISOCOUNTRYCODES"
 *  documentation="This is important documentation on the
ISOCountryCodes class."
 * 
 * @ojb.field name="ISOCode"
 *documentation="This is important documentation on the
ISOCode field."
 *jdbc-type="VARCHAR"
 *length="10"
 * @ojb.field name="Country"
 *documentation="This is important documentation on the
Country field."
 *jdbc-type="VARCHAR"
 *length="128"
 * @ojb.field name="PostalRegExp"
 *documentation="This is important documentation on the
PostalRegExp field."
 *jdbc-type="VARCHAR"
 *length="128"
 */
public class ISOCountryCodes
 END JAVADOC 

 BEGIN project_schema.xml 

http://jakarta.apache.org/turbine/dtd/database.dtd";>

 







 END project_schema.xml 


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



Re: [OJB XDoclet] fails because of database schema dtd

2004-03-02 Thread Joerg Heinicke
Thomas Dudziak  first.gmd.de> writes:

> > I'm behind a proxy, so that's probably the deeper reason for the fail. But
> > as I know the generation works from the OJB tests I had a look into its
> > schemas and there another DTD is referenced:
> > http://db.apache.org/torque/dtd/database_3_0_1.dtd
> > This one is probably not fetched from remote, but from a JAR, so it works.
> > The OJB XDoclet module should also reflect that change. Otherwise I can not
> > use it for my automatic build as I have to replace the DTD by hand.
> 
> No you don't as you can specify the DTD that is used via the dtdUrl
> attribute of the torqueschema subtask (see the docs for details).

Thanks for the hint, it works.

> Any
> other problem is due to Torque then (the XDoclet module does not check the
> DTD), or the XML parser used by Torque (there are issues with older Xerces
> parsers).

That was clear to me. But Torque must have been failing as the wrong DTD was
referenced and the XDoclet module added the reference to the schema file. That
was why I wrote to this list. I don't know why the default is still
http://jakarta.apache.org/turbine/dtd/database.dtd when Torque has moved to
db.apache.org. This would also be the reason that Torque itself knows the
database.dtd from db.apache.org, but not from jakarta.apache.org.

Joerg


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



Re: [OJB XDoclet] fails because of database schema dtd

2004-03-02 Thread Thomas Dudziak
On Tue, 2 Mar 2004, Joerg Heinicke wrote:

> Hello,
> 
> independent from OTM I came across another issue with OJB. I'm using the OJB
> XDoclet module for generating all the schema, descriptor, XML stuff. Yesterday I
> got Torque working, it generates my database schema XML now, unfortunately with
> an old URI for the DTD:
> 
> [torque-sql] (transform.DTDResolver 140 ) Resolver: used
> http://jakarta.apache.org/turbine/dtd/database.dtd
> [torque-sql] (transform.DTDResolver 160 ) Couldn't read DTD specified in XML
> schema:
> [torque-sql] java.net.ConnectException: Connection refused
> 
> I'm behind a proxy, so that's probably the deeper reason for the fail. But as I
> know the generation works from the OJB tests I had a look into its schemas and
> there another DTD is referenced:
> http://db.apache.org/torque/dtd/database_3_0_1.dtd
> This one is probably not fetched from remote, but from a JAR, so it works. The
> OJB XDoclet module should also reflect that change. Otherwise I can not use it
> for my automatic build as I have to replace the DTD by hand.

No you don't as you can specify the DTD that is used via the dtdUrl
attribute of the torqueschema subtask (see the docs for details). Any
other problem is due to Torque then (the XDoclet module does not check the
DTD), or the XML parser used by Torque (there are issues with older Xerces
parsers).

Tom


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



[OJB XDoclet] fails because of database schema dtd

2004-03-02 Thread Joerg Heinicke
Hello,

independent from OTM I came across another issue with OJB. I'm using the OJB
XDoclet module for generating all the schema, descriptor, XML stuff. Yesterday I
got Torque working, it generates my database schema XML now, unfortunately with
an old URI for the DTD:

[torque-sql] (transform.DTDResolver 140 ) Resolver: used
http://jakarta.apache.org/turbine/dtd/database.dtd
[torque-sql] (transform.DTDResolver 160 ) Couldn't read DTD specified in XML
schema:
[torque-sql] java.net.ConnectException: Connection refused

I'm behind a proxy, so that's probably the deeper reason for the fail. But as I
know the generation works from the OJB tests I had a look into its schemas and
there another DTD is referenced:
http://db.apache.org/torque/dtd/database_3_0_1.dtd
This one is probably not fetched from remote, but from a JAR, so it works. The
OJB XDoclet module should also reflect that change. Otherwise I can not use it
for my automatic build as I have to replace the DTD by hand.

Thanks in advance,

Joerg


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



Re: Tools to create database schema from 'repository.xml' ?

2003-10-16 Thread Marcus Breese
I actually use a combination of Torque and the ojb-doclet to create the 
database and the repository.xml file.  It also creates a skeleton 
object model.

Let me know if you're interested in my ant scripts and velocity 
templates...

On Thursday, October 16, 2003, at 06:44  AM, Christophe.Demarey wrote:

Hi,

I had a look in your test application but I don't find how to generate 
the database schema binding to the repository.xml file.

From the repository.xml file, is it possible to :
1) generate a sql file to create tables in the database?
2) execute this sql file in the database to create the database 
schema? (I think it's possible with Torque).

For these two steps, shall I use Torque Tasks ?
In this case :
* What values must I assign to properties? I found no documentation 
about this (ex: basePathToDbProps, idTableXMLFile, sqldbmap, ...).
* What configuration files must I take into my application? What 
should be modified? What is really needed (I want to use a light OJB 
version: only jars and configuration files)?

I really need this information as it is a very important part for me.

Thanks.

--
Christophe Demarey,
Research engineer
OpenCCM project - http://www.objectweb.org/openccm
GOAL Team - CNRS/USTL/LIFL - http://www.lifl.fr/GOAL/
Universite des Sciences et Technologies de Lille
LIFL - UMR CNRS 8022- Batiment M3
59655 Villeneuve d'Ascq Cedex - FRANCE
Phone: +33 (0)32043 4728
Fax  : +33 (0)32043 6566
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-=-= -=-= -=-= -=-= -=-= -=-= -=-= -=-= -=-= -=-= -=-=-
Marcus Breese[EMAIL PROTECTED]
IU School of Medicine  [EMAIL PROTECTED]
Dept. of Biochemistry and Molecular Biology
Center for Medical Genomics / Grow Lab


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


RE: Tools to create database schema from 'repository.xml' ?

2003-10-16 Thread Antonio Gallardo
Cobble, Tim dijo:
> Nice,  sounds better than the perl script my friend wrote.
> Will check it out!

Nice to hear that! I hope it would help you. If you find a bug please feel
free to contact the devel mail list on druid.

Best Regards,

Antonio Gallardo




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



RE: Tools to create database schema from 'repository.xml' ?

2003-10-16 Thread Cobble, Tim
Nice,  sounds better than the perl script my friend wrote.
Will check it out!

Tim


-Original Message-
From: Antonio Gallardo [mailto:[EMAIL PROTECTED] 
Sent: Thursday, October 16, 2003 8:39 AM
To: [EMAIL PROTECTED]
Subject: RE: Tools to create database schema from 'repository.xml' ?

Cobble, Tim dijo:
> How about tools to create the repository.xml from either DDL or
> database?

See Druid - http://druid.sf.net/ . The CVS version include that an OJB
generator. You can also wait for the next release that will be today or
tomorrow.

Druid also has an import tool from a JDBC connection. That way you can
generate a repository from an already deployed Database.

Best Regards,

Antonio Gallardo.
>
> -Original Message-
> From: Christophe.Demarey [mailto:[EMAIL PROTECTED]
> Sent: Thursday, October 16, 2003 7:45 AM
> To: OJB Users List
> Subject: Tools to create database schema from 'repository.xml' ?
>
> Hi,
>
> I had a look in your test application but I don't find how to generate
> the database schema binding to the repository.xml file.
>
>  From the repository.xml file, is it possible to :
> 1) generate a sql file to create tables in the database?
> 2) execute this sql file in the database to create the database
schema?
> (I think it's possible with Torque).
>
> For these two steps, shall I use Torque Tasks ?
> In this case :
> * What values must I assign to properties? I found no documentation
> about this (ex: basePathToDbProps, idTableXMLFile, sqldbmap, ...). *
> What configuration files must I take into my application? What should
> be modified? What is really needed (I want to use a light OJB version:
> only jars and configuration files)?
>
> I really need this information as it is a very important part for me.
>
>
> Thanks.
>
> --
> Christophe Demarey,
> Research engineer
> OpenCCM project - http://www.objectweb.org/openccm
> GOAL Team - CNRS/USTL/LIFL - http://www.lifl.fr/GOAL/
> Universite des Sciences et Technologies de Lille
> LIFL - UMR CNRS 8022- Batiment M3
> 59655 Villeneuve d'Ascq Cedex - FRANCE
> Phone: +33 (0)32043 4728
> Fax  : +33 (0)32043 6566
>
>
> -
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]


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



RE: Tools to create database schema from 'repository.xml' ?

2003-10-16 Thread Antonio Gallardo
Cobble, Tim dijo:
> How about tools to create the repository.xml from either DDL or
> database?

See Druid - http://druid.sf.net/ . The CVS version include that an OJB
generator. You can also wait for the next release that will be today or
tomorrow.

Druid also has an import tool from a JDBC connection. That way you can
generate a repository from an already deployed Database.

Best Regards,

Antonio Gallardo.
>
> -Original Message-
> From: Christophe.Demarey [mailto:[EMAIL PROTECTED]
> Sent: Thursday, October 16, 2003 7:45 AM
> To: OJB Users List
> Subject: Tools to create database schema from 'repository.xml' ?
>
> Hi,
>
> I had a look in your test application but I don't find how to generate
> the database schema binding to the repository.xml file.
>
>  From the repository.xml file, is it possible to :
> 1) generate a sql file to create tables in the database?
> 2) execute this sql file in the database to create the database schema?
> (I think it's possible with Torque).
>
> For these two steps, shall I use Torque Tasks ?
> In this case :
> * What values must I assign to properties? I found no documentation
> about this (ex: basePathToDbProps, idTableXMLFile, sqldbmap, ...). *
> What configuration files must I take into my application? What should
> be modified? What is really needed (I want to use a light OJB version:
> only jars and configuration files)?
>
> I really need this information as it is a very important part for me.
>
>
> Thanks.
>
> --
> Christophe Demarey,
> Research engineer
> OpenCCM project - http://www.objectweb.org/openccm
> GOAL Team - CNRS/USTL/LIFL - http://www.lifl.fr/GOAL/
> Universite des Sciences et Technologies de Lille
> LIFL - UMR CNRS 8022- Batiment M3
> 59655 Villeneuve d'Ascq Cedex - FRANCE
> Phone: +33 (0)32043 4728
> Fax  : +33 (0)32043 6566
>
>
> - 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. : RE: Tools to create database schema from 'repository.xml' ?

2003-10-16 Thread stephane . labbe-ext


You have one reverse tool :
ant reverse-db


De "Cobble, Tim"  :
> How about tools to create the repository.xml from either DDL or
> database?
>
> -Original Message-
> From: Christophe.Demarey [mailto:[EMAIL PROTECTED]
> Sent: Thursday, October 16, 2003 7:45 AM
> To: OJB Users List
> Subject: Tools to create database schema from 'repository.xml' ?
>
> Hi,
>
> I had a look in your test application but I don't find how to generate
> the database schema binding to the repository.xml file.
>
> From the repository.xml file, is it possible to :
> 1) generate a sql file to create tables in the database?
> 2) execute this sql file in the database to create the database schema?
> (I think it's possible with Torque).
>
> For these two steps, shall I use Torque Tasks ?
> In this case :
> * What values must I assign to properties? I found no documentation
> about this (ex: basePathToDbProps, idTableXMLFile, sqldbmap, ...).
> * What configuration files must I take into my application? What should
> be modified? What is really needed (I want to use a light OJB version:
> only jars and configuration files)?
>
> I really need this information as it is a very important part for me.
>
>
> Thanks.
>
> --
> Christophe Demarey,
> Research engineer
> OpenCCM project - http://www.objectweb.org/openccm
> GOAL Team - CNRS/USTL/LIFL - http://www.lifl.fr/GOAL/
> Universite des Sciences et Technologies de Lille
> LIFL - UMR CNRS 8022- Batiment M3
> 59655 Villeneuve d'Ascq Cedex - FRANCE
> Phone: +33 (0)32043 4728
> Fax  : +33 (0)32043 6566
>
>
> -
> 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: Tools to create database schema from 'repository.xml' ?

2003-10-16 Thread Cobble, Tim
How about tools to create the repository.xml from either DDL or
database?

-Original Message-
From: Christophe.Demarey [mailto:[EMAIL PROTECTED] 
Sent: Thursday, October 16, 2003 7:45 AM
To: OJB Users List
Subject: Tools to create database schema from 'repository.xml' ?

Hi,

I had a look in your test application but I don't find how to generate 
the database schema binding to the repository.xml file.

 From the repository.xml file, is it possible to :
1) generate a sql file to create tables in the database?
2) execute this sql file in the database to create the database schema? 
(I think it's possible with Torque).

For these two steps, shall I use Torque Tasks ?
In this case :
* What values must I assign to properties? I found no documentation 
about this (ex: basePathToDbProps, idTableXMLFile, sqldbmap, ...).
* What configuration files must I take into my application? What should 
be modified? What is really needed (I want to use a light OJB version: 
only jars and configuration files)?

I really need this information as it is a very important part for me.


Thanks.

-- 
Christophe Demarey,
Research engineer
OpenCCM project - http://www.objectweb.org/openccm
GOAL Team - CNRS/USTL/LIFL - http://www.lifl.fr/GOAL/
Universite des Sciences et Technologies de Lille
LIFL - UMR CNRS 8022- Batiment M3
59655 Villeneuve d'Ascq Cedex - FRANCE
Phone: +33 (0)32043 4728
Fax  : +33 (0)32043 6566


-
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]



Tools to create database schema from 'repository.xml' ?

2003-10-16 Thread Christophe.Demarey
Hi,

I had a look in your test application but I don't find how to generate 
the database schema binding to the repository.xml file.

From the repository.xml file, is it possible to :
1) generate a sql file to create tables in the database?
2) execute this sql file in the database to create the database schema? 
(I think it's possible with Torque).

For these two steps, shall I use Torque Tasks ?
In this case :
* What values must I assign to properties? I found no documentation 
about this (ex: basePathToDbProps, idTableXMLFile, sqldbmap, ...).
* What configuration files must I take into my application? What should 
be modified? What is really needed (I want to use a light OJB version: 
only jars and configuration files)?

I really need this information as it is a very important part for me.

Thanks.

--
Christophe Demarey,
Research engineer
OpenCCM project - http://www.objectweb.org/openccm
GOAL Team - CNRS/USTL/LIFL - http://www.lifl.fr/GOAL/
Universite des Sciences et Technologies de Lille
LIFL - UMR CNRS 8022- Batiment M3
59655 Villeneuve d'Ascq Cedex - FRANCE
Phone: +33 (0)32043 4728
Fax  : +33 (0)32043 6566
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Antwort: Re: SCHEMA

2003-10-15 Thread Cesar
I didn´t try yet 
[ ]´s
- Original Message - 
From: <[EMAIL PROTECTED]>
To: "OJB Users List" <[EMAIL PROTECTED]>
Sent: Wednesday, October 15, 2003 4:27 AM
Subject: Antwort: Re: SCHEMA



Hi Cesar,

is this working for you? I asked something similar a few weeks ago (I
named it qualifier instead of schema) but I don't see how I can set a
different schema name for each jcdalias.

Lasse





|-+--->
| |   Wayne Kidd  |
| |   <[EMAIL PROTECTED]|
| |   om> |
| |   |
| |   22.09.03 20:29  |
| |   Bitte antworten |
| |   an "OJB Users   |
| |   List"   |
| |   |
|-+--->

>---
|
  |
|
  |An:  OJB Users List <[EMAIL PROTECTED]>
|
  |Kopie:
|
  |Thema:   Re: SCHEMA
|

>---
|



I don't think it matters how many companies you have for this to
work.
The thing does not have to be completely dynamic unless you create
the
schema after startup.  What I do is run an initializer servlet at
startup.  For each schema, I open a jcdalias (you could do this
dynamically by creating a JdbcConnectionDescriptor instance
(equivalent
to coding a jdbc-connection-descriptor entry in repository.xml)).
Unless there is something missing in this logic, you should be OK.

Wayne

cesar.leite wrote:

>Hi Wayne
>
>I read in emails this solution but my problem is that my
>application work "N" companies and for each company I have a
>schema different i'am working with DB2 and this solution is
>not best in my the case.
>
>Is There another solution with ojb?
>
>[ ]´s
>Cesar
>
>
>
>>When a PersistenceBrokerFactory creates a PersistenceBroker
>>
>>
>instance, it
>
>
>>can specify a different jcdalias.  That alias can work again
>>
>>
>st the same
>
>
>>repository.xml but a different url (accessing a different da
>>
>>
>tabase).  In
>
>
>>order for this to work properly, the OJB.properties should s
>>
>>
>pecify
>
>
>>ObjectCacheClass=org.apache.ojb.broker.cache.ObjectCachePerB
>>
>>
>rokerImpl
>
>
>>so that seperate caches are maintained for the separate
>>PersistenceBroker instances.
>>
>>Wayne
>>
>>
>>cesar.leite wrote:
>>
>>
>>
>>>Hi
>>>I would like to know if with ojb i can change my schema whe
>>>
>>>
>n
>
>
>>>i'm executing my program?
>>>
>>>Example: I can use the SCHEMA1.PRODUCT and later I can use
>>>SCHEMA2.PRODUCT to have access the same table product.
>>>
>>>thanks.
>>>Cesar
>>>
>>>
>>>---
>>>Acabe com aquelas janelinhas que pulam na sua tela.
>>>AntiPop-up UOL - É grátis!
>>>http://antipopup.uol.com.br
>>>
>>>
>>>---
>>>
>>>
>--
>
>
>>>To unsubscribe, e-mail: [EMAIL PROTECTED]
>>>For additional commands, e-mail: ojb-user-
>>>
>>>
>[EMAIL PROTECTED]
>
>
>>>
>>>
>>>
>>>
>>
>>
>>
>-
>
>
>>To unsubscribe, e-mail: [EMAIL PROTECTED]
>>For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
>>
>>
>
>
>---
>Acabe com aquelas janelinhas que pulam na sua tela.
>AntiPop-up UOL - É grátis!
>http://antipopup.uol.com.br
>
>
>
-
>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]



Antwort: Re: SCHEMA

2003-10-15 Thread lasse . lambrecht

Hi Cesar,

is this working for you? I asked something similar a few weeks ago (I
named it qualifier instead of schema) but I don't see how I can set a
different schema name for each jcdalias.

Lasse





|-+--->
| |   Wayne Kidd  |
| |   <[EMAIL PROTECTED]|
| |   om> |
| |   |
| |   22.09.03 20:29  |
| |   Bitte antworten |
| |   an "OJB Users   |
| |   List"   |
| |   |
|-+--->
  
>---|
  |
   |
  |An:  OJB Users List <[EMAIL PROTECTED]> 
  |
  |Kopie:  
   |
  |Thema:   Re: SCHEMA 
   |
  
>---|



I don't think it matters how many companies you have for this to
work.
The thing does not have to be completely dynamic unless you create
the
schema after startup.  What I do is run an initializer servlet at
startup.  For each schema, I open a jcdalias (you could do this
dynamically by creating a JdbcConnectionDescriptor instance
(equivalent
to coding a jdbc-connection-descriptor entry in repository.xml)).
Unless there is something missing in this logic, you should be OK.

Wayne

cesar.leite wrote:

>Hi Wayne
>
>I read in emails this solution but my problem is that my
>application work "N" companies and for each company I have a
>schema different i'am working with DB2 and this solution is
>not best in my the case.
>
>Is There another solution with ojb?
>
>[ ]´s
>Cesar
>
>
>
>>When a PersistenceBrokerFactory creates a PersistenceBroker
>>
>>
>instance, it
>
>
>>can specify a different jcdalias.  That alias can work again
>>
>>
>st the same
>
>
>>repository.xml but a different url (accessing a different da
>>
>>
>tabase).  In
>
>
>>order for this to work properly, the OJB.properties should s
>>
>>
>pecify
>
>
>>ObjectCacheClass=org.apache.ojb.broker.cache.ObjectCachePerB
>>
>>
>rokerImpl
>
>
>>so that seperate caches are maintained for the separate
>>PersistenceBroker instances.
>>
>>Wayne
>>
>>
>>cesar.leite wrote:
>>
>>
>>
>>>Hi
>>>I would like to know if with ojb i can change my schema whe
>>>
>>>
>n
>
>
>>>i'm executing my program?
>>>
>>>Example: I can use the SCHEMA1.PRODUCT and later I can use
>>>SCHEMA2.PRODUCT to have access the same table product.
>>>
>>>thanks.
>>>Cesar
>>>
>>>
>>>---
>>>Acabe com aquelas janelinhas que pulam na sua tela.
>>>AntiPop-up UOL - É grátis!
>>>http://antipopup.uol.com.br
>>>
>>>
>>>---
>>>
>>>
>--
>
>
>>>To unsubscribe, e-mail: [EMAIL PROTECTED]
>>>For additional commands, e-mail: ojb-user-
>>>
>>>
>[EMAIL PROTECTED]
>
>
>>>
>>>
>>>
>>>
>>
>>
>>
>-
>
>
>>To unsubscribe, e-mail: [EMAIL PROTECTED]
>>For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
>>
>>
>
>
>---
>Acabe com aquelas janelinhas que pulam na sua tela.
>AntiPop-up UOL - É grátis!
>http://antipopup.uol.com.br
>
>
>
-
>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: SCHEMA

2003-09-22 Thread Wayne Kidd
I don't think it matters how many companies you have for this to work.  
The thing does not have to be completely dynamic unless you create the 
schema after startup.  What I do is run an initializer servlet at 
startup.  For each schema, I open a jcdalias (you could do this 
dynamically by creating a JdbcConnectionDescriptor instance (equivalent 
to coding a jdbc-connection-descriptor entry in repository.xml)).  
Unless there is something missing in this logic, you should be OK.

Wayne

cesar.leite wrote:

Hi Wayne

I read in emails this solution but my problem is that my 
application work "N" companies and for each company I have a 
schema different i'am working with DB2 and this solution is 
not best in my the case.

Is There another solution with ojb?

[ ]´s
Cesar
 

When a PersistenceBrokerFactory creates a PersistenceBroker 
   

instance, it 
 

can specify a different jcdalias.  That alias can work again
   

st the same 
 

repository.xml but a different url (accessing a different da
   

tabase).  In 
 

order for this to work properly, the OJB.properties should s
   

pecify
 

ObjectCacheClass=org.apache.ojb.broker.cache.ObjectCachePerB
   

rokerImpl
 

so that seperate caches are maintained for the separate 
PersistenceBroker instances.

Wayne

cesar.leite wrote:

   

Hi
I would like to know if with ojb i can change my schema whe
 

n 
 

i'm executing my program?

Example: I can use the SCHEMA1.PRODUCT and later I can use 
SCHEMA2.PRODUCT to have access the same table product.

thanks.
Cesar
---
Acabe com aquelas janelinhas que pulam na sua tela.
AntiPop-up UOL - É grátis! 
http://antipopup.uol.com.br

---
 

--
 

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

[EMAIL PROTECTED]
 



 


   

-
 

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



---
Acabe com aquelas janelinhas que pulam na sua tela.
AntiPop-up UOL - É grátis! 
http://antipopup.uol.com.br

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



Re: SCHEMA

2003-09-21 Thread Ron Gallagher
Cesar --

You may want to take a look at the 'profiles' capability within the metadata manager.  
In your case, you'd set up a separate profile for each company.  The only difference 
between the profiles would be the schema name assigned to each class descriptor.

At start up, your repository.xml would contain a single set of class-descriptors with 
no schema name set.  Then, you'd do the following for each company:
1) Get the original DescriptorRepository via the copyOfGlobalRepository.
2) Loop through all class descriptors and set the schema name accordingly.
3) Add the profile via the MetadataManager::addProfile method.  Since your profiles 
are company specific, you can use the name of the company as the 'key' for the profile.

Then, after you acquire a PersistenceBroker, you'd tell the MetadataManager to load 
the profile that is specific to the 'current' company.

HTH

Ron Gallagher
Atlanta, GA
[EMAIL PROTECTED]


> 
> From: "cesar.leite" <[EMAIL PROTECTED]>
> Date: 2003/09/21 Sun AM 09:11:56 EDT
> To: [EMAIL PROTECTED]
> Subject: Re: SCHEMA
> 
> Hi Wayne
> 
> I read in emails this solution but my problem is that my
> application work "N" companies and for each company I have a
> schema different i'am working with DB2 and this solution is
> not best in my the case.
> 
> Is There another solution with ojb?
> 
> [ ]´s
> Cesar
> 
> > When a PersistenceBrokerFactory creates a PersistenceBroker
> instance, it
> > can specify a different jcdalias.  That alias can work again
> st the same
> > repository.xml but a different url (accessing a different da
> tabase).  In
> > order for this to work properly, the OJB.properties should s
> pecify
> > ObjectCacheClass=org.apache.ojb.broker.cache.ObjectCachePerB
> rokerImpl
> >
> > so that seperate caches are maintained for the separate
> > PersistenceBroker instances.
> >
> > Wayne
> >
> >
> > cesar.leite wrote:
> >
> > >Hi
> > >I would like to know if with ojb i can change my schema whe
> n
> > >i'm executing my program?
> > >
> > >Example: I can use the SCHEMA1.PRODUCT and later I can use
> > >SCHEMA2.PRODUCT to have access the same table product.
> > >
> > >thanks.
> > >Cesar
> > >
> > >
> > >---
> > >Acabe com aquelas janelinhas que pulam na sua tela.
> > >AntiPop-up UOL - É grátis!
> > >http://antipopup.uol.com.br
> > >
> > >
> > >---
> --
> > >To unsubscribe, e-mail: [EMAIL PROTECTED]
> > >For additional commands, e-mail: ojb-user-
> [EMAIL PROTECTED]
> > >
> > >
> >
> >
> > 
> -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
> 
> 
> ---
> Acabe com aquelas janelinhas que pulam na sua tela.
> AntiPop-up UOL - É grátis!
> http://antipopup.uol.com.br
> 
> 
> -
> 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: SCHEMA

2003-09-21 Thread cesar.leite
Hi Wayne

I read in emails this solution but my problem is that my
application work "N" companies and for each company I have a
schema different i'am working with DB2 and this solution is
not best in my the case.

Is There another solution with ojb?

[ ]´s
Cesar

> When a PersistenceBrokerFactory creates a PersistenceBroker
instance, it
> can specify a different jcdalias.  That alias can work again
st the same
> repository.xml but a different url (accessing a different da
tabase).  In
> order for this to work properly, the OJB.properties should s
pecify
> ObjectCacheClass=org.apache.ojb.broker.cache.ObjectCachePerB
rokerImpl
>
> so that seperate caches are maintained for the separate
> PersistenceBroker instances.
>
> Wayne
>
>
> cesar.leite wrote:
>
> >Hi
> >I would like to know if with ojb i can change my schema whe
n
> >i'm executing my program?
> >
> >Example: I can use the SCHEMA1.PRODUCT and later I can use
> >SCHEMA2.PRODUCT to have access the same table product.
> >
> >thanks.
> >Cesar
> >
> >
> >---
> >Acabe com aquelas janelinhas que pulam na sua tela.
> >AntiPop-up UOL - É grátis!
> >http://antipopup.uol.com.br
> >
> >
> >---
--
> >To unsubscribe, e-mail: [EMAIL PROTECTED]
> >For additional commands, e-mail: ojb-user-
[EMAIL PROTECTED]
> >
> >
>
>
> 
-
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


---
Acabe com aquelas janelinhas que pulam na sua tela.
AntiPop-up UOL - É grátis!
http://antipopup.uol.com.br


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



Re: SCHEMA

2003-09-20 Thread Wayne Kidd
When a PersistenceBrokerFactory creates a PersistenceBroker instance, it 
can specify a different jcdalias.  That alias can work against the same 
repository.xml but a different url (accessing a different database).  In 
order for this to work properly, the OJB.properties should specify
ObjectCacheClass=org.apache.ojb.broker.cache.ObjectCachePerBrokerImpl

so that seperate caches are maintained for the separate 
PersistenceBroker instances.

Wayne

cesar.leite wrote:

Hi
I would like to know if with ojb i can change my schema when 
i'm executing my program?

Example: I can use the SCHEMA1.PRODUCT and later I can use 
SCHEMA2.PRODUCT to have access the same table product.

thanks.
Cesar
---
Acabe com aquelas janelinhas que pulam na sua tela.
AntiPop-up UOL - É grátis! 
http://antipopup.uol.com.br

-
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]


SCHEMA

2003-09-20 Thread cesar.leite
Hi
I would like to know if with ojb i can change my schema when
i'm executing my program?

Example: I can use the SCHEMA1.PRODUCT and later I can use
SCHEMA2.PRODUCT to have access the same table product.

thanks.
Cesar


---
Acabe com aquelas janelinhas que pulam na sua tela.
AntiPop-up UOL - É grátis!
http://antipopup.uol.com.br


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



RE: Velocity error trying to create schema for MySQL

2003-09-20 Thread Neil Aggarwal
Tom:

I just realized that I had moved the mysql.profile and that
was causing velocity to barf.  

I did not check it based on the error message I got.

Thanks,
Neil


--
Neil Aggarwal, JAMM Consulting, (972)612-6056, www.JAMMConsulting.com
FREE! Valuable info on how your business can reduce operating costs by 
17% or more in 6 months or less! => http://newsletter.JAMMConsulting.com

> -Original Message-
> From: Thomas Dudziak [mailto:[EMAIL PROTECTED] 
> Sent: Saturday, September 20, 2003 3:23 AM
> To: OJB Users List
> Subject: Re: Velocity error trying to create schema for MySQL
> 
> 
> First, run ant with the -v option. This should give you more 
> detailed info
> on the build process. Also, it would be good if you could post your
> repository_user.xml and project_schema.xml files.
> 
> Tom
> 
> 
> 
> 
> -
> 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: Velocity error trying to create schema for MySQL

2003-09-20 Thread Thomas Dudziak
First, run ant with the -v option. This should give you more detailed info
on the build process. Also, it would be good if you could post your
repository_user.xml and project_schema.xml files.

Tom




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



Velocity error trying to create schema for MySQL

2003-09-19 Thread Neil Aggarwal
Hello:

When I try to generate the MySQL schema for a simple test app,
I get this error in the Velocity log:
2003-09-19 15:45:34,174 - Method load threw exception for reference
$properties in template sql/base/Control.vm at  [2,19]

Here is the target I am using to do it:
  

  
  

  

Here is my complete buildfile:


  
  

  
  
  
  
  
  

  

  
  

  
  

  
  
 
   

  

  

  


  

  
  
  


  


  
  

   

  


  

   
  

   

  


  

  
 

  
 
   


  

   

  

  
  

  

  

  
  

  
  
  

  



Any ideas?

Thanks, 
Neil

--
Neil Aggarwal, JAMM Consulting, (972)612-6056, www.JAMMConsulting.com
FREE! Valuable info on how your business can reduce operating costs by 
17% or more in 6 months or less! => http://newsletter.JAMMConsulting.com


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



Error generating schema sql

2003-09-16 Thread Neil Aggarwal
Hello:

When I try to call project-sql-classpath from my build file, I 
get this error:

BUILD FAILED
file:C:/JavaLibs/db-ojb-1.0.rc4/build-torque.xml:435:
C:\Dev\OjbJdoTest\lib not
found.

Does this mean I have to copy all of the db-ojb libs into a lib
directory
in my project?  I tried to over-ride the torque.classpath by calling
the build-torque.xml file using this call:

  

  
  
  

  

In case you need it, here is my complete build.xml file:



  
  

  
  
  
  
  

  

  
  

  
  

  
  
   

  

  

  


  


  
  

   

  


  

   
  

   

  

  


  

   

  

  
  
  

  

  

  
  
  

  
  


Thanks,
Neil

--
Neil Aggarwal, JAMM Consulting, (972)612-6056, www.JAMMConsulting.com
FREE! Valuable info on how your business can reduce operating costs by 
17% or more in 6 months or less! => http://newsletter.JAMMConsulting.com


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



Re: OJB XDoclet generating torque table schema

2003-08-14 Thread 苗启广
hi ,all:
   how can I send my questions to all of you ? Could you tell me ? Thanks~~
 mqg

__
Find a Chinese Souvenir, Just Click Here:
http://www.souvenirchina.com
mailto:[EMAIL PROTECTED]

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

OJB XDoclet generating torque table schema

2003-08-14 Thread Hayes, Reggie D.
I am using the xdoclet ojb module to generate an ojb repository and a torque
schema.  The problem that I am running into is that the foreign key
reference constraints are not generated for collections.  My persistent
collections are only implementing 1:n associations.  The foreign key
reference constraints are generated for references.  Am I doing something
wrong?
 
/**
 *  The collection of BioAssays for this Experiment.
 *  
 * @ojb.collection
element-class-ref="gov.nih.niehs.cebs.domain.BioAssay.BioAssay"
 *
collection-class="gov.nih.niehs.cebs.domain.Interface.HasBioAssays$BioAssays
_list"
 *
foreignkey="experimentId"
 *
auto-update="true"
 *
auto-delete="true"
 *
orderby="id=DESC"
 */


Re: OJB XDoclet generating torque table schema

2003-08-14 Thread Thomas Dudziak
The tags look ok, however you only supplied the collection comment. This 
might sound trivial but is there an experimentId field (that also has an 
ojb.field tag) in the element class or one of its subclasses ? Do you 
get any errors from the xdoclet ojb module ? (try ant -v to see some 
more output)
If its none of the above you could send me the source or a comparable 
example so I can check it.

Tom



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


OJB XDoclet generating torque table schema

2003-08-14 Thread Reggie Hayes
I am using the xdoclet ojb module to generate an ojb repository and a
torque schema.  The problem that I am running into is that the foreign
key reference constraints are not generated for ojb collections within
the torque schema.  The foreign key reference constraints are generated
for ojb references.  Am I doing something wrong?
 
/**
 *  The collection of BioAssays for this Experiment.
 *  
 * @ojb.collection
element-class-ref="gov.nih.niehs.cebs.domain.BioAssay.BioAssay"
 *
collection-class="gov.nih.niehs.cebs.domain.Interface.HasBioAssays$BioAs
says_list"
 *
foreignkey="experimentId"
 *
auto-update="true"
 *
auto-delete="true"
 *
orderby="id=DESC"
 */
 
 


OJB XDoclet generating torque table schema

2003-08-07 Thread Reggie & Valerie Hayes
I am using the xdoclet ojb module to generate an ojb repository and a
torque schema.  The problem that I am running into is that the foreign
key reference constraints are not generated for ojb collections within
the torque schema.  The foreign key reference constraints are generated
for ojb references.  Am I doing something wrong?
 
/**
 *  The collection of BioAssays for this Experiment.
 *  
 * @ojb.collection
element-class-ref="gov.nih.niehs.cebs.domain.BioAssay.BioAssay"
 *
collection-class="gov.nih.niehs.cebs.domain.Interface.HasBioAssays$BioAs
says_list"
 *
foreignkey="experimentId"
 *
auto-update="true"
 *
auto-delete="true"
 *
orderby="id=DESC"
 */
 


Re: [Re-post] indirection-table and schema (Thomas, can you confirm?)

2003-07-22 Thread Jason Mihalick
Synonyms don't work in DB2.  Everything has to be qualified with a 
schema.  The only way around it is that I'm aware of is to run the "set 
current sqlid=''", a DB2 platform specific command.

I haven't had a chance to test yet, but I suspect that I will need to set

indirection-table="SYSADM.FOO_BAR"

Thomas, can you confirm or deny this?  ;-)

--
Jason
Roland Carlsson wrote:

If I remember correctly a schema is to Ojb the same thing as the user.  You
specify the login to the database you are going to use and then you can use
all objects that the user has rights to use. I'm not sure if the
. notation work but you could prehaps create synoyms for
those objects?
Regards
Roland
- Original Message - 
From: "Jason Mihalick" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, July 22, 2003 11:56 AM
Subject: [Re-post] indirection-table and schema

 

Does the indirection-table attribute on a  pick up
   

a
 

schema name from anywhere or is this something you have to specify in the
value of the indirection-table attribute?
Example:

If my schema name is SYSADM and my indirection table is FOO_BAR, does my
indirection-table attribute need to look like this?

   

 

  
 ...
  


OR is the schema inherited from parent class-descriptor?

Thanks in advance,
Jason


-
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: [Re-post] indirection-table and schema

2003-07-22 Thread Roland Carlsson
If I remember correctly a schema is to Ojb the same thing as the user.  You
specify the login to the database you are going to use and then you can use
all objects that the user has rights to use. I'm not sure if the
. notation work but you could prehaps create synoyms for
those objects?

Regards
Roland

- Original Message - 
From: "Jason Mihalick" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, July 22, 2003 11:56 AM
Subject: [Re-post] indirection-table and schema


> Does the indirection-table attribute on a  pick up
a
> schema name from anywhere or is this something you have to specify in the
> value of the indirection-table attribute?
>
> Example:
>
> If my schema name is SYSADM and my indirection table is FOO_BAR, does my
> indirection-table attribute need to look like this?
>
>table="FOO"
>   schema="SYSADM"
>   ...
>
> >>
> >
> >
>   ...
>   indirection-table="SYSADM.FOO_BAR"
>>
>   ...
>
>
> 
>
> OR is the schema inherited from parent class-descriptor?
>
>
> Thanks in advance,
> Jason
>
>
>
> -
> 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-post] indirection-table and schema

2003-07-22 Thread Jason Mihalick
Does the indirection-table attribute on a  pick up a
schema name from anywhere or is this something you have to specify in the
value of the indirection-table attribute?
Example:

If my schema name is SYSADM and my indirection table is FOO_BAR, does my
indirection-table attribute need to look like this?


 

  
 ...
  


OR is the schema inherited from parent class-descriptor?

Thanks in advance,
Jason


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


indirection-table and schema

2003-07-21 Thread jrmihalick
Does the indirection-table attribute on a  pick up a
schema name from anywhere or is this something you have to specify in the
value of the indirection-table attribute?

Example:

If my schema name is SYSADM and my indirection table is FOO_BAR, does my
indirection-table attribute need to look like this?


   
  ...
   



OR is the schema inherited from parent class-descriptor?


Thanks in advance,
Jason



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



Re: [RE: Oracle Connection & Schema Question]

2003-07-10 Thread Josh Berry
If you are using Ant for building, it has some wonderful capabilities here. 
Specifically look into the filtering capabilities.  

It is possible to do the following:
  

Then, when you copy a file do the following:
  
..
  


Not sure if this is exactly what you had in mind, but I think it could
accomplish the same thing.

-josh



"McCaffrey, John G." <[EMAIL PROTECTED]> wrote:
> I also ran into this issue, as well as the need to dynamically change the
> schema between environments (development, test, stage, Production - all
> point to different databases/schemas)
> 
> I solved this using the following
> 1. each server has a systemProperty "env" that indicates whether it is
"dev"
> or "test" or "prod"
> 2. I have an Servlet.init() that calls System.getProperty("env"); and loads
> the right OJB and log4J files 
> 
> for example when I deploy to the "test" server
> 3. in test_OJB.properties: 
>   the repositoryFile =OJB/test_repository.xml
> 4. in test_repository.xml:
>  ENTITY internal SYSTEM "repository_internal.xml"
>   ENTITY user SYSTEM "repository_user.xml"
>       ENTITY schema "$TEST" 
>   ]>
> 5. in user_repository.xml  
>table="CUSTOMER_TABLE">
>   (schema= is the important part. &schema; is the entity defined
> above)
> 
> 6. in my SequenceManagerMSFImpl.getCustomerSeq()
>   ClassDescriptor cld =
> persistanceBroker.getClassDescriptor(CustomerVO.class);
>   String current_env = cld.getSchema()+"."; //will = $TEST or #DSNA
>   then I use current_env to go after a few tables that I need to to
> generate the Seq
>   (notice that I had to add the "." at the end)
> 
> I just thought I would include this info, in case you will need to move
your
> app from dev to test, and go after a different schema.
> 
> Has anyone developed a more elegant solution? I would like to avoid having
> so many files (2 files XX_OJB.props and XX_repository.xml, for each
> environment). This was the best I could come up with.
> 
> -John
> 
> 
>   
> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
> Sent: Thursday, July 10, 2003 10:13 AM
> To: OJB Users List
> Subject: Re: Oracle Connection & Schema Question
> 
> 
> Try this 
> 
>  table="PROJECT_FOO.SOME_TABLE">
> ..
> 
> 
> 
> 
> 
> 
> 
> "Brown, Melonie S. - Contractor" <[EMAIL PROTECTED]>
> 10.07.2003 19:03
> Please respond to "OJB Users List"
>  
> To: "'[EMAIL PROTECTED]'" <[EMAIL PROTECTED]>
> cc: 
> Subject:Oracle Connection & Schema Question
> 
> 
> A directive was handed down by our dba's as follows. . . 
> 
> "There will be a schema called PROJECT_FOO which contains data, views,
> procedures, etc.
> There will be a userid called FOOUSER which will be used by the 
> application
> to do what needs to be doing on the database (read, write).
> In developing code all calls to the database should include the prefix of
> the schema i.e. PROJECT_FOO.myusertable, PROJECT_FOO.mytable, etc."
> 
> Our repository.xml looks like this:
> 
> platform="Oracle"
>  jdbc-level="2.0"
>  driver="com.p6spy.engine.spy.P6SpyDriver"
>  protocol="jdbc"
>  subprotocol="Oracle"  
>  dbalias="thin:@999.999.99.999::SERVER"
>  username="FOOUSER"
>  password="foopassword"
>  jcd-alias="default"
>  default-connection="true" 
>  batch-mode="false"
> useAutoCommit="1"
> ignoreAutoCommitExceptions="false" 
>>
>  
> className="org.apache.ojb.broker.util.sequence.SequenceManagerNextValImpl">
>  
> 
> 
> 
> With OJB, where would the schema be specified?
> 
> -
> 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: Oracle Connection & Schema Question

2003-07-10 Thread McCaffrey, John G.
I also ran into this issue, as well as the need to dynamically change the
schema between environments (development, test, stage, Production - all
point to different databases/schemas)

I solved this using the following
1. each server has a systemProperty "env" that indicates whether it is "dev"
or "test" or "prod"
2. I have an Servlet.init() that calls System.getProperty("env"); and loads
the right OJB and log4J files 

for example when I deploy to the "test" server
3. in test_OJB.properties: 
the repositoryFile =OJB/test_repository.xml
4. in test_repository.xml:


     
    ]>
5. in user_repository.xml  

(schema= is the important part. &schema; is the entity defined
above)

6. in my SequenceManagerMSFImpl.getCustomerSeq()
ClassDescriptor cld =
persistanceBroker.getClassDescriptor(CustomerVO.class);
String current_env = cld.getSchema()+"."; //will = $TEST or #DSNA
then I use current_env to go after a few tables that I need to to
generate the Seq
(notice that I had to add the "." at the end)

I just thought I would include this info, in case you will need to move your
app from dev to test, and go after a different schema.

Has anyone developed a more elegant solution? I would like to avoid having
so many files (2 files XX_OJB.props and XX_repository.xml, for each
environment). This was the best I could come up with.

-John



-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Thursday, July 10, 2003 10:13 AM
To: OJB Users List
Subject: Re: Oracle Connection & Schema Question


Try this 


...







"Brown, Melonie S. - Contractor" <[EMAIL PROTECTED]>
10.07.2003 19:03
Please respond to "OJB Users List"
 
To: "'[EMAIL PROTECTED]'" <[EMAIL PROTECTED]>
cc: 
    Subject:Oracle Connection & Schema Question


A directive was handed down by our dba's as follows. . . 

"There will be a schema called PROJECT_FOO which contains data, views,
procedures, etc.
There will be a userid called FOOUSER which will be used by the 
application
to do what needs to be doing on the database (read, write).
In developing code all calls to the database should include the prefix of
the schema i.e. PROJECT_FOO.myusertable, PROJECT_FOO.mytable, etc."

Our repository.xml looks like this:

  
   
 



With OJB, where would the schema be specified?

-
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]



Oracle Connection & Schema Question

2003-07-10 Thread Brown, Melonie S. - Contractor
Thanks! That seems to be working.
 Original Message 
Subject: Re: Oracle Connection & Schema Question
Date: Thu, 10 Jul 2003 19:13:00 +0400
From: [EMAIL PROTECTED]
Reply-To: OJB Users List <[EMAIL PROTECTED]>
Newsgroups: gmane.comp.jakarta.ojb.user
References:
<[EMAIL PROTECTED]>

Try this 


...


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



Re: Oracle Connection & Schema Question

2003-07-10 Thread Eremiychuk
Try this 


...







"Brown, Melonie S. - Contractor" <[EMAIL PROTECTED]>
10.07.2003 19:03
Please respond to "OJB Users List"
 
To: "'[EMAIL PROTECTED]'" <[EMAIL PROTECTED]>
    cc: 
Subject:Oracle Connection & Schema Question


A directive was handed down by our dba's as follows. . . 

"There will be a schema called PROJECT_FOO which contains data, views,
procedures, etc.
There will be a userid called FOOUSER which will be used by the 
application
to do what needs to be doing on the database (read, write).
In developing code all calls to the database should include the prefix of
the schema i.e. PROJECT_FOO.myusertable, PROJECT_FOO.mytable, etc."

Our repository.xml looks like this:

  
   
 



With OJB, where would the schema be specified?

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




Oracle Connection & Schema Question

2003-07-10 Thread Brown, Melonie S. - Contractor
A directive was handed down by our dba's as follows. . . 

"There will be a schema called PROJECT_FOO which contains data, views,
procedures, etc.
There will be a userid called FOOUSER which will be used by the application
to do what needs to be doing on the database (read, write).
In developing code all calls to the database should include the prefix of
the schema i.e. PROJECT_FOO.myusertable, PROJECT_FOO.mytable, etc."

Our repository.xml looks like this:

  
   
   



With OJB, where would the schema be specified?

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



Schema change at connect time?

2003-04-02 Thread Chris Halverson
I'm copying parts of two separate Oracle databases into (hopefully)
one MySQL database (don't ask, strange business rules are dictating
this). In one of the Oracle databases, they have a public synonym
setup which makes the copying easy. In the other, they do not (and
will not add one), which makes copying hard. I'm using the same
repository_user.xml for both Oracle and MySQL. I've tried adding the
"schema=" to the class-descriptor lines, but then OJB tries to connect
to a different database in MySQL, which is not what I want.

The Oracle DBA says if I could execute:

  ALTER SESSION SET CURRENT_SCHEMA = SYSDBA

at the beginning of my session on Oracle, everything would be fine.

So my questions are:

* Is there a way to execute that SQL at connection time?

* Am I going to be forced to have two separate databases?

If I have to have two databases, it's not really the end of the world,
it's just semi-easier to do it as one.

Thanks!

cdh

-- 
Chris D. Halverson http://www.halverson.org/

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



Re: Cannot create database schema and test data using >build preparetutorials

2003-02-06 Thread Mehmet D. AKIN
Well it says  in the site
"To check if OJB runs properly out of the box execute *|bin\build 
junit|* under Win32 and *|bin/build.sh junit|* under Unix/Linux.
This will launch the OJB regression test suite. If all tests are passed 
the console output looks like follows: 
/jakarta-ojb-XXX/target/test/ojb/OJB.properties]]>/jakarta-ojb-XXX/target/test/ojb/OJB.properties]]>/jakarta-ojb-XXX/target/test/ojb/OJB.properties]]>"

I even could not run bin\build junit
it gives same exception,

in site it says default db is hsqldb and it would run wtihout any 
trouble, am I wrong? I mean what's the procedure just after downloading 
the source code of OJB

thanks in advance

Anthony Kong wrote:

Hi, Mehmet,

I guess the problem is exactly because you did not touch any conf files? :-)

You have to decide which sql database you will run against in the
repository_database.xml. Have you set a proper value there?

Anthony


-Original Message-
From: Mehmet D. AKIN [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, February 05, 2003 7:57 PM
To: OJB Users List
Subject: Cannot create database schema and test data using >build
preparetutorials


I just downloaded source and tried to run bin\build prepare-tutorials, 
it compiles sources but when it comes to database preparation, torque 
gives a series of nullPointerExceptions and it cannot write anything to 
database. I didnt touch any of the configuration files, I use newest 
version of ant and Java JDK1.4.1. Anyone else encountered this problem ?

Here is the some part of the exception:

--
[torque-datasql] Resolver: used database.dtd from 
org.apache.torque.engine.database.transform package
[torque-datasql] Resolver: used 
D:\tools\jakarta-ojb-0.9.8\src\schema\ojbtest-data.dtd
[torque-datasql] java.lang.NullPointerException
[torque-datasql]at 
org.apache.torque.engine.database.transform.XmlToData.startElement(XmlToData
.java:174)
[torque-datasql]at 
org.apache.xerces.parsers.AbstractSAXParser.startElement(AbstractSAXParser.j
ava:454)
[torque-datasql]at 
org.apache.xerces.parsers.AbstractXMLDocumentParser.emptyElement(AbstractXML
DocumentParser.java:217)
[torque-datasql]at 
org.apache.xerces.impl.XMLNamespaceBinder.emptyElement(XMLNamespaceBinder.ja
va:594)
[torque-datasql]at 
org.apache.xerces.impl.dtd.XMLDTDValidator.emptyElement(XMLDTDValidator.java
:777)
[torque-datasql]at 
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanStartElement(XMLDo
cumentFragmentScannerImpl.java:748)
[torque-datasql]at 
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatc
her.dispatch(XMLDocumentFragmentScannerImpl.jav
a:1453)
[torque-datasql]at 
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocume
ntFragmentScannerImpl.java:333)
[torque-datasql]at 
org.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:524)
[torque-datasql]at 
org.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:580)
..
..



-
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: Cannot create database schema and test data using >build preparetutorials

2003-02-05 Thread Anthony Kong
Hi, Mehmet,

I guess the problem is exactly because you did not touch any conf files? :-)

You have to decide which sql database you will run against in the
repository_database.xml. Have you set a proper value there?

Anthony


-Original Message-
From: Mehmet D. AKIN [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, February 05, 2003 7:57 PM
To: OJB Users List
Subject: Cannot create database schema and test data using >build
preparetutorials


I just downloaded source and tried to run bin\build prepare-tutorials, 
it compiles sources but when it comes to database preparation, torque 
gives a series of nullPointerExceptions and it cannot write anything to 
database. I didnt touch any of the configuration files, I use newest 
version of ant and Java JDK1.4.1. Anyone else encountered this problem ?

Here is the some part of the exception:

--
[torque-datasql] Resolver: used database.dtd from 
org.apache.torque.engine.database.transform package
[torque-datasql] Resolver: used 
D:\tools\jakarta-ojb-0.9.8\src\schema\ojbtest-data.dtd
[torque-datasql] java.lang.NullPointerException
[torque-datasql]at 
org.apache.torque.engine.database.transform.XmlToData.startElement(XmlToData
.java:174)
[torque-datasql]at 
org.apache.xerces.parsers.AbstractSAXParser.startElement(AbstractSAXParser.j
ava:454)
[torque-datasql]at 
org.apache.xerces.parsers.AbstractXMLDocumentParser.emptyElement(AbstractXML
DocumentParser.java:217)
[torque-datasql]at 
org.apache.xerces.impl.XMLNamespaceBinder.emptyElement(XMLNamespaceBinder.ja
va:594)
[torque-datasql]at 
org.apache.xerces.impl.dtd.XMLDTDValidator.emptyElement(XMLDTDValidator.java
:777)
[torque-datasql]at 
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanStartElement(XMLDo
cumentFragmentScannerImpl.java:748)
[torque-datasql]at 
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatc
her.dispatch(XMLDocumentFragmentScannerImpl.jav
a:1453)
[torque-datasql]at 
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocume
ntFragmentScannerImpl.java:333)
[torque-datasql]at 
org.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:524)
[torque-datasql]at 
org.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:580)
..
..



-
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]




Cannot create database schema and test data using >build preparetutorials

2003-02-05 Thread Mehmet D. AKIN
I just downloaded source and tried to run bin\build prepare-tutorials, 
it compiles sources but when it comes to database preparation, torque 
gives a series of nullPointerExceptions and it cannot write anything to 
database. I didnt touch any of the configuration files, I use newest 
version of ant and Java JDK1.4.1. Anyone else encountered this problem ?

Here is the some part of the exception:

--
[torque-datasql] Resolver: used database.dtd from 
org.apache.torque.engine.database.transform package
[torque-datasql] Resolver: used 
D:\tools\jakarta-ojb-0.9.8\src\schema\ojbtest-data.dtd
[torque-datasql] java.lang.NullPointerException
[torque-datasql]at 
org.apache.torque.engine.database.transform.XmlToData.startElement(XmlToData.java:174)
[torque-datasql]at 
org.apache.xerces.parsers.AbstractSAXParser.startElement(AbstractSAXParser.java:454)
[torque-datasql]at 
org.apache.xerces.parsers.AbstractXMLDocumentParser.emptyElement(AbstractXMLDocumentParser.java:217)
[torque-datasql]at 
org.apache.xerces.impl.XMLNamespaceBinder.emptyElement(XMLNamespaceBinder.java:594)
[torque-datasql]at 
org.apache.xerces.impl.dtd.XMLDTDValidator.emptyElement(XMLDTDValidator.java:777)
[torque-datasql]at 
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanStartElement(XMLDocumentFragmentScannerImpl.java:748)
[torque-datasql]at 
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(XMLDocumentFragmentScannerImpl.jav
a:1453)
[torque-datasql]at 
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:333)
[torque-datasql]at 
org.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:524)
[torque-datasql]at 
org.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:580)
..
..



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