Re: Dynamically Loading NSComboBox From a Database.
Re: Dynamically Loading NSComboBox From a Database.
- Subject: Re: Dynamically Loading NSComboBox From a Database.
- From: Jim Murry <email@hidden>
- Date: Wed, 20 Mar 2002 18:43:00 -0800
I appreciate the help, the approach of using a timer was considered .
My thought was polling to often could drag down a remote server, so I
was looking for a way to update only when required. I am looking into
postgresSQL as another was kind enough to suggest that it did use
notifications. I am hoping to figure that feature out, if not I believe
that I will poll for changes in the number of entries in tables on a
regular basis and update my data as required.
I did not take the comment personally, I just wanted to explain why "I"
was using a NSComboBox. I am sorry if it appeared that I responded a
little harsh.
Thanks again, the help is appreciated.
Begin forwarded message:
From: Chris Hanson <email@hidden>
Date: Wed Apr 03, 2002 05:44:00 PM US/Pacific
To: email@hidden
Subject: Re: Dynamically Loading NSComboBox From a Database.
At 1:35 PM -0800 4/2/02, Jim Murry wrote:
I have not been able to figure out how to get MySQL to notify my
program when it gets changed by another computer. That was my initial
approach, but could not figure that out so I was looking into this
approach. I agree that there would be fewer calls to the database
using your approach. If there are any suggestion on how to get a
remote MySQL database to do notifications, I might be able to
implement the NSComboBox properly.
Even if you can't get notifications from MySQL, you can still de-couple
the human interface to your application from the application's data
model. One way to do this would be to use a timer to poll the database
for changes, update your model from that if necessary, and sync your
human interface to the model.
My intent was to help you avoid writing an application where the user
clicks on a combo box and then sees the Spinning Cursor of Death for
several seconds while the database is queried. If you're using MySQL
locally rather than via a network maybe this won't be an issue, in
which case you should feel free to ignore me. ;)
Oh, and the comment I made about the combo box wasn't *specifically* to
you. It sounds like you have perfectly valid reasons for using it.
I've just had to deal with developers bringing applications over from
Windows and using combo boxes because they're available and familiar,
not because they're the best choice for their application's human
interface.
(A good topic for discussion on Apple-HI-Developers would be "When
should I use a combo box versus a popup menu?" Except the list isn't
around any more...)
-- Chris
-- Chris Hanson | Email: email@hidden
bDistributed.com, Inc. | Phone: +1-847-372-3955
Mac OS X & WebObjects Consulting | Fax: +1-847-589-3738
http://bdistributed.com/ | Personal Email: email@hidden
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.