O'Reilly logo

SproutCore Web Application Development by Tyler Keating

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Querying the store

Before we look at synchronizing data with a remote source, we do have to catch up on how to use the queries that we briefly saw when we introduced find. Firstly, there are two types of queries: local and remote. I'll warn you now not to get hung up on the names; using both types of queries may invoke a fetch to a remote data source. The difference is that the content and order of local queries is updated live depending on the current records in the local store, while the content and order of remote queries is set by the remote data source and can only be updated by requesting from the remote data source again.

Why have this distinction? It's simple. If you have 5,000,000 records on your server, you don't want to load them all ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required