How to change type of sorting

Discussion of open issues, suggestions and bugs regarding ADO.NET provider for Oracle
Post Reply
romanFleischer
Posts: 18
Joined: Wed 02 Jun 2010 16:28

How to change type of sorting

Post by romanFleischer » Wed 10 Nov 2010 12:53

Hello,

we use dotConnect 5.70.120.00 with MS entity framework. Nearmost everything works well, but the sorting seems to be ASCII instead of national letters. So big letter words were shown prior to smal letter words.

This is wrong for our customer. We try to use NLS_SORT and ALTER SESSION. This works well when we connect direct to the database. But where can we set this value inside our sw-solution? How is it possible to change sorting?

Thanks
Roman

AndreyR
Devart Team
Posts: 2919
Joined: Mon 07 Jul 2008 13:16

Post by AndreyR » Fri 12 Nov 2010 12:39

Create a partial class (or use the exitsting DataModel.cs if you are using a .edml model), and add the OnContextCreated method.
In this method you should open the store connection:

Code: Select all

((EntityConnection)(db.Connection)).StoreConnection.Open();
Execute the code that will influence the sorting after opening the connecton. Don't close it, the session is flushed when the connection is closed.

Post Reply