I don't have the code accessible at the moment so I can't check it, but if
you search the code for where SqlSelectBuilder is instantiated you should
be able to figure out if there is an existing extension point, or how much
work you would need to add one. Alternatively, you might also explore the
idea of extending the existing SqlSelectBuilder and Dialects to incorporate
this feature, provided it isn't too intrusive.

/Oskar


2012/9/11 Ghassan Karwchan <[email protected]>

> I know how to implement a dialect
> I will rephrase my question.
> I am not looking for how to hook a custom dialect.
> I am looking to override the  SqlSelectBuilder  class
> Is there a place where we can hook this new SqlSelectBuilder?
>
>
> On Tuesday, September 11, 2012 5:40:51 AM UTC-6, sbohlen wrote:
>
>> You need to code and compile a completely different assembly representing
>> your new dialect with whatever changes you need and then use the
>> hibernate.cfg.xml value to specify it (see http://www.nhforge.org/doc/nh/
>> **en/#configuration-optional-**dialects<http://www.nhforge.org/doc/nh/en/#configuration-optional-dialects>for
>>  more info).
>>
>> Steve Bohlen
>> [email protected]
>> http://blog.unhandled-**exceptions.com<http://blog.unhandled-exceptions.com>
>> http://twitter.com/sbohlen
>>
>>
>>
>> On Tue, Sep 11, 2012 at 2:26 AM, Ghassan Karwchan 
>> <[email protected]>wrote:
>>
>>> I am dealing with a proprietary database.
>>> It is ESRI's File Geodatabase (to whom might know it)
>>> There is an ADO.NET data provider for it, but this provider doesn't
>>> accept in sql statement aliases
>>> so the select should be "select field1, fielde2 from table1"
>>> it doesn't accept "select field1 as name1, field2 as name2 from table1
>>> tab_name1"
>>>
>>> After I tried for a while with the Dialect, I am thinking my only
>>> solution is to override the SqlSelectBuilder
>>> Am I right?
>>>
>>> And in case I want to override this class, is there a way with
>>> NHibernate extension point to specify that I want to use this overridden
>>> one?
>>> where should I assign the new one?
>>>
>>>
>>>
>>

Reply via email to