Closed aheissenberger closed 14 years ago
save_doc does exactly that.
Yes, but only if I include the latest revision ID which means that I have to do a request to coachdb for each record to check if it exist. take the IDrev an and it to the new local data and then save it with "save_doc". I know this behavor is part of the native couchdb API but wouldn´t it make sense to offer this as an optional parameter in your API?
Which API Function can be used to simulate the SQL command REPLACE which will create a new Document if the primary key does not exist, else it updates the existing record.