trampster
trampster

Reputation: 8898

Upper extension method in linq to NHibernate

I would like to use the Upper extension method which is declared on the IDbMethods interface against Sql Server 2008.

The extension methods are defined in NHibernate.Linq.SqlClient.SqlClientExtensions

I understand that this will translate to UPPER() on sql server.

However I can not figure out how to get an implementation of IDbMethods so that I can use the extension method.

Upvotes: 1

Views: 615

Answers (1)

Diego Mijelshon
Diego Mijelshon

Reputation: 52735

You don't need to use IDbMethods. Just use YourStringProperty.ToUpper() and the provider will map it.

Upvotes: 1

Related Questions