• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Error When Deleting from different session
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Error When Deleting from different session


  • Subject: Re: Error When Deleting from different session
  • From: Owen McKerrow <email@hidden>
  • Date: Sat, 11 Jun 2005 11:02:11 +1000

Thanks Chuck,

That was exactly the problem. A fellow team member had built a relationship from one table to the child entity and had put the reverse relationship from the parent to the table. It just took me 5 times to look at the model before I noticed the discrepancy :)

Owen

On 11/06/2005, at 5:51 AM, Chuck Hill wrote:

Hi Owen,


On Jun 9, 2005, at 6:47 PM, Owen McKerrow wrote:

Im posting this to both the WO and OpenBase lists as Im not sure exactly where the problem is coming from.
I have a table called Grants which is having issues when I delete from it. That is to say, if I create a Grant I can delete it happily if its in teh same session. If I come back in with a new session I get the following error :


java.lang.IllegalStateException: sqlStringForKeyValueQualifier: attempt to generate SQL for com.webobjects.eocontrol.EOKeyValueQualifier (_eofInv_jStudentGrant_person.grant.rowID = (java.math.BigDecimal)'2') failed because attribute identified by key '_eofInv_jStudentGrant_person.grant.rowID' was not reachable from from entity 'External'
02:12:00AM


sqlStringForKeyValueQualifier: attempt to generate SQL for com.webobjects.eocontrol.EOKeyValueQualifier (_eofInv_jStudentGrant_person.grant.rowID = (java.math.BigDecimal)'2') failed because attribute identified by key '_eofInv_jStudentGrant_person.grant.rowID' was not reachable from from entity 'External'


As I said Im not sure if this is a WO problem or an OpenBase one,
It's WebObjects, something is wrong in your EOModel.


but I have no idea where "_eofInv_jStudentGrant_person.grant.rowID" is coming from. Is this just WO's way of saying "jStudentGrant_person.grant.rowID" i.e. its sticking the "_eofInv" in the front of it, or is there a hidden table in OpenBase which has this attribute in it ? Im thinking its WO.

eofInv means "EOF generated Inverse Relationship". EOF is generating a relationship trying to get to the destination of a relationship and it can't. I can't quite reason out which one. Are you using inheritance with relationships to entities below the top most entity? This is most likely happening as the result of EOF evaluating delete rules.


And why does this error not happen if I have delete the grant in the same session as I made it ?
Because it is already in memory in the same session. Later it needs to fault it in from the database and when it tries to generate SQL to do so it hits this problem.

HTH

Chuck


--
Practical WebObjects - a book for intermediate WebObjects developers who want to increase their overall knowledge of WebObjects, or those who are trying to solve specific application development problems.
http://www.global-village.net/products/practical_webobjects





_______________________________________________ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
References: 
 >Error When Deleting from different session (From: Owen McKerrow <email@hidden>)
 >Re: Error When Deleting from different session (From: Chuck Hill <email@hidden>)

  • Prev by Date: Re: Authorize.net Credit Card Authentication
  • Next by Date: Re: disposing components
  • Previous by thread: Re: Error When Deleting from different session
  • Next by thread: Re: Error When Deleting from different session
  • Index(es):
    • Date
    • Thread