SQLite-PCL select inherit members.

With SQLite i want to select a member class "Class" from a table.
This Class inherits a member from the class BaseObject.

    public Class () : base ()
    {

    }

    public Class (string up, string name) : base (up)
    {
        _name = name;
    }


    public string Name
    {
        get
        {
            return _name;
        }
        set
        {
            _name = value;
        }
    }

    private string _name;
}




    public class BaseObject
    {
    public BaseObject ()
    {

    }

    public BaseObject (string up)
    {
        _up = up;
    }


    public string UniversalPointer
    {
        get
        {
            return _up;
        }
        set
        {
            _up = value;
        }
    }

    private string _up;
}

The code i use to insert and select the queries are:

            _conn.Execute("INSERT INTO Class VALUES ('" + cls.UniversalPointer + "', '" + cls.Name + "');");

            List<Class> classes = _conn.Query<Class>("SELECT * FROM Class");

The data is in the file, but when i use the Select query it only gets the name and not the UniversalPointer (base object)
Is there a way I can select this in 1 query?

Sign In or Register to comment.