Add or update with db.js

A common question with db.js is how to merge data from a remote store into the local store. When doing so you need to think about how you’re handling an add vs an update statement.
Say you have some records that you’re syncing between the t…


This content originally appeared on Posts on LINQ to Fail and was authored by Posts on LINQ to Fail

A common question with db.js is how to merge data from a remote store into the local store. When doing so you need to think about how you’re handling an add vs an update statement. Say you have some records that you’re syncing between the two instances and they have a common key that you use to identify on both the client and the server. When a user hits the site you pull down the records and want to work out if they are to be inserted or just updated against what you already have.


This content originally appeared on Posts on LINQ to Fail and was authored by Posts on LINQ to Fail


Print Share Comment Cite Upload Translate
APA
Posts on LINQ to Fail | Sciencx (2023-01-29T02:21:55+00:00) » Add or update with db.js. Retrieved from https://www.scien.cx/2014/09/11/add-or-update-with-db-js/.
MLA
" » Add or update with db.js." Posts on LINQ to Fail | Sciencx - Thursday September 11, 2014, https://www.scien.cx/2014/09/11/add-or-update-with-db-js/
HARVARD
Posts on LINQ to Fail | Sciencx Thursday September 11, 2014 » Add or update with db.js., viewed 2023-01-29T02:21:55+00:00,<https://www.scien.cx/2014/09/11/add-or-update-with-db-js/>
VANCOUVER
Posts on LINQ to Fail | Sciencx - » Add or update with db.js. [Internet]. [Accessed 2023-01-29T02:21:55+00:00]. Available from: https://www.scien.cx/2014/09/11/add-or-update-with-db-js/
CHICAGO
" » Add or update with db.js." Posts on LINQ to Fail | Sciencx - Accessed 2023-01-29T02:21:55+00:00. https://www.scien.cx/2014/09/11/add-or-update-with-db-js/
IEEE
" » Add or update with db.js." Posts on LINQ to Fail | Sciencx [Online]. Available: https://www.scien.cx/2014/09/11/add-or-update-with-db-js/. [Accessed: 2023-01-29T02:21:55+00:00]
rf:citation
» Add or update with db.js | Posts on LINQ to Fail | Sciencx | https://www.scien.cx/2014/09/11/add-or-update-with-db-js/ | 2023-01-29T02:21:55+00:00
https://github.com/addpipe/simple-recorderjs-demo