How do I switch between different contexts in CoolStorage

107 views Asked by At

I ave different databases with the same schema, the only difference is the connectionstring. Is it possible to use the context options in CoolStorage to switch the context of the CoolStorage instance to another SQL instance?

1

There are 1 answers

0
Philippe Leybaert On BEST ANSWER

This is currently only supported if you call ad-hoc queries. For example:

CSDatabase.Context["ContextName"].ExecuteNonQuery("...");

For object-mapped operations, it is not supported. Every mapped class has to be mapped to a specific context at compile-time.