Thanks Igor and thanks Martin,
I need to add both the id and the other properties to an hash table (a Cocoa 
NSDictionary) so I needed a way to have a key, value representation that 
includes also the id.

I solved the problem with 2 queries and some Cocoa code.
I don't like complex queries and 2 simple queries is a better approach for the 
maintainability of the project.

Thanks a lot for your advices.
--
Marco Bambini
http://www.sqlabs.com






On Feb 2, 2011, at 8:11 PM, Igor Tandetnik wrote:

> On 2/2/2011 11:16 AM, Marco Bambini wrote:
>> your query returns 3 columns, but I need just two columns (key, value for 
>> example).
> 
> Why? You have all the information you need, just in a slightly different 
> (and, arguably, easier to use) form.
> 
>> The first row should be the label 'ID' and the id of the MKObjects followed 
>> by a SELECT prop_key, prop_value WHERE obj_id= MKObjects.id.
> 
> Why should it? Why exactly do you insist on this format?
> 
> What should happen, in your proposed representation, when there is more 
> than row in MKObjects, each with its own set of properties?
> -- 
> Igor Tandetnik
> 
> _______________________________________________
> sqlite-users mailing list
> sqlite-users@sqlite.org
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to