Re: Retrieve inserted id in mass insert using SqlMapExecutor.

2009-07-09 Thread Jeff Butler
> has been executed > > > > > > -Original Message- > > From: Westhveg [mailto:westhstud...@gmail.com] > > Sent: 09 July 2009 02:27 PM > > To: user-java@ibatis.apache.org > > Subject: RE: Retrieve inserted id in mass insert using SqlMapExecutor

RE: Retrieve inserted id in mass insert using SqlMapExecutor.

2009-07-09 Thread Westhveg
nd check this property after the batch > has been executed > > > -Original Message- > From: Westhveg [mailto:westhstud...@gmail.com] > Sent: 09 July 2009 02:27 PM > To: user-java@ibatis.apache.org > Subject: RE: Retrieve inserted id in mass insert using SqlMapExe

RE: Retrieve inserted id in mass insert using SqlMapExecutor.

2009-07-09 Thread meindert
loop through the list and check this property after the batch has been executed -Original Message- From: Westhveg [mailto:westhstud...@gmail.com] Sent: 09 July 2009 02:27 PM To: user-java@ibatis.apache.org Subject: RE: Retrieve inserted id in mass insert using SqlMapExecutor. No, I'

RE: Retrieve inserted id in mass insert using SqlMapExecutor.

2009-07-09 Thread Westhveg
t know for sure, but wouldn't you be able to loop through the list > after the batch has executed and check the id (keyProperty) on your > records? > > > -Original Message- > From: Westhveg [mailto:westhstud...@gmail.com] > Sent: 09 July 2009 11:47 AM > To: user

RE: Retrieve inserted id in mass insert using SqlMapExecutor.

2009-07-09 Thread meindert
rg Subject: RE: Retrieve inserted id in mass insert using SqlMapExecutor. Hello meindert-3, Thanks for your reply. This is correct and in my case is already working. But my problem is when I use batch processes. Remembering the code: public List createRecordsMassively(final Li

RE: Retrieve inserted id in mass insert using SqlMapExecutor.

2009-07-09 Thread Westhveg
Hello meindert-3, Thanks for your reply. This is correct and in my case is already working. But my problem is when I use batch processes. Remembering the code: public List createRecordsMassively(final List records) { getSqlMapClientTemplate().execute(new SqlMapClientCallback() {

RE: Retrieve inserted id in mass insert using SqlMapExecutor.

2009-07-09 Thread meindert
Put the name of the property that hold the ID in the sql map and the record get's updated with the id and your insert statement returns the id object Here is MS SQl example, just replace SELECT @@IDENTITY with the correct query for Mysql to fetch the ID insert into online_upload_log (id