Closed mdaguete closed 14 years ago
Could you provide a snippet about this ? Afaike put_atachments is used to send attachments one by one. If you want to send inline attachments use couchbeam_doc:add_attachment function to add attachmets to the doc and then save the doc. Not sure I understood anyway so a snippet could help :)
Sorry, now I understand you, I was usign put attachment in a loop to add all atachments ... I'm going to test couchbeam:_doc:add_attachment ..
Another question .. is there any suport for standalone attachments ?
Regards
put_atatchments/fetch_attachments are for that. If you do it in a loop don't forget to pass just latest doc. have a look in tests or here :
Ok, thanks
closing this issue so.
Hello,
I', trying to attach multiple files to a document, but only the last one it's stored.
The problem seems to be related to couchbeam_db:put_attach/6, it not returns the full object after success.
In my code, after the functions returns if I open the document by id and I use it to add another attachment it works.
Regards.