• 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: ec.saveChages gives null exception (didn't before)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ec.saveChages gives null exception (didn't before)


  • Subject: Re: ec.saveChages gives null exception (didn't before)
  • From: Chuck Hill <email@hidden>
  • Date: Mon, 7 Mar 2005 09:37:34 -0800

It is more likely what you have not done. When you connect to a database in EOModeler, it caches some database specific information to the connection dictionary under the jdbc2info key. If you later change databases (as I recall you have) and don't use EOModeler to connect to the new database, this jdbc2info will still be for the old database. I'm not 100% sure that connecting to the new DB will update this, it's not something I do frequently.

If you inspect the root node in the EOModel you should see this jdbc2info key. Delete it and save the model. If you want you can then connect to the new database and save the model, or EOF can regenerate this information from the database each time it is run. If you are going to switch back and forth a lot, I would try to avoid saving this information in the model. Note that if it is not in the model, EOF will keep two connections to the database open, one for data and one for this information. In most cases this does not matter, but it will in you are in a environment where the DB license is on a per connection basis.

Chuck

On Mar 6, 2005, at 8:08 PM, Drew Thoeni wrote:

For quite some time, this method, and all others that save to the Class table (like a classroom, not an object definition) worked fine. I've looked at the SQL that is being generated and it appears fine. There is only one not-null column in the table (the key) and the failures are on updates to an existing record. Clearly, something is null that should not be. And, it seems it's a result of something I've done. But I've spent about an hour tinkering with this and (probably in 10 minutes) reached my level of expertise.

Can anyone suggest what I might check into regarding this exception?


[2005-03-06 22:49:59 EST] <main> Waiting for requests...
[2005-03-06 22:58:35 EST] <WorkerThread8> java.lang.NullPointerException
at com.webobjects.jdbcadaptor.JDBCAdaptor.isValidQualifierType(JDBCAdaptor .java:659)
at com.webobjects.eoaccess.EODatabaseContext.isValidQualifierTypeForAttrib ute(EODatabaseContext.java:5146)
at com.webobjects.eoaccess.EODatabaseContext.lockingNonQualifiableAttribut es(EODatabaseContext.java:5160)
at com.webobjects.eoaccess.EODatabaseContext.createAdaptorOperationsForDat abaseOperationAttributes(EODatabaseContext.java:5346)
at com.webobjects.eoaccess.EODatabaseContext.createAdaptorOperationsForDat abaseOperation(EODatabaseContext.java:5520)
at com.webobjects.eoaccess.EODatabaseContext.performChanges(EODatabaseCont ext.java:6337)
at com.webobjects.eocontrol.EOObjectStoreCoordinator.saveChangesInEditingC ontext(EOObjectStoreCoordinator.java:411)
at com.webobjects.eocontrol.EOEditingContext.saveChanges(EOEditingContext. java:3148)
at ClassAdmin.saveClass(ClassAdmin.java:63)

--
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


  • Follow-Ups:
    • Re: ec.saveChages gives null exception (didn't before)
      • From: Drew Thoeni <email@hidden>
References: 
 >ec.saveChages gives null exception (didn't before) (From: Drew Thoeni <email@hidden>)

  • Prev by Date: Re: How to avoid innumerable sessions being created by robots
  • Next by Date: PDF
  • Previous by thread: Re: ec.saveChages gives null exception (didn't before)
  • Next by thread: Re: ec.saveChages gives null exception (didn't before)
  • Index(es):
    • Date
    • Thread