Discussion:
[castor-dev] [Fwd: Re: Varchar length support?]
Ralf Joachim
2009-06-02 14:04:32 UTC
Permalink
Forwarding this discussion to dev list as we need to know Werner's point
of view.

Ralf
--
Syscon Ingenieurbüro für Meß- und Datentechnik GmbH
Ralf Joachim
Raiffeisenstraße 11
72127 Kusterdingen
Germany

Tel. +49 7071 3690 52
Mobil: +49 173 9630135
Fax +49 7071 3690 98

Internet: www.syscon.eu
E-Mail: ***@syscon.eu

Sitz der Gesellschaft: D-72127 Kusterdingen
Registereintrag: Amtsgericht Stuttgart, HRB 382295
Geschäftsleitung: Jens Joachim, Ralf Joachim
Werner Guttmann
2009-06-10 18:21:59 UTC
Permalink
Hi Ralf,

I have just re-read the complete issue .. ;-). How do we want to
approach this ?

Werner
Post by Ralf Joachim
Forwarding this discussion to dev list as we need to know Werner's point
of view.
Ralf
------------------------------------------------------------------------
Re: Varchar length support?
Tue, 2 Jun 2009 15:35:03 +0200
Ralf,
I have read here (http://jira.codehaus.org/browse/CASTOR-1527) that there is some kind of patch? Does this patch works?
Can you give an estimate when these attributes, like length and defaults, will be available by DDL gen? ( I'am not a good programmer otherwise i would give it a try. )
Regards,
Adis
From: Ralf Joachim
Sent: Tuesday, June 02, 2009 11:12 AM
To: Adis Corovic
Subject: Re: Varchar length support?
Hi Adis,
http://jira.codehaus.org/secure/IssueNavigator.jspa?reset=true&mode=hide&pid=10891&sorter/order=DESC&sorter/field=priority&resolution=-1&component=12341
http://jira.codehaus.org/browse/CASTOR-1527
According to this you are not able to specify length of varchar fields in mapping yet.
Regards
Ralf
Hi Ralf ,
<class name="Mijn test2">
<map-to table="Mijn Tabel2"/>
<field name="Code" type="Integer" required="true" identity="true">
<sql name="Code"/>
</field>
<field name="Naam" type="varchar" required="true">
<sql name="Naam"/>
</field>
</class>It always takes my default length (256), but I want to second column to be varchar(10). How can I accomplish this?Can you please reply to this?Sorry that I am disturbing you..Regards,Adis
From: Ralf Joachim
Sent: Friday, May 29, 2009 3:35 PM
To: Adis Corovic
Subject: Re: Information about Castor DDL Gen
Hi Adis,
at the moment DDLGEN does only support generation of DDL scripts form mapping files. While we have already added support to read mapping informations from annotated java classes to our persistence engine, using this annotations to generate DDL scripts is not available yet. Having said that I would not see a chance to generate usefull DDL scripts from java classes without annotations.
Regards
Ralf
Hello Ralf,
I have read that you are one of the contributors of Castor DDL Generator.
Therefore I want to ask you something;
Is it possible to generate DDL code from something else than a mapping file of XML?
The reason I am asking this: for my study I chosen DDL generation as a thema. So I am investigating how DDL genration could be established.
Is it possible to generate from a Java Class DDL script trough your DDL generator?
Thanks in advance,
Best regards,
Adis Corovic
Nijmegen, The Netherlands
------------------------------------------------------------------------
---------------------------------------------------------------------
http://xircles.codehaus.org/manage_email
---------------------------------------------------------------------
To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email
Ralf Joachim
2009-06-10 19:16:56 UTC
Permalink
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
<title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
Hi Werner,<br>
<br>
I would add new optional attributes with same namespace to our current
mapping.<br>
<br>
at map-to element consistent with table annotation of JPA 2.0 spec<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;xsd:attribute name="schema"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; type="xsd:NMTOKENS"&nbsp;
use="optional" default=""/&gt;<br>
<br>
at sql element consistent column annotation of JPA 2.0 spec<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;xsd:attribute name="length"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; type="xsd:integer"&nbsp;&nbsp;
use="optional" default="255"/&gt;<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;xsd:attribute name="precision"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; type="xsd:integer"&nbsp;&nbsp;
use="optional" default="0"/&gt;<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;xsd:attribute name="scale"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
type="xsd:integer"&nbsp;&nbsp; use="optional" default="0"/&gt;<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;xsd:attribute name="nullable"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; type="xsd:boolean"&nbsp;&nbsp;
use="optional" default="true"/&gt;<br>
<br>
If this is fine with you I can support Adis how to implement this
feature or go for this myself. If you prefer the solution to have a
different namespace for these new attributes, you will at least need to
provide some initial code for us to start how this should be
implemented.<br>
<br>
Regards<br>
Ralf<br>
<br>
Werner Guttmann schrieb:
<blockquote cite="mid:***@gmx.net" type="cite">
<pre wrap="">Hi Ralf,

I have just re-read the complete issue .. ;-). How do we want to
approach this ?

Werner

Ralf Joachim wrote:
</pre>
<blockquote type="cite">
<pre wrap="">Forwarding this discussion to dev list as we need to know Werner's point
of view.

Ralf


------------------------------------------------------------------------

Subject:
Re: Varchar length support?
From:
"Adis Corovic" <a class="moz-txt-link-rfc2396E" href="mailto:***@live.nl">&lt;***@live.nl&gt;</a>
Date:
Tue, 2 Jun 2009 15:35:03 +0200
To:
"Ralf Joachim" <a class="moz-txt-link-rfc2396E" href="mailto:***@syscon.eu">&lt;***@syscon.eu&gt;</a>

To:
"Ralf Joachim" <a class="moz-txt-link-rfc2396E" href="mailto:***@syscon.eu">&lt;***@syscon.eu&gt;</a>


Ralf,

I'm sorry that I am bothering you but still I have some questions:
I have read here (<a class="moz-txt-link-freetext" href="http://jira.codehaus.org/browse/CASTOR-1527">http://jira.codehaus.org/browse/CASTOR-1527</a>) that there is some kind of patch? Does this patch works?

Can you give an estimate when these attributes, like length and defaults, will be available by DDL gen? ( I'am not a good programmer otherwise i would give it a try. )

Regards,

Adis


From: Ralf Joachim
Sent: Tuesday, June 02, 2009 11:12 AM
To: Adis Corovic
Subject: Re: Varchar length support?


Hi Adis,

there are a few issues in jira about improvements and refactorings required at DDLGEN. Take a look at:

<a class="moz-txt-link-freetext" href="http://jira.codehaus.org/secure/IssueNavigator.jspa?reset=true&mode=hide&pid=10891&sorter/order=DESC&sorter/field=priority&resolution=-1&component=12341">http://jira.codehaus.org/secure/IssueNavigator.jspa?reset=true&amp;mode=hide&amp;pid=10891&amp;sorter/order=DESC&amp;sorter/field=priority&amp;resolution=-1&amp;component=12341</a>

One of this issues is a feature request to add specification of field length to our mapping: See:

<a class="moz-txt-link-freetext" href="http://jira.codehaus.org/browse/CASTOR-1527">http://jira.codehaus.org/browse/CASTOR-1527</a>

According to this you are not able to specify length of varchar fields in mapping yet.

Regards
Ralf


Adis Corovic schrieb:
Hi Ralf ,

I was examing the samples an do some testing and have a question regarding the length of varchar datattype. I could find out how to give the length of my varchar field in mappin.xml:
&lt;class name="Mijn test2"&gt;
&lt;map-to table="Mijn Tabel2"/&gt;
&lt;field name="Code" type="Integer" required="true" identity="true"&gt;
&lt;sql name="Code"/&gt;
&lt;/field&gt;
&lt;field name="Naam" type="varchar" required="true"&gt;
&lt;sql name="Naam"/&gt;
&lt;/field&gt;
&lt;/class&gt;It always takes my default length (256), but I want to second column to be varchar(10). How can I accomplish this?Can you please reply to this?Sorry that I am disturbing you..Regards,Adis

From: Ralf Joachim
Sent: Friday, May 29, 2009 3:35 PM
To: Adis Corovic
Subject: Re: Information about Castor DDL Gen


Hi Adis,

at the moment DDLGEN does only support generation of DDL scripts form mapping files. While we have already added support to read mapping informations from annotated java classes to our persistence engine, using this annotations to generate DDL scripts is not available yet. Having said that I would not see a chance to generate usefull DDL scripts from java classes without annotations.

Regards
Ralf

Adis Corovic schrieb:
Hello Ralf,

I have read that you are one of the contributors of Castor DDL Generator.
Therefore I want to ask you something;
Is it possible to generate DDL code from something else than a mapping file of XML?
The reason I am asking this: for my study I chosen DDL generation as a thema. So I am investigating how DDL genration could be established.

Is it possible to generate from a Java Class DDL script trough your DDL generator?

Thanks in advance,
Best regards,

Adis Corovic
Nijmegen, The Netherlands




------------------------------------------------------------------------

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

<a class="moz-txt-link-freetext" href="http://xircles.codehaus.org/manage_email">http://xircles.codehaus.org/manage_email</a>
</pre>
</blockquote>
<pre wrap=""><!---->
---------------------------------------------------------------------
To unsubscribe from this list, please visit:

<a class="moz-txt-link-freetext" href="http://xircles.codehaus.org/manage_email">http://xircles.codehaus.org/manage_email</a>


</pre>
</blockquote>
<br>
<pre class="moz-signature" cols="72">--

Syscon Ingenieurb&uuml;ro f&uuml;r Me&szlig;- und Datentechnik GmbH
Ralf Joachim
Raiffeisenstra&szlig;e 11
72127 Kusterdingen
Germany

Tel. +49 7071 3690 52
Mobil: +49 173 9630135
Fax +49 7071 3690 98

Internet: <a class="moz-txt-link-abbreviated" href="http://www.syscon.eu">www.syscon.eu</a>
E-Mail: <a class="moz-txt-link-abbreviated" href="mailto:***@syscon.eu">***@syscon.eu</a>

Sitz der Gesellschaft: D-72127 Kusterdingen
Registereintrag: Amtsgericht Stuttgart, HRB 382295
Gesch&auml;ftsleitung: Jens Joachim, Ralf Joachim
</pre>
</body>
</html>

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email
Werner Guttmann
2009-06-11 10:54:20 UTC
Permalink
Hi,

let's go for the easy approach for the time being. A few things, though:

a) I still think positively of introducing namespaces to the mapping
file. And yes, there will have to be some progress on e.g.
<anyAttributes> first.
b) Time is very limited right now (for me, at least), due to several
reasons (commercial projects including).
c) I am spending a lot of time making the (partial) support for JPA
annotations ready to be committed. And I think it won't be long.
d) And can we narrow down the types of those new attributes, e.g. use
<xs:positivInteger> wherever possible or use narrower types (short
instead of integer).

