1) To my knowledge you don't have any control over this... but I want to say there is a discussion or some work being done to allow for more control over ETag generation. I had originally thought a _show function's ETag was simply the document's (based on revision hash I think) but the Wiki shows it's a bit more complex then that:
https://wiki.apache.org/couchdb/Formatting_with_Show_and_List#ETags 2) Not entirely sure what you are asking. To retrieve an attachment you just retrieve it off the document. Something like http://server/db/docid/attachmentid Are you trying to embed an attachment's data into the _show's results? I don't think that is possible as you are only given access to the document requested which will only have the attachment stubs. -- Sean Copenhaver Sent with Sparrow (http://www.sparrowmailapp.com/?sig) On Thursday, September 22, 2011 at 9:29 PM, Gert Cuykens wrote: > 1) How do you overwrite the ETag of a show function? > I tried this but does not work. > return {headers:{'Content-Type':'text/html','Etags':doc._rev},body:'...'} > > 2) Can you use the show function to show the content of a binary attachment?
