• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Problem with onetomany relantionship with JPA 2.0

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello everybody, i have a problem with a onetomany relationship, i have a elementostvpaga that can have many canales and a canales class tha can have many elementostvpaga, when in mi view i tried to visualize it i get an error i put my classes and the log with the error, thks.








and the error log, cheers!

GRAVE: Fallo al ejecutar SELECT IdCanal, IdProductosTelecom, T_canales.Nombre from Paquetecanal left join Canales T_canales on Paquetecanal.IdCanal = T_canales.IdCanal WHERE Paquetecanal.IdProductosTelecom = ?

com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException: Column 'IdCanal' in field list is ambiguous at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source) at java.lang.reflect.Constructor.newInstance(Unknown Source) at com.mysql.jdbc.Util.handleNewInstance(Util.java:406) at com.mysql.jdbc.Util.getInstance(Util.java:381) at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1015) at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:956) at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3558) at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3490) at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1959) at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2109) at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2643) at com.mysql.jdbc.PreparedStatement.executeInternal(PreparedStatement.java:2077) at com.mysql.jdbc.PreparedStatement.executeQuery(PreparedStatement.java:2228) at org.apache.tomcat.dbcp.dbcp.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:92) at org.openxava.tab.impl.JDBCTabProvider.nextBlock(JDBCTabProvider.java:235) at org.openxava.tab.impl.JDBCTabProvider.nextChunk(JDBCTabProvider.java:258) at org.openxava.tab.impl.EntityTabDataProvider.nextChunk(EntityTabDataProvider.java:35) at org.openxava.tab.impl.EntityTab.nextChunk(EntityTab.java:298) at org.openxava.tab.impl.TableModelBean.getRow(TableModelBean.java:120) at org.openxava.tab.impl.TableModelBean.getValueAt(TableModelBean.java:171) at org.openxava.tab.impl.XTableModelDecoratorBase.getValueAt(XTableModelDecoratorBase.java:63) at org.openxava.tab.impl.HiddenXTableModel.getValueAt(HiddenXTableModel.java:70) at
 
ranger
Posts: 17347
11
Mac IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
OK, please don't duplicate post the same question. Although I like the CODE tags look here in this thread, so i am going to close the other one, but look at my last reply and reply to that here.

Thanks

Mark
 
Diego Armando Zarate Diaz
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ok, i read your response at the another post, i post again for the information was cleareast, sorry for the inconvenients. And thks for your time.

Cheers!
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic