[Openerp-community] OpenERP 6.1 transaction issue

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

[Openerp-community] OpenERP 6.1 transaction issue

Sam Lefever
Dear community,

We are facing a problem passing our code in 6.1 version.
We try to insert data in a transaction and in the same transaction, looking for those data.
It was working perfectly in 6.0, but not anymore in 6.1.

Does someone have an idea for what is the change between versions?

Thanks for any help,

Regards

Sam
 
_______________
Samuel Lefever
Software Engineer
Tel : +32 2 333.58.52
GSM : +32 471 88.88.83
Email : [hidden email]

_______________
TAKTIK SA
Grote Baan 225
1620 Drogenbos
Tel : +32 2 333.58.40
Fax : +32 2 648.16.53

 






_______________________________________________
Mailing list: https://launchpad.net/~openerp-community
Post to     : [hidden email]
Unsubscribe : https://launchpad.net/~openerp-community
More help   : https://help.launchpad.net/ListHelp
Reply | Threaded
Open this post in threaded view
|

Re: [Openerp-community] OpenERP 6.1 transaction issue

Eric Caudal - www.elico-corp.com
http://www.openerp.com/forum/post101050.html#p101050
There is as well a community project for this matter: https://launchpad.net/openupgrade-server

Good luck

Eric CAUDAL
openerp
Eric CAUDAL, Elico Corp, Shanghai.
[hidden email]
Cell: + 86 186 2136 1670. Skype: elico.corp
Premium Certified Training Partner - OpenERP Ready Partner.

Premium CTP
http://www.openerp.net.cn

On 06/18/2012 04:16 PM, Sam Lefever wrote:
Dear community,

We are facing a problem passing our code in 6.1 version.
We try to insert data in a transaction and in the same transaction, looking for those data.
It was working perfectly in 6.0, but not anymore in 6.1.

Does someone have an idea for what is the change between versions?

Thanks for any help,

Regards

Sam
 
_______________
Samuel Lefever
Software Engineer
Tel : +32 2 333.58.52
GSM : +32 471 88.88.83
Email : [hidden email]

_______________
TAKTIK SA
Grote Baan 225
1620 Drogenbos
Tel : +32 2 333.58.40
Fax : +32 2 648.16.53

 







_______________________________________________
Mailing list: https://launchpad.net/~openerp-community
Post to     : [hidden email]
Unsubscribe : https://launchpad.net/~openerp-community
More help   : https://help.launchpad.net/ListHelp

_______________________________________________
Mailing list: https://launchpad.net/~openerp-community
Post to     : [hidden email]
Unsubscribe : https://launchpad.net/~openerp-community
More help   : https://help.launchpad.net/ListHelp
Reply | Threaded
Open this post in threaded view
|

Re: [Openerp-community] OpenERP 6.1 transaction issue

Sam Lefever
Hello and thanks for the answer.

But, if I understood the project, the links your sent are for DB migration, am I right?
We are facing problem with code migration.

Thanks

Sam
_______________
Samuel Lefever
Software Engineer
Tel : +32 2 333.58.52
GSM : +32 471 88.88.83
Email : [hidden email]

_______________
TAKTIK SA
Grote Baan 225
1620 Drogenbos
Tel : +32 2 333.58.40
Fax : +32 2 648.16.53

 





Le 18 juin 2012 à 10:31, Eric Caudal <[hidden email]>
 a écrit :

http://www.openerp.com/forum/post101050.html#p101050
There is as well a community project for this matter: https://launchpad.net/openupgrade-server

Good luck

Eric CAUDAL
<Logo-Elico90.gif>
Eric CAUDAL, Elico Corp, Shanghai.
[hidden email]
Cell: + 86 186 2136 1670. Skype: elico.corp
Premium Certified Training Partner - OpenERP Ready Partner.

<CTP-Premium-Partner-logo-300x62.png>
http://www.openerp.net.cn

On 06/18/2012 04:16 PM, Sam Lefever wrote:
Dear community,

We are facing a problem passing our code in 6.1 version.
We try to insert data in a transaction and in the same transaction, looking for those data.
It was working perfectly in 6.0, but not anymore in 6.1.

Does someone have an idea for what is the change between versions?

Thanks for any help,

Regards

Sam
 
_______________
Samuel Lefever
Software Engineer
Tel : +32 2 333.58.52
GSM : +32 471 88.88.83
Email : [hidden email]

_______________
TAKTIK SA
Grote Baan 225
1620 Drogenbos
Tel : +32 2 333.58.40
Fax : +32 2 648.16.53

 


<Pièce jointe.gif>





