Re: How to manage (My)SQL data in Cocoa

2008-11-10 Thread mmalcolm crawford
On Nov 10, 2008, at 12:39 PM, dreamcat7 wrote: Sorry maybe i should have clarified that but i believed that Quincey had already explained about the datasource methods. You *must* (if you dont want to end up in a heap of self-inflicted mess) represent your data in those way - WHEN you inten

Re: How to manage (My)SQL data in Cocoa

2008-11-10 Thread dreamcat7
Hi, Sorry maybe i should have clarified that but i believed that Quincey had already explained about the datasource methods. You *must* (if you dont want to end up in a heap of self-inflicted mess) represent your data in those way - WHEN you intend to link to an NSTableView using bindings.

Re: How to manage (My)SQL data in Cocoa

2008-11-10 Thread I. Savant
On Mon, Nov 10, 2008 at 1:48 PM, mmalcolm crawford <[EMAIL PROTECTED]> wrote: > NSTableView does not place any restriction on the way its data is > *represented*, just how it is *provided*. The more important point of focus here is that the *NSTableDataSource protocol* exists precisely *because

Re: How to manage (My)SQL data in Cocoa

2008-11-10 Thread mmalcolm crawford
On Nov 10, 2008, at 7:36 AM, dreamcat7 wrote: For NSTableView you MUST follow Quincey's conventions for the data representation. No, you don't. Quincey's statement that "the most natural "fit" with a NSTableView would probably be an array of dictionaries" is true, but there is no *need*

Re: How to manage (My)SQL data in Cocoa

2008-11-10 Thread dreamcat7
Just to make even clearer what Quincey has said; For NSTableView you MUST follow Quincey's conventions for the data representation. If you do not then simply the NSTableView control will not work. This is due to some very specific restrictions and limitations in the NSTableView Cocoa class.

Re: How to manage (My)SQL data in Cocoa

2008-11-09 Thread Quincey Morris
On Nov 9, 2008, at 09:16, Michele Barboni wrote: Currently I'm querying the database for a column at once, building an NSArray of them and add all NSArrays (the columns) in a NSMutableArray ("the table"). For editing I'm doing queries in the NSTableView controller (and I really don't like t

How to manage (My)SQL data in Cocoa

2008-11-09 Thread Michele Barboni
Hi, I'm developing a small application for showing/adding/modifying/ deleting entries for a MySQL database by some NSTableViews. My (mysql) tables are very simple, all of them has as primary-key and foreign-key an integer (autoincrement), other columns are varchar() or text. Currently I'm