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 6990589
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T19:22:27+00:00 2026-05-27T19:22:27+00:00

I started using RavenDB today. When I save a class, I can see the

  • 0

I started using RavenDB today. When I save a class, I can see the Collection property in the DB:

enter image description here

However, when I load the class, the collection has no items in it:

public IEnumerable<CustomVariableGroup> GetAll()
{
    using (IDocumentSession session = Database.OpenSession())
    {
        IEnumerable<CustomVariableGroup> groups = session.Query<CustomVariableGroup>();
        return groups;
    }
}

enter image description here

Is there some type of activation depth that needs to be set in order to see the properties that are POCOs?

Edit (to show the classes, by request):

public class EntityBase : NotifyPropertyChangedBase
{
  public string Id { get; set; }  // Required field for all objects with RavenDB.
}

    public class CustomVariableGroup : EntityBase
{
    private ObservableCollection<CustomVariable> _customVariables;       

    public ObservableCollection<CustomVariable> CustomVariables
    {
        get
        {
            if (this._customVariables == null)
            {
                this._customVariables = new ObservableCollection<CustomVariable>();
            }
            return this._customVariables;
        }
    }
}

    public class CustomVariable : EntityBase
{
    private string _key;
    private string _value;

    /// <summary>
    /// Gets or sets the key.
    /// </summary>
    /// <value>
    /// The key.
    /// </value>
    public string Key
    {
        get { return this._key; }

        set
        {
            this._key = value;
            NotifyPropertyChanged(() => this.Key);
        }
    }

    /// <summary>
    /// Gets or sets the value.
    /// </summary>
    /// <value>
    /// The value.
    /// </value>
    public string Value
    {
        get { return this._value; }

        set
        {
            this._value = value;
            NotifyPropertyChanged(() => this.Value);
        }
    }
}
  • 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-27T19:22:27+00:00Added an answer on May 27, 2026 at 7:22 pm

    Got it. There was no setter on the CustomVariables property. As soon as I added the private setter, it worked. So, apparently RavenDB doesn’t use the private backing field, like db4o does. RavenDB needs the property.

    public ObservableCollection<CustomVariable> CustomVariables
    {
        get
        {
            if (this._customVariables == null)
            {
                this._customVariables = new ObservableCollection<CustomVariable>();
            }
            return this._customVariables;
        }
    
        private set
        {
            this._customVariables = value;
        }
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I started using core data and I read that I can save the data
I started using Hibernate recently and I'm still a newbie, however, the error I'm
Started using thinking sphinx today and I'd like to know what's going wrong here:
I started using entity inheritance today with core data, does anyone have any experience
Just started using AJAX today via JQuery and I am getting nowhere. As an
Just started using App Engine's webapp framework, but I can't figure out what's wrong
I recently started using RavenDb. I am converting a relational dbase to use RavenDb.
I started using Protobuf-Net in C# and WPF projects. I have a class that
I started using MVC3 and Rhino mocks. Can someone provide me an example to
I started using boost::thread recently (WinXP, VS10, BoostPro) and found that mutex can be

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.