Yes, but we would only have one new class implementing
"IHqlFunctionProvider" instead of several MyMsSql2008Dialect,
MyOracle9iDialect, MyMySQL5Dialect, etc.
This is not critical to me, I was just wondering... I really like
NHibernate's extensibility, and in HQL extensibility can only be
achieved by switching to a new class (xxxDialect) at configuration
time.


On Apr 20, 7:28 pm, Fabio Maulo <[email protected]> wrote:
> so and so.
> At the end you will have the same work.
> Instead configure a different dialect you have to configure a
> "IHqlFunctionProvider".
> Instead write RegisterFunction in the dialect you have to do it in
> "IHqlFunctionProvider".
>
> The other part of the work (re-usability) is the same because as you can do
> today inside each dialect you can re-use same functions implementations.
>
>
>
>
>
>
>
>
>
> On Wed, Apr 20, 2011 at 3:06 PM, Ricardo Peres <[email protected]> wrote:
> > Something like you showed, but for HQL: the possibility to add custom
> > server-specific functions that can be used in HQL, without the need to
> > subclass xxxDialect.
> > Does it make sense?
>
> > On Apr 20, 6:34 pm, Fabio Maulo <[email protected]> wrote:
> > > which is your proposal ?
>
> > > On Wed, Apr 20, 2011 at 2:20 PM, Ricardo Peres <[email protected]>
> > wrote:
> > > > Hello,
>
> > > > Some time ago, Fabio posted about LINQ provider extensibility in
> > > > NHibernate:
> > > >http://fabiomaulo.blogspot.com/2010/07/nhibernate-linq-provider-exten.
> > ..
> > > > .
> > > > It is such a nice feature that I was wondering if it would make sense
> > > > to have something like that for HQL (yes, I still use HQL...). I know
> > > > that we can subclass a dialect and add custom functions, but it
> > > > requires duplicating code for all possible dialects that we are going
> > > > to use.
> > > > What are your thoughts?
>
> > > > Thanks,
>
> > > > RP
>
> > > --
> > > Fabio Maulo
>
> --
> Fabio Maulo

Reply via email to