Exception on Where() or Select(): A Property must have UseVariable Attribute set

41 views
Skip to first unread message

michael....@gmail.com

unread,
Jan 1, 2017, 3:03:38 PM1/1/17
to Siaqodb - NoSQL embedded database for .NET
Hello

I'm using Siaqodb in a Xamarin.Forms Project and have the following Error:

A Property must have UseVariable Attribute set( property:SummarizeOnStartpage of type:MyBudgetLive.AccountItem)

On this Line:

return _db.Query<AccountItem>().Where(item => item.SummarizeOnStartpage).Sum(item => item.CurrentBalance);  

Item Class:

    public class AccountItem
    {
        public int OID { getset; }
        public Guid UID { getset; }
        public DateTime Created { getset; }
        public DateTime Modified { getset; }

        public string Name { getset; }
        public string Color { getset; }
        public decimal InitialBalance { getset; }
        public decimal CurrentBalance { getset; }
        public bool IsDefaultExpense { getset; }
        public bool IsDefaultIncome { getset; }
        public bool ShowOnStartPage { getset; }
        public bool SummarizeOnStartpage { getset; }
    }
 

I also get the same Error on any Where Clause and any Select Clause.
Queries like First(), FirstOrDefault, ToList(), etc. are working fine.

Do you have any Idea whats wrong here?

Thank you very much

Siaqodb - NoSQL embedded database for .NET

unread,
Jul 3, 2017, 2:19:06 PM7/3/17
to Siaqodb - NoSQL embedded database for .NET, michael....@gmail.com
Hi Michael,
  Sorry for the delay, we are just now taking over support for this product.  Have you changed your model since the original run of your program?  If you are still interested, please contact us directly at sup...@siaqodb.com for assistance.  Thanks!
Reply all
Reply to author
Forward
0 new messages