Can I take it that whoever works on this will have to extend the
JDO-specific natures for the Class-|FieldDescriptor classes ?

Cheers
Werner
Post by Ralf Joachim
Hi Werner,
I would add new optional attributes with same namespace to our current
mapping.
at map-to element consistent with table annotation of JPA 2.0 spec
<xsd:attribute name="schema" type="xsd:NMTOKENS"
use="optional" default=""/>
at sql element consistent column annotation of JPA 2.0 spec
<xsd:attribute name="length" type="xsd:integer"
use="optional" default="255"/>
<xsd:attribute name="precision" type="xsd:integer"
use="optional" default="0"/>
<xsd:attribute name="scale" type="xsd:integer"
use="optional" default="0"/>
<xsd:attribute name="nullable" type="xsd:boolean"
use="optional" default="true"/>
If this is fine with you I can support Adis how to implement this
feature or go for this myself. If you prefer the solution to have a
different namespace for these new attributes, you will at least need to
provide some initial code for us to start how this should be implemented.
Regards
Ralf
Post by Werner Guttmann
Hi Ralf,
I have just re-read the complete issue .. ;-). How do we want to
approach this ?
Werner
Post by Ralf Joachim
Forwarding this discussion to dev list as we need to know Werner's point
of view.
Ralf
------------------------------------------------------------------------
Re: Varchar length support?
Tue, 2 Jun 2009 15:35:03 +0200
Ralf,
I have read here (http://jira.codehaus.org/browse/CASTOR-1527) that there is some kind of patch? Does this patch works?
Can you give an estimate when these attributes, like length and defaults, will be available by DDL gen? ( I'am not a good programmer otherwise i would give it a try. )
Regards,
Adis
From: Ralf Joachim
Sent: Tuesday, June 02, 2009 11:12 AM
To: Adis Corovic
Subject: Re: Varchar length support?
Hi Adis,
http://jira.codehaus.org/secure/IssueNavigator.jspa?reset=true&mode=hide&pid=10891&sorter/order=DESC&sorter/field=priority&resolution=-1&component=12341
http://jira.codehaus.org/browse/CASTOR-1527
According to this you are not able to specify length of varchar fields in mapping yet.
Regards
Ralf
Hi Ralf ,
<class name="Mijn test2">
<map-to table="Mijn Tabel2"/>
<field name="Code" type="Integer" required="true" identity="true">
<sql name="Code"/>
</field>
<field name="Naam" type="varchar" required="true">
<sql name="Naam"/>
</field>
</class>It always takes my default length (256), but I want to second column to be varchar(10). How can I accomplish this?Can you please reply to this?Sorry that I am disturbing you..Regards,Adis
From: Ralf Joachim
Sent: Friday, May 29, 2009 3:35 PM
To: Adis Corovic
Subject: Re: Information about Castor DDL Gen
Hi Adis,
at the moment DDLGEN does only support generation of DDL scripts form mapping files. While we have already added support to read mapping informations from annotated java classes to our persistence engine, using this annotations to generate DDL scripts is not available yet. Having said that I would not see a chance to generate usefull DDL scripts from java classes without annotations.
Regards
Ralf
Hello Ralf,
I have read that you are one of the contributors of Castor DDL Generator.
Therefore I want to ask you something;
Is it possible to generate DDL code from something else than a mapping file of XML?
The reason I am asking this: for my study I chosen DDL generation as a thema. So I am investigating how DDL genration could be established.
Is it possible to generate from a Java Class DDL script trough your DDL generator?
Thanks in advance,
Best regards,
Adis Corovic
Nijmegen, The Netherlands
------------------------------------------------------------------------
---------------------------------------------------------------------
http://xircles.codehaus.org/manage_email
---------------------------------------------------------------------
http://xircles.codehaus.org/manage_email
--
Syscon Ingenieurbüro für Meß- und Datentechnik GmbH
Ralf Joachim
Raiffeisenstraße 11
72127 Kusterdingen
Germany
Tel. +49 7071 3690 52
Mobil: +49 173 9630135
Fax +49 7071 3690 98
Internet: www.syscon.eu
Sitz der Gesellschaft: D-72127 Kusterdingen
Registereintrag: Amtsgericht Stuttgart, HRB 382295
Geschäftsleitung: Jens Joachim, Ralf Joachim
--------------------------------------------------------------------- To
http://xircles.codehaus.org/manage_email
---------------------------------------------------------------------
To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email
Ralf Joachim
2009-06-11 11:19:16 UTC
Permalink
Hi Werner,

will norrow types of the new attributes as much as possible.

at map-to element consistent with table annotation of JPA 2.0 spec
<xsd:attribute name="schema" type="xsd:NMTOKENS"
use="optional" default=""/>

at sql element consistent column annotation of JPA 2.0 spec
<xsd:attribute name="length" type="xsd:unsignedShort"
use="optional" default="255"/>
<xsd:attribute name="precision" type="xsd:unsignedByte"
use="optional" default="0"/>
<xsd:attribute name="scale" type="xsd:unsignedByte"
use="optional" default="0"/>
<xsd:attribute name="nullable" type="xsd:boolean"
use="optional" default="true"/>

Are these definitions okay with you?

DDLGEN does not use descriptors yet. Instead DDLGEN directly accesses
Class-/FieldMapping at the moment. Therefore at
http://jira.codehaus.org/browse/CASTOR-1527 I don't intend to extend JDO
natures and add new attributes to descriptors. But there is issue
http://jira.codehaus.org/browse/CASTOR-1526 to use descriptors instead
of mapping classes. At this issue one will need to add the JDO natures.
After this we could also target to retrieve the informations for DDLGEN
from annotations.

P.S. will add the whole communication to the issue

Regards
Ralf
Post by Werner Guttmann
Hi,
a) I still think positively of introducing namespaces to the mapping
file. And yes, there will have to be some progress on e.g.
<anyAttributes> first.
b) Time is very limited right now (for me, at least), due to several
reasons (commercial projects including).
c) I am spending a lot of time making the (partial) support for JPA
annotations ready to be committed. And I think it won't be long.
d) And can we narrow down the types of those new attributes, e.g. use
<xs:positivInteger> wherever possible or use narrower types (short
instead of integer).
Can I take it that whoever works on this will have to extend the
JDO-specific natures for the Class-|FieldDescriptor classes ?
Cheers
Werner
Post by Ralf Joachim
Hi Werner,
I would add new optional attributes with same namespace to our current
mapping.
at map-to element consistent with table annotation of JPA 2.0 spec
<xsd:attribute name="schema" type="xsd:NMTOKENS"
use="optional" default=""/>
at sql element consistent column annotation of JPA 2.0 spec
<xsd:attribute name="length" type="xsd:integer"
use="optional" default="255"/>
<xsd:attribute name="precision" type="xsd:integer"
use="optional" default="0"/>
<xsd:attribute name="scale" type="xsd:integer"
use="optional" default="0"/>
<xsd:attribute name="nullable" type="xsd:boolean"
use="optional" default="true"/>
If this is fine with you I can support Adis how to implement this
feature or go for this myself. If you prefer the solution to have a
different namespace for these new attributes, you will at least need to
provide some initial code for us to start how this should be implemented.
Regards
Ralf
Post by Werner Guttmann
Hi Ralf,
I have just re-read the complete issue .. ;-). How do we want to
approach this ?
Werner
Post by Ralf Joachim
Forwarding this discussion to dev list as we need to know Werner's point
of view.
Ralf
------------------------------------------------------------------------
Re: Varchar length support?
Tue, 2 Jun 2009 15:35:03 +0200
Ralf,
I have read here (http://jira.codehaus.org/browse/CASTOR-1527) that there is some kind of patch? Does this patch works?
Can you give an estimate when these attributes, like length and defaults, will be available by DDL gen? ( I'am not a good programmer otherwise i would give it a try. )
Regards,
Adis
From: Ralf Joachim
Sent: Tuesday, June 02, 2009 11:12 AM
To: Adis Corovic
Subject: Re: Varchar length support?
Hi Adis,
http://jira.codehaus.org/secure/IssueNavigator.jspa?reset=true&mode=hide&pid=10891&sorter/order=DESC&sorter/field=priority&resolution=-1&component=12341
http://jira.codehaus.org/browse/CASTOR-1527
According to this you are not able to specify length of varchar fields in mapping yet.
Regards
Ralf
Hi Ralf ,
<class name="Mijn test2">
<map-to table="Mijn Tabel2"/>
<field name="Code" type="Integer" required="true" identity="true">
<sql name="Code"/>
</field>
<field name="Naam" type="varchar" required="true">
<sql name="Naam"/>
</field>
</class>It always takes my default length (256), but I want to second column to be varchar(10). How can I accomplish this?Can you please reply to this?Sorry that I am disturbing you..Regards,Adis
From: Ralf Joachim
Sent: Friday, May 29, 2009 3:35 PM
To: Adis Corovic
Subject: Re: Information about Castor DDL Gen
Hi Adis,
at the moment DDLGEN does only support generation of DDL scripts form mapping files. While we have already added support to read mapping informations from annotated java classes to our persistence engine, using this annotations to generate DDL scripts is not available yet. Having said that I would not see a chance to generate usefull DDL scripts from java classes without annotations.
Regards
Ralf
Hello Ralf,
I have read that you are one of the contributors of Castor DDL Generator.
Therefore I want to ask you something;
Is it possible to generate DDL code from something else than a mapping file of XML?
The reason I am asking this: for my study I chosen DDL generation as a thema. So I am investigating how DDL genration could be established.
Is it possible to generate from a Java Class DDL script trough your DDL generator?
Thanks in advance,
Best regards,
Adis Corovic
Nijmegen, The Netherlands
------------------------------------------------------------------------
---------------------------------------------------------------------
http://xircles.codehaus.org/manage_email
---------------------------------------------------------------------
http://xircles.codehaus.org/manage_email
--
Syscon Ingenieurbüro für Meß- und Datentechnik GmbH
Ralf Joachim
Raiffeisenstraße 11
72127 Kusterdingen
Germany
Tel. +49 7071 3690 52
Mobil: +49 173 9630135
Fax +49 7071 3690 98
Internet: www.syscon.eu
Sitz der Gesellschaft: D-72127 Kusterdingen
Registereintrag: Amtsgericht Stuttgart, HRB 382295
Geschäftsleitung: Jens Joachim, Ralf Joachim
--------------------------------------------------------------------- To
http://xircles.codehaus.org/manage_email
---------------------------------------------------------------------
http://xircles.codehaus.org/manage_email
--
Syscon Ingenieurbüro für Meß- und Datentechnik GmbH
Ralf Joachim
Raiffeisenstraße 11
72127 Kusterdingen
Germany

Tel. +49 7071 3690 52
Mobil: +49 173 9630135
Fax +49 7071 3690 98

Internet: www.syscon.eu
E-Mail: ***@syscon.eu

Sitz der Gesellschaft: D-72127 Kusterdingen
Registereintrag: Amtsgericht Stuttgart, HRB 382295
Geschäftsleitung: Jens Joachim, Ralf Joachim




---------------------------------------------------------------------
To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email
Werner Guttmann
2009-06-11 12:04:35 UTC
Permalink
Fine by me.

Werner
Post by Ralf Joachim
Hi Werner,
will norrow types of the new attributes as much as possible.
at map-to element consistent with table annotation of JPA 2.0 spec
<xsd:attribute name="schema" type="xsd:NMTOKENS"
use="optional" default=""/>
at sql element consistent column annotation of JPA 2.0 spec
<xsd:attribute name="length" type="xsd:unsignedShort"
use="optional" default="255"/>
<xsd:attribute name="precision" type="xsd:unsignedByte"
use="optional" default="0"/>
<xsd:attribute name="scale" type="xsd:unsignedByte"
use="optional" default="0"/>
<xsd:attribute name="nullable" type="xsd:boolean"
use="optional" default="true"/>
Are these definitions okay with you?
DDLGEN does not use descriptors yet. Instead DDLGEN directly accesses
Class-/FieldMapping at the moment. Therefore at
http://jira.codehaus.org/browse/CASTOR-1527 I don't intend to extend JDO
natures and add new attributes to descriptors. But there is issue
http://jira.codehaus.org/browse/CASTOR-1526 to use descriptors instead
of mapping classes. At this issue one will need to add the JDO natures.
After this we could also target to retrieve the informations for DDLGEN
from annotations.
P.S. will add the whole communication to the issue
Regards
Ralf
Post by Werner Guttmann
Hi,
a) I still think positively of introducing namespaces to the mapping
file. And yes, there will have to be some progress on e.g.
<anyAttributes> first.
b) Time is very limited right now (for me, at least), due to several
reasons (commercial projects including).
c) I am spending a lot of time making the (partial) support for JPA
annotations ready to be committed. And I think it won't be long.
d) And can we narrow down the types of those new attributes, e.g. use
<xs:positivInteger> wherever possible or use narrower types (short
instead of integer).
Can I take it that whoever works on this will have to extend the
JDO-specific natures for the Class-|FieldDescriptor classes ?
Cheers
Werner
Post by Ralf Joachim
Hi Werner,
I would add new optional attributes with same namespace to our current
mapping.
at map-to element consistent with table annotation of JPA 2.0 spec
<xsd:attribute name="schema" type="xsd:NMTOKENS"
use="optional" default=""/>
at sql element consistent column annotation of JPA 2.0 spec
<xsd:attribute name="length" type="xsd:integer"
use="optional" default="255"/>
<xsd:attribute name="precision" type="xsd:integer"
use="optional" default="0"/>
<xsd:attribute name="scale" type="xsd:integer"
use="optional" default="0"/>
<xsd:attribute name="nullable" type="xsd:boolean"
use="optional" default="true"/>
If this is fine with you I can support Adis how to implement this
feature or go for this myself. If you prefer the solution to have a
different namespace for these new attributes, you will at least need to
provide some initial code for us to start how this should be implemented.
Regards
Ralf
Post by Werner Guttmann
Hi Ralf,
I have just re-read the complete issue .. ;-). How do we want to
approach this ?
Werner
Post by Ralf Joachim
Forwarding this discussion to dev list as we need to know Werner's point
of view.
Ralf
------------------------------------------------------------------------
Re: Varchar length support?
Tue, 2 Jun 2009 15:35:03 +0200
Ralf,
I have read here (http://jira.codehaus.org/browse/CASTOR-1527) that there is some kind of patch? Does this patch works?
Can you give an estimate when these attributes, like length and defaults, will be available by DDL gen? ( I'am not a good programmer otherwise i would give it a try. )
Regards,
Adis
From: Ralf Joachim
Sent: Tuesday, June 02, 2009 11:12 AM
To: Adis Corovic
Subject: Re: Varchar length support?
Hi Adis,
http://jira.codehaus.org/secure/IssueNavigator.jspa?reset=true&mode=hide&pid=10891&sorter/order=DESC&sorter/field=priority&resolution=-1&component=12341
http://jira.codehaus.org/browse/CASTOR-1527
According to this you are not able to specify length of varchar fields in mapping yet.
Regards
Ralf
Hi Ralf ,
<class name="Mijn test2">
<map-to table="Mijn Tabel2"/>
<field name="Code" type="Integer" required="true" identity="true">
<sql name="Code"/>
</field>
<field name="Naam" type="varchar" required="true">
<sql name="Naam"/>
</field>
</class>It always takes my default length (256), but I want to second column to be varchar(10). How can I accomplish this?Can you please reply to this?Sorry that I am disturbing you..Regards,Adis
From: Ralf Joachim
Sent: Friday, May 29, 2009 3:35 PM
To: Adis Corovic
Subject: Re: Information about Castor DDL Gen
Hi Adis,
at the moment DDLGEN does only support generation of DDL scripts form mapping files. While we have already added support to read mapping informations from annotated java classes to our persistence engine, using this annotations to generate DDL scripts is not available yet. Having said that I would not see a chance to generate usefull DDL scripts from java classes without annotations.
Regards
Ralf
Hello Ralf,
I have read that you are one of the contributors of Castor DDL Generator.
Therefore I want to ask you something;
Is it possible to generate DDL code from something else than a mapping file of XML?
The reason I am asking this: for my study I chosen DDL generation as a thema. So I am investigating how DDL genration could be established.
Is it possible to generate from a Java Class DDL script trough your DDL generator?
Thanks in advance,
Best regards,
Adis Corovic
Nijmegen, The Netherlands
------------------------------------------------------------------------
---------------------------------------------------------------------
http://xircles.codehaus.org/manage_email
---------------------------------------------------------------------
http://xircles.codehaus.org/manage_email
--
Syscon Ingenieurbüro für Meß- und Datentechnik GmbH
Ralf Joachim
Raiffeisenstraße 11
72127 Kusterdingen
Germany
Tel. +49 7071 3690 52
Mobil: +49 173 9630135
Fax +49 7071 3690 98
Internet: www.syscon.eu
Sitz der Gesellschaft: D-72127 Kusterdingen
Registereintrag: Amtsgericht Stuttgart, HRB 382295
Geschäftsleitung: Jens Joachim, Ralf Joachim
--------------------------------------------------------------------- To
http://xircles.codehaus.org/manage_email
---------------------------------------------------------------------
http://xircles.codehaus.org/manage_email
---------------------------------------------------------------------
To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email

Loading...