WCF RIA Services provide lots of possibilities on getting data from the server to the client whether it is a Silverlight client or a console application.
One of the challenges that you may experience using WCF RIA Services is getting related properties to an entity to be included on the client. But no need to get scared – it is actually pretty easy.
First of all you need to create an association between your entity and the related entity. Lets say we have a company (Company) with a CEO (Employee):
When we get a list of companies from the client we would like to have the CEO property included and filled on the company. To do that we need to add a few attributes to the CEO property. Instead of adding the attributes on the entity object we can create a metadata file that holds this type of information.
Now the CEO property will be included, filled and ready to use when we call a query from the client that returns a list of companies.
You can download sample from my DropBox: http://dl.dropbox.com/u/4243120/SL%20Demos/RiaIncludePropertiesDemo.zip
by xamlgeek
What does the “Association” attribute mean?