Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6071011
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T09:59:55+00:00 2026-05-23T09:59:55+00:00

I have an object model where I’m checking a filter value of nested child

  • 0

I have an object model where I’m checking a filter value of nested child property e.g.

Order -> Customer

And Customer has a property e.g. Name = "Joe Bloggs"

My domain service returns IQueryable<Order>. My domain data source is bound to this (and in turn my Grid is bound to the domain data source), and I have a filter descriptor set as something like this:

<ria:FilterDescriptor Operator="Contains" Value="{Binding Text, ElementName=txtCustomerName}" PropertyPath="Customer.Name" IgnoredValue=""/>

This all works great, except the relationship between Order and Customer is optional i.e. an Order may not have a Customer and therefore the Customer navigation property may be null. In such a situation, when running the query, the domain data source throws a null reference exception – presumably because it’s trying to traverse the Customer and get the Name value when of course the Customer is null.

Has anyone come up with a good solution to this problem?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T09:59:55+00:00Added an answer on May 23, 2026 at 9:59 am

    I ended up solving this by using the MVVM equivalent to the DomainDataSource – the DomainCollectionView and its associated classes. With this, you have more control of your query composition and I therefore made my query do a null check on the Customer property before evaluation the Name property on it.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Say I have a model object 'Person' defined, which has a field called 'Name'.
The GoDiagram object model has a GoDocument. GoViews have a reference to a GoDocument.
I have a legacy object model that has content objects and a table designed
I have an object model like that: Folder - simple structure with name etc.
So I have a model object, which is a named 'location' which has a
I have a model object called Problem: [Table(Name = Problems)] public class Problem {
Hi I'm have an object model with an Employee and EmployeeWorksiteReference (cause it's an
I have a project which exposes object model to use by different types of
In my Core Data managed object model, I have an entity Foo with a
I'm relatively new to the Component Object Model specification - I have a simple

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.