I have a problem to insert a composite-id object into Mysql database
The problem is that before inserting a new object into database I should verify if the object already exist or no
I tried to use Isession.get() but I don't know which identifier should I enter
Code:
<?xml version="1.0" encoding="utf-8" ?>
<hibernate-mapping xmlns="urn:nhibernate-mapping-2.0" auto-import="true" >
<class name="FlatInfo.DataCollector.Service,FlatInfo.DataCollector" table="Service" lazy="true" mutable="true">
<composite-id>
<key-property name="ServiceName" type="System.String"/>
<key-property name="Version" type="System.String"/>
</composite-id>
</class>
</hibernate-mapping>
or should i change the mapping file and manage to have an auto generated id
Please is there any one to help it is urgent!!!!!
Execuse me if I sent the topic many times I m new menber in the forum
[/quote]