Hi.. I'm using .NET 4.0, Oracle 11g (Oracle.DataAccess 4.112.2.0) and NH3.3
I'm mapping an Oracle stored procedure inside <sql-insert> entity section,
in a NHibernate's .hbm.xml mapping file, like this:
<class name="Person" table="PERSONS">
<id name="Id" column="COD_PERSON" />
<property name="Name" column="NAME" />
<property name="AuditField1" column="AUDITFIELD1" />
<property name="AuditField2" column="AUDITFIELD2" />
<property name="AuditField3" column="AUDITFIELD3" />
<sql-insert>exec PKG_PERSONS.insert_sp ?,?</sql-insert>
</class>
This is the stored procedure:
create or replace package body PKG_PERSONS is
procedure insert_sp(pcod_person persons.cod_person%type,
pname persons.name%type) is
begin
insert into persons(cod_person, name) values(pcod_person, pname);
end;
>From this mapping, I'm expecting Id and Name properties would be send as
parameters, but for sure, this isn't happening; I'm getting this Oracle
error: *ORA-01036: illegal variable name/number*.
NH shows some logs in Console window and it seems like it's trying to map
all properties, included AuditFields, to invoke the stored procedure.
Is this the expected behaviour?
Is it possible to specific what properties send as parameter with
NH3.3/Oracle11g?
Thanks a lot.
--
You received this message because you are subscribed to the Google Groups
"nhusers" group.
To view this discussion on the web visit
https://groups.google.com/d/msg/nhusers/-/gjc-e0ndOJMJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/nhusers?hl=en.