• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Entity beans and foreign keys

 
Irsan Saparianto
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I'm having problems with Entity Beans. The problem is, i cannot insert any row (using ejbCreate) to a table that has a foreign key coloumn. I've tried using CMP and BMP, nothing worked. This is weird, all find, update, and remove methods work, except the create method. I've also checked the deployment descriptors, they're okay. Has someone had this kind of problem? Can somebody help me?
By the way, i'm using Forte 3.0 EE, iPlanet Application Server 6.0 SP3, and MS-SQL Server 2000.
 
Sudharsan Govindarajan
Ranch Hand
Posts: 319
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Irsan,

Have u solved this problem? I am facing the same problem with Mysql 4.0.17 & JBoss 3.2.3

Thanks,
Sudharsan
 
chuck keuper
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am having this exact same problem with JBuilder 9 and BES 5.2. Was a solution found??
 
goose li
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ' ' at line 1

mysql-4.1.7
JBuilder X

I have the same problem, I try to inert a photo into my MySQL server!
 
Ken Loh
Ranch Hand
Posts: 190
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sounds like an FK constraint. Best way to try is to construct a similar SQL query similar to the EJB-QL that you use and see what the result is if you enter it to your DB console. Only after the SQL works that you port it to EJB-QL.

My $0.02.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic