Hi Matt
Do you know if there is possible to querying directly to the bucket used by 
the sync gateway in this new version of N1QL (DP4)? 
Because, I have some synchronizing issues between this bucket and the 
shadow bucket, after several time I got discrepancies



El martes, 30 de septiembre de 2014, 12:34:03 (UTC-5), Matt Ingenthron 
escribió:
>
>  Hi Victor, 
>
>  You should not be directly querying the bucket used by sync gateway. 
>  The intent, at the moment, is that you use the bucket shadowing 
> <http://developer.couchbase.com/mobile/develop/guides/sync-gateway/wcbs/bucket-shadowing/index.html>
>  functionality 
> there to shadow it to another bucket, and then you can query from there 
> with N1QL.
>
>  Then you’ll have only one version, as determined by SyncGateway, in the 
> shadow.
>
>  Thanks,
>
>  Matt
>
>  On Sep 30, 2014, at 7:51 AM, Victor Fernandez <[email protected] 
> <javascript:>> wrote:
>
>  Yes Gerald for example I have a document named user::vfernandez. This 
> doc have two fields age and name, if I modify this document through the 
> sync gateway another version of the same document it's created. When I do 
> the select with NIQL, this process returns me the first version of the 
> document (when it was created) and the second version (after this was 
> modified). I only need the last revision
>
> El martes, 30 de septiembre de 2014 09:38:49 UTC-5, Gerald escribió: 
>>
>> Hi Victor, 
>>
>>  How is it that you are getting multiple versions? What versions were 
>> you referring to in your original posting?
>>
>>  Also, how do you know that it is multiple versions of the same 
>> document, as opposed to separate documents?
>>  
>> On Tue, Sep 30, 2014 at 7:30 AM, Victor Fernandez <[email protected]
>> > wrote:
>>
>>> Hi Gerald, this version field is from Metadata? or  your suggestion is 
>>> to add a field for versions?
>>>
>>> El martes, 30 de septiembre de 2014 09:28:26 UTC-5, Gerald escribió: 
>>>>
>>>> Hi, 
>>>>
>>>>  If you have a version field, you can do something like:
>>>>
>>>>  select *
>>>> from my-bucket
>>>> where ...
>>>> order by version desc
>>>> limit 1
>>>>
>>>> On Monday, September 29, 2014 3:23:52 PM UTC-7, Victor Fernandez wrote: 
>>>>>
>>>>> Hi I have the N1QL process running in my couchbase server, I'm making 
>>>>> REST petitions to make the querys but the problem is that te query 
>>>>> returns 
>>>>> all the versions of a document. I only need the latest version, is there 
>>>>> a 
>>>>> way to do this?
>>>>>
>>>>    
>>>  -- 
>>> You received this message because you are subscribed to a topic in the 
>>> Google Groups "Couchbase" group.
>>> To unsubscribe from this topic, visit 
>>> https://groups.google.com/d/topic/couchbase/uivm95SLkFE/unsubscribe.
>>> To unsubscribe from this group and all its topics, send an email to 
>>> [email protected].
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>  
>>   
>  -- 
> You received this message because you are subscribed to the Google Groups 
> "Couchbase" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to [email protected] <javascript:>.
> For more options, visit https://groups.google.com/d/optout.
>
>  
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Couchbase" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to