I knew this would be a thorny issue, and I was hoping not to have to
deal with it. When fooling around with different ideas, I decided to
try adding the user to the club instead of adding the club to the
user. They should be equivalent. It turns out that in this case,
adding the user to the club worked as expected, even though the other
way around didn't. I'm sure this has something to do with the way the
cache is handled and how objects are tracked to be updated. Either
way I'm glad that I don't have to delve into this any deeper at this
point because it seems somewhat complicated and obtuse.
I appreciate all the pointers on what to do, I am saving them for
when this comes up again. I'm sure it will at some point.
Kevin
On Apr 18, 2007, at 1:59 PM, Mike Schrag wrote:
However, if you're doing all of these changes through a single
instance of a single wo app, then you should not need to care about
this. This is really only an issue you have multiple instances or
people changing your database behind your app's back. If you are
single instance/single app/single db access, then you have some
other problem going on.
ms
On Apr 18, 2007, at 2:54 PM, Robert Walker wrote:
http://developer.apple.com/documentation/WebObjects/
Enterprise_Objects/Fetching/chapter_6_section_7.html#//apple_ref/
doc/uid/TP30001011-CH206-BADDGFAG
This is a page that explains how to "Ensure Fresh Data." Warning:
It's not for the feint of heart. This is actually more
complicated that it initially seems. By default snapshots are
cached for 60 minutes. This is typically too long unless your
data is pretty static and stale data isn't a major problem.
In cases like your you will need to balance the benefits of the
snapshot caching and data freshness using the mechanisms described
in the above document.
The place to start is with the method on EOFetchSpecification
called setRefreshesRefetchedObjects(true);
On Apr 18, 2007, at 12:49 PM, Kevin Windham wrote:
I have an app with users and clubs. There is a many-to-many
between these objects. I allow one user to add another user to
their club through a page that fetches the particular user they
want to add and then calls the new users addToClubs method. This
much works fine. I can go look in my DB and see that the user has
been added. However, when I redisplay the original user's club
page, the new user does not show up. If I log out of the app and
log back in, the new user shows up.
I tried adding a refreshObject call on the original user, but
that doesn't seem to help. How can I refresh the many to many on
my original user?
Thanks,
Kevin
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/
robertwalker1%40mac.com
This email sent to [EMAIL PROTECTED]
--
Robert Walker
[EMAIL PROTECTED]
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/mschrag%
40mdimension.com
This email sent to [EMAIL PROTECTED]
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/kevo%
40gatorgraphics.com
This email sent to [EMAIL PROTECTED]
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com
This email sent to [EMAIL PROTECTED]