_______________________________________________
Mailing list: https://launchpad.net/~openerp-community
Post to     : [hidden email]
Unsubscribe : https://launchpad.net/~openerp-community
More help   : https://help.launchpad.net/ListHelp
_______________________________________________
Mailing list: https://launchpad.net/~openerp-community
Post to     : [hidden email]
Unsubscribe : https://launchpad.net/~openerp-community
More help   : https://help.launchpad.net/ListHelp


_______________________________________________
Mailing list: https://launchpad.net/~openerp-community
Post to     : [hidden email]
Unsubscribe : https://launchpad.net/~openerp-community
More help   : https://help.launchpad.net/ListHelp
Reply | Threaded
Open this post in threaded view
|

Re: [Openerp-community] OpenERP 6.1 transaction issue

Stefan Rijnhart (Therp)
In reply to this post by Sam Lefever
On 18-06-12 10:16, Sam Lefever wrote:
Dear community,

We are facing a problem passing our code in 6.1 version.
We try to insert data in a transaction and in the same transaction, looking for those data.
It was working perfectly in 6.0, but not anymore in 6.1.

Does someone have an idea for what is the change between versions?


Hi Sam,

What it reminds me of is the need to refresh browse records after having written to them (in OpenERP 6.1):

partner = self.pool.get('res.partner').browse(cr, uid, 1)
print partner.name # prints old name
self.pool.get('res.partner').write(cr, uid, {'name': 'New name'}
print partner.name # prints old name
partner.refresh()
print partner.name # prints new name

But this was more problematic in 6.0 as the refresh() method was not yet available, and a new browse record needed to be created instead.

If you are facing a different issue, can you give a snippet of the code that illustrates your problem?

Cheers,
Stefan.

-- 
Therp - Maatwerk in open ontwikkeling

Stefan Rijnhart - Ontwerp en implementatie

mail: [hidden email]
tel: +31 (0) 614478606
http://therp.nl
https://twitter.com/therp_stefan

_______________________________________________
Mailing list: https://launchpad.net/~openerp-community
Post to     : [hidden email]
Unsubscribe : https://launchpad.net/~openerp-community
More help   : https://help.launchpad.net/ListHelp
Reply | Threaded
Open this post in threaded view
|

Re: [Openerp-community] OpenERP 6.1 transaction issue

Stefan Rijnhart (Therp)

self.pool.get('res.partner').write(cr, uid, {'name': 'New name'}

Would not want to befog the kids trying this out at home, so rather

    self.pool.get('res.partner').write(cr, uid, 1, {'name': 'New name'})



-- 
Therp - Maatwerk in open ontwikkeling

Stefan Rijnhart - Ontwerp en implementatie

mail: [hidden email]
tel: +31 (0) 614478606
http://therp.nl
https://twitter.com/therp_stefan

_______________________________________________
Mailing list: https://launchpad.net/~openerp-community
Post to     : [hidden email]
Unsubscribe : https://launchpad.net/~openerp-community
More help   : https://help.launchpad.net/ListHelp
Reply | Threaded
Open this post in threaded view
|

Re: [Openerp-community] OpenERP 6.1 transaction issue

Sam Lefever
Thanks for your answers.
We finally found the reason (that s in our code) why we didn't have access to the update data in the same transaction.

Thanks all,

Sam

_______________
Samuel Lefever
Software Engineer
Tel : +32 2 333.58.52
GSM : +32 471 88.88.83
Email : [hidden email]

_______________
TAKTIK SA
Grote Baan 225
1620 Drogenbos
Tel : +32 2 333.58.40
Fax : +32 2 648.16.53

 





Le 18 juin 2012 à 13:05, Stefan Rijnhart <[hidden email]> a écrit :


self.pool.get('res.partner').write(cr, uid, {'name': 'New name'}

Would not want to befog the kids trying this out at home, so rather

    self.pool.get('res.partner').write(cr, uid, 1, {'name': 'New name'})



-- 
Therp - Maatwerk in open ontwikkeling

Stefan Rijnhart - Ontwerp en implementatie

mail: [hidden email]
tel: +31 (0) 614478606
http://therp.nl
https://twitter.com/therp_stefan
_______________________________________________
Mailing list: https://launchpad.net/~openerp-community
Post to     : [hidden email]
Unsubscribe : https://launchpad.net/~openerp-community
More help   : https://help.launchpad.net/ListHelp


_______________________________________________
Mailing list: https://launchpad.net/~openerp-community
Post to     : [hidden email]
Unsubscribe : https://launchpad.net/~openerp-community
More help   : https://help.launchpad.net/ListHelp