Hello!
Is it possible to force NHibernate to fetch a property value using CASE
WHEN sql-sytax, when this property is defined in a few subclasses?
Domain model:
[TableName("clazz_A")]
public class ClazzA : Entity
{ public virtual String Name { get; set; } }
[TableName("clazz_A1")]
pub
Maybe cascade="lock" will help... It exists in CascadeStyle class, so
I suppose it is implemented :)
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"nhusers" group.
To post to this group, send email to nhusers@google
First of all I don't think it will be a real problem.
But if you really matter, you may use sql-query (of course not bound
to your class), or maybe create a bunch of "lightweight" classes that
will contain "just" columns/associations you need in particular case.
Super-massive/super-universal class
> But this does nothing, so it is not the same as fetch="select" in your
> mapping !
Hmm, I suppose that you have take into account combination of fetch=
and lazy= properties in mapping.
> Can anyone explain the difference between them, and possibly explain
> why Lazy (as it more or less explain
On 21 окт, 18:05, Fabio Maulo wrote:
> I'm not so sure that such kind of query has a better performance than 2 or 3
> round-trips.
I suppose, there will be more than "just 2 or 3 round-trips", as
p.ADDRESSES is collection, and fetching collection and object tree
(pretty deep in this case) for ea
You may reattach root object (Person) to session and then perform
query that will retrieve all the object graph starting from this
person.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"nhusers" group.
To post to th
BTW why don't you use Interceptor to do all this logging stuff?
And maybe it will be more reliable to put this logic into DB itself
(trigger, or stored procedure for create/update)...
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the
The problem is that in first case you have NO objects B and C. C
doesn't exist at all, while B exist as uninitialized proxy - so when
you reattach A in first case - nHibernate will just "initialize proxy
for B" - and at the same moment create proxies for C and D objects -
next step while processin
I always think that cascade="delete-orphan" apply ONLY to collection
associations (one-to-many in a set or bag) - not to many-to-one
association.
And probably there is NO way for nHibernate to know that there are
some other references to this city - from another Address object or
from object of to
Maybe missed cascade for object associations?
After first call you have 1 detached instance loaded in 1-st session
and 1 proxy (to B object).
Then you attach A, initialize B proxy, initialize C - so far it
worked. Close session - and now you have 3 detached instances A, B and
C.
Then you try to at
> So, my questions are:
> 1) Why did the style of sql change?
I'm also interested in this question!
> 2) Can I force NH to generate the ANSI compliant style?
Use Oracle10gDialect. As I can see, the only difference between them
is ANSI syntax for joins.
> 3) How do I specify <> in a mapping fil
11 matches
Mail list logo