So am I barking up the wrong tree with my approach? Or is there a better 
way to query this kind of data? I've never used a dictionary for a key, so 
is that maybe the best approach to take instead of an array key?

Thanks

Brendan

On Wednesday, August 26, 2015 at 2:38:28 PM UTC-6, Brendan Duddridge wrote:
>
> Hi,
>
> If I have a view that emits keys something like this:
>
> emit(@[doc[@"Form"], doc[@"Record"], doc[@"Field"]], nil);
>
> I would like to fetch all rows that have a  specific Field no matter what 
> the value of Form and Record are.
>
> Is that possible?
>
> I thought maybe something like this would work:
>
> query.keys = @[@[@"", @"", field]];
>
> But it didn't work. It found 0 rows. I kind of need a wildcard for Form 
> and Record or something like that.
>
> I'm basically trying to support a cascade delete. If the user deletes a 
> Form, Record, or Field, I need to delete all rows that reference any of 
> them.
>
> Would it be better to use an NSDictionary as the key instead of an 
> NSArray? Sort order is unimportant in this case.
>
> Thanks,
>
> Brendan
>

-- 
You received this message because you are subscribed to the Google Groups 
"Couchbase Mobile" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to mobile-couchbase+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/mobile-couchbase/ea91153c-ec3c-4899-b6cd-16c8eb5e6548%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to