Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF "Technology" (Ecore Tools, EMFatic, etc)  » [Teneo] Error with generated FK name, name too long
[Teneo] Error with generated FK name, name too long [message #82090] Sat, 05 May 2007 14:44 Go to next message
Alain Picard is currently offline Alain PicardFriend
Messages: 235
Registered: July 2009
Senior Member
Martin,

I am getting the following errors when trying to get one of my ecore
model initialized with the table_per_class strategy:

SchemaUpdate.java: 155 : Unsuccessful: alter table `xmlall` add index
FK315EF3B3B4B9A2E8c5350b174b5c68cd4745c1713725705c4ee2773d2f 81e2a
(`modelelement_stereotype_e_id`), add constraint
FK315EF3B3B4B9A2E8c5350b174b5c68cd4745c1713725705c4ee2773d2f 81e2a
foreign key (`modelelement_stereotype_e_id`) references `stereotype` (e_id)
ERROR [04 May 2007 09:50] SchemaUpdate.java: 155 : Unsuccessful: alter
table `xmlall` add index
FK315EF3B3B4B9A2E8c5350b174b5c68cd4745c1713725705c4ee2773d2f 81e2a
(`modelelement_stereotype_e_id`), add constraint
FK315EF3B3B4B9A2E8c5350b174b5c68cd4745c1713725705c4ee2773d2f 81e2a
foreign key (`modelelement_stereotype_e_id`) references `stereotype` (e_id)
ERROR [04 May 2007 09:50] SchemaUpdate.java: 156 : Identifier name
'FK315EF3B3B4B9A2E8c5350b174b5c68cd4745c1713725705c4ee2773d2 f81e2a' is
too long
ERROR [04 May 2007 09:50] SchemaUpdate.java: 156 : Identifier name
'FK315EF3B3B4B9A2E8c5350b174b5c68cd4745c1713725705c4ee2773d2 f81e2a' is
too long

I saw a method in PersistenceOptions, getMaximumSqlNameLength, would
that help avoid this?

Also is there possible to implement a different naming strategy for FK
names that would be more meaningful?

Thanks
Alain
Re: [Teneo] Error with generated FK name, name too long [message #82190 is a reply to message #82090] Sun, 06 May 2007 13:40 Go to previous message
Martin Taal is currently offline Martin TaalFriend
Messages: 5468
Registered: July 2009
Senior Member
Alain,
Currently Teneo does not generate the foreign-key name this is done by hibernate.
Please enter a bugzilla for this (with the addition that the fk-naming should be customizable).

gr. Martin.

Alain Picard wrote:
> Martin,
>
> I am getting the following errors when trying to get one of my ecore
> model initialized with the table_per_class strategy:
>
> SchemaUpdate.java: 155 : Unsuccessful: alter table `xmlall` add index
> FK315EF3B3B4B9A2E8c5350b174b5c68cd4745c1713725705c4ee2773d2f 81e2a
> (`modelelement_stereotype_e_id`), add constraint
> FK315EF3B3B4B9A2E8c5350b174b5c68cd4745c1713725705c4ee2773d2f 81e2a
> foreign key (`modelelement_stereotype_e_id`) references `stereotype` (e_id)
> ERROR [04 May 2007 09:50] SchemaUpdate.java: 155 : Unsuccessful: alter
> table `xmlall` add index
> FK315EF3B3B4B9A2E8c5350b174b5c68cd4745c1713725705c4ee2773d2f 81e2a
> (`modelelement_stereotype_e_id`), add constraint
> FK315EF3B3B4B9A2E8c5350b174b5c68cd4745c1713725705c4ee2773d2f 81e2a
> foreign key (`modelelement_stereotype_e_id`) references `stereotype` (e_id)
> ERROR [04 May 2007 09:50] SchemaUpdate.java: 156 : Identifier name
> 'FK315EF3B3B4B9A2E8c5350b174b5c68cd4745c1713725705c4ee2773d2 f81e2a' is
> too long
> ERROR [04 May 2007 09:50] SchemaUpdate.java: 156 : Identifier name
> 'FK315EF3B3B4B9A2E8c5350b174b5c68cd4745c1713725705c4ee2773d2 f81e2a' is
> too long
>
> I saw a method in PersistenceOptions, getMaximumSqlNameLength, would
> that help avoid this?
>
> Also is there possible to implement a different naming strategy for FK
> names that would be more meaningful?
>
> Thanks
> Alain


--

With Regards, Martin Taal

Springsite/Elver.org
Office: Hardwareweg 4, 3821 BV Amersfoort
Postal: Nassaulaan 7, 3941 EC Doorn
The Netherlands
Tel: +31 (0)84 420 2397
Fax: +31 (0)84 225 9307
Mail: mtaal@springsite.com - mtaal@elver.org
Web: www.springsite.com - www.elver.org
Re: [Teneo] Error with generated FK name, name too long [message #605311 is a reply to message #82090] Sun, 06 May 2007 13:40 Go to previous message
Martin Taal is currently offline Martin TaalFriend
Messages: 5468
Registered: July 2009
Senior Member
Alain,
Currently Teneo does not generate the foreign-key name this is done by hibernate.
Please enter a bugzilla for this (with the addition that the fk-naming should be customizable).

gr. Martin.

Alain Picard wrote:
> Martin,
>
> I am getting the following errors when trying to get one of my ecore
> model initialized with the table_per_class strategy:
>
> SchemaUpdate.java: 155 : Unsuccessful: alter table `xmlall` add index
> FK315EF3B3B4B9A2E8c5350b174b5c68cd4745c1713725705c4ee2773d2f 81e2a
> (`modelelement_stereotype_e_id`), add constraint
> FK315EF3B3B4B9A2E8c5350b174b5c68cd4745c1713725705c4ee2773d2f 81e2a
> foreign key (`modelelement_stereotype_e_id`) references `stereotype` (e_id)
> ERROR [04 May 2007 09:50] SchemaUpdate.java: 155 : Unsuccessful: alter
> table `xmlall` add index
> FK315EF3B3B4B9A2E8c5350b174b5c68cd4745c1713725705c4ee2773d2f 81e2a
> (`modelelement_stereotype_e_id`), add constraint
> FK315EF3B3B4B9A2E8c5350b174b5c68cd4745c1713725705c4ee2773d2f 81e2a
> foreign key (`modelelement_stereotype_e_id`) references `stereotype` (e_id)
> ERROR [04 May 2007 09:50] SchemaUpdate.java: 156 : Identifier name
> 'FK315EF3B3B4B9A2E8c5350b174b5c68cd4745c1713725705c4ee2773d2 f81e2a' is
> too long
> ERROR [04 May 2007 09:50] SchemaUpdate.java: 156 : Identifier name
> 'FK315EF3B3B4B9A2E8c5350b174b5c68cd4745c1713725705c4ee2773d2 f81e2a' is
> too long
>
> I saw a method in PersistenceOptions, getMaximumSqlNameLength, would
> that help avoid this?
>
> Also is there possible to implement a different naming strategy for FK
> names that would be more meaningful?
>
> Thanks
> Alain


--

With Regards, Martin Taal

Springsite/Elver.org
Office: Hardwareweg 4, 3821 BV Amersfoort
Postal: Nassaulaan 7, 3941 EC Doorn
The Netherlands
Tel: +31 (0)84 420 2397
Fax: +31 (0)84 225 9307
Mail: mtaal@springsite.com - mtaal@elver.org
Web: www.springsite.com - www.elver.org
Previous Topic:Using "external" library in JET template
Next Topic:[Teneo] Help needed with inherance mapping
Goto Forum:
  


Current Time: Thu Jan 21 15:40:25 GMT 2021

Powered by FUDForum. Page generated in 0.01789 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top