Search code examples
c#ormmonostack-overflowormlite-servicestack

Does ServiceStack ormlite has the concept of transient attribute?


I am newbie to servicestack and ormlite.

I am trying to have fields to be used for displaying / serialization purposes not for persistance purposes. I tried [ignoredatamemebr] but this ignore both persistance and serialization. I want to do something similar to [notmapped] in entity framework and like @transient in hibernate.


Solution

  • Use the [Ignore] attribute to ignore properties from being persisted in OrmLite.

    Whilst here are different ways to ignore properties during serialization.