Return-Path: X-Original-To: apmail-couchdb-user-archive@www.apache.org Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 8646F10CEA for ; Fri, 8 Nov 2013 21:40:32 +0000 (UTC) Received: (qmail 93115 invoked by uid 500); 8 Nov 2013 21:40:31 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 93079 invoked by uid 500); 8 Nov 2013 21:40:31 -0000 Mailing-List: contact user-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@couchdb.apache.org Delivered-To: mailing list user@couchdb.apache.org Received: (qmail 93071 invoked by uid 99); 8 Nov 2013 21:40:31 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 08 Nov 2013 21:40:31 +0000 X-ASF-Spam-Status: No, hits=1.7 required=5.0 tests=FREEMAIL_ENVFROM_END_DIGIT,HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of siriele2x3@gmail.com designates 209.85.216.179 as permitted sender) Received: from [209.85.216.179] (HELO mail-qc0-f179.google.com) (209.85.216.179) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 08 Nov 2013 21:40:27 +0000 Received: by mail-qc0-f179.google.com with SMTP id k18so2244612qcv.38 for ; Fri, 08 Nov 2013 13:40:06 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=VdhAxnh6Z+VP0/F7kt9DjQqFx6a+THxtDayYr7E+S9M=; b=Yh6g6Vzdou7dG2GTo82+glfwIwmBLrf+tJNdXC3fqq+dnemVgB/vBW7QunKA6AvkdU GVfnMNyCM5uCeaNHI94MN1FwSL+j/vl7eH30HMwCyWtwCpk+UtEX4qiYrxjK6ummmje5 2EZxVNnQnvndQMxCCuridHCuBV6gJ9emR82aMORHBs7IX8mrlcqkK/8BYc0IeeCZ43Qb 5ubGUmiNDOPof7Hawj8BE00N2OhhluHnQ5y4ToyGmvEP1y3cyIv5/bbvl66oBRn1ThNK Jr6Qh2uRxAHndljB118ES3jY3QYpbyTuUo86I7PrpT9KoFC8aKhDpeumprgXlXOIo9V9 hWpQ== MIME-Version: 1.0 X-Received: by 10.224.103.66 with SMTP id j2mr27538579qao.66.1383946806457; Fri, 08 Nov 2013 13:40:06 -0800 (PST) Received: by 10.96.72.76 with HTTP; Fri, 8 Nov 2013 13:40:06 -0800 (PST) Received: by 10.96.72.76 with HTTP; Fri, 8 Nov 2013 13:40:06 -0800 (PST) In-Reply-To: References: Date: Fri, 8 Nov 2013 13:40:06 -0800 Message-ID: Subject: Re: overwrite document without revision? From: Stanley Iriele To: user@couchdb.apache.org Content-Type: multipart/alternative; boundary=047d7b67001fc97bec04eab139f0 X-Virus-Checked: Checked by ClamAV on apache.org --047d7b67001fc97bec04eab139f0 Content-Type: text/plain; charset=ISO-8859-1 But no you can't just throw a doc in the db without the latest revision if it already exists On Nov 8, 2013 1:39 PM, "Stanley Iriele" wrote: > I still think you can use update handlers for that...just send the doc > over the wire... Parse it and save it in the db with the current revision > of the current doc if it exists...you. Can't do this in bulk... And I think > what you're trying to Dave is the round trip... Which the update handler > gives you... > On Nov 8, 2013 12:54 PM, "Daniel Nephin" wrote: > >> Isn't this the default behaviour? >> >> All you need to update a document is it's '_id'. Since this is a data >> warehouse, I assume the ID is already being set by the transaction system, >> so you don't need to do a lookup. If you PUT a document ( >> http://docs.couchdb.org/en/latest/api/document/common.html#put--db-docid) >> using >> it's ID, it will replace the previous revision. >> >> Am I missing something? >> >> >> On Fri, Nov 8, 2013 at 11:33 AM, Robert Newson >> wrote: >> >> > There is not, not even update handlers can do that, by design. >> > >> > B. >> > >> > >> > On 8 November 2013 17:41, Stanley Iriele wrote: >> > > Update handlers sound like the way to go here.... >> > > On Nov 8, 2013 9:39 AM, "Alex Ramos" wrote: >> > > >> > >> Is there any way to unconditionally overwrite a document without >> first >> > >> making a round-trip to get the current rev? >> > >> >> > >> I'm trying to use CouchDB as a data warehouse of sorts and I just >> need >> > to >> > >> overwrite docs with data coming from the transactional system of >> record >> > (in >> > >> MySQL) when they change. >> > >> >> > >> > --047d7b67001fc97bec04eab139f0--