• 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: Strange Exception less useless, but no less Strange
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Strange Exception less useless, but no less Strange


  • Subject: Re: Strange Exception less useless, but no less Strange
  • From: David LeBer <email@hidden>
  • Date: Sun, 20 Mar 2005 13:50:29 -0500


On Mar 20, 2005, at 1:12 PM, Andrew Kinnie wrote:

I finally managed to connect to a copy of my deployed database to diagnose the problem I have been having... WO 5.2 app for a club. The site has been running for a couple years, was recently updated to allow multiple locations for the club (with dedicated schedules pulled from the database for each club). Now, everything works, except the admin component. This component works on the development machine using a freshly created database. However, I have been getting a useless exception when it is run on the deployment machine, using the live database that has data for the past couple years. Now that I have copied the deployed database to the development machine, I am getting more useful information, but it still doesn't make sense to me.

The app now crashes at the appropriate place, and gives me a more detailed message (FINALLY). However, the more detailed message still doesn't make sense. It seems to be some sort of syncing issue, but I really don't know. As the code works on a freshly created database, but not on the old one, I am confused.

I get a null pointer exception on this line:

String club = clubName();
/* this line: */
if(club.equals("A Club Name")){

If it is ever possible that clubName() may be null this will through a NPE. I usually use this syntax in those cases:


if ("A Club Name".equals(club)) {
	//do stuff;
}

Note that the clubName() method is an EOModeler generated method:

public String clubName(){
	return (String)storedValueForKey("clubName");
}

And that there is a clubName key in the EOModel, and that there is a column in the database corresponding with it.

However, instead of using EOModeler to create the column, I did it manually in Openbase Manager, because the database was live and contained data. I also filled in the data.

Also note that this same column is used to fetch objects on another page in order to show upcoming events at particular clubs, so apparently the model does talk to that column elsewhere in the code.

;david

--
David LeBer
Senior Systems Developer
PiMedia

Attachment: smime.p7s
Description: S/MIME cryptographic signature

 _______________________________________________
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: Strange Exception less useless, but no less Strange
      • From: Andrew Kinnie <email@hidden>
References: 
 >Strange Exception less useless, but no less Strange (From: Andrew Kinnie <email@hidden>)

  • Prev by Date: Re: Strange Exception less useless, but no less Strange
  • Next by Date: Re: Strange Exception less useless, but no less Strange
  • Previous by thread: Re: Strange Exception less useless, but no less Strange
  • Next by thread: Re: Strange Exception less useless, but no less Strange
  • Index(es):
    • Date
    • Thread