Binding data from a related table (foreign key) using RIA services in XAML.


hi,

i have foreign key relationship between 2 tables [location] , [user]. 

the [location] table has fields [id] , [description].

the [user] table has fields [id],[firstname],[lastname],[location_id]. binding datagrid follows:

 

            datagrid1.itemssource = dc.users;              dc.load(dc.getallusersquery());
 

in previous application using linq sql , not using ria, i able bind field in xaml datagrid using notation somelike following:

<textblock text="{binding location.description}" margin="4"/>  
 this not appear work when using ria services entity data model. possible ria services?

i have gotten around problem "include" arrtibutes in metadata of data service know if possible?

thanks in advance.

this work in ria i'm using quite heavily.  if have include attribute in metadata , include table name in query e.g. this.context.users.include("locations") should ok.



Silverlight  >  WCF RIA Services with Silverlight



Comments

Popular posts from this blog

Conditional formatting a graph vertical axis in SSRS 2012 charts

Register with Power BI failed

SQL server replication error Cannot find the dbo or user defined function........