Sterling vs SQL CE on Mango

Jul 19, 2011 at 2:39 PM

Hi folks,

I read the sterling documentation and i must say its lightweight, powerful and bit easier too. Right now we are developing app for wp7, hence Sterling seems like a good choice. I have understood the benefits / positives of Sterling db. But i believe i should also be knowing the disadvantages of the same, if any (am sure at least one or two will be there). Please let me know.

Also once we move to wp7.1 (mango), which has local database storage using SQL CE. What would be advisable to use, Sterling or SQL CE? I mean i am curious to know what are the advantages of Sterling over SQL CE and vice-versa.

Thanks in advance.

Coordinator
Jul 22, 2011 at 1:28 PM

I'll let the community speak to their experience, but here are my thoughts:

1. Sterling is perfect for what it does - serialization of domain sets that target the client experience. It does not manage millions of rows.

2. Sterling allows you to focus on the design of your classes and then persist them. You don't have to change your classes to work with Sterling and you don't have to model them after a database. Sterling takes care of it for you.

3. Sterling gives you full availability of LINQ to Objects to query, sort, and manipulate data

The main advantages over SQL CE is that it is object-based so you aren't restricted by columns. You can declare a "table" with an "object" property and store three different object types in three different rows and Sterling will handle it fine. That is also the main disadvantage - because it serializes the full object graph, it must deserialize the objects to get at information so if you aren't able to cover what you need through indexes, performance takes a hit. SQL CE also goes directly to the file system and uses a single file for the database, which is going to be far faster than Sterling which currently has multiple files and uses isolated storage.