콘텐츠로 건너뛰기
메뉴
커뮤니티에 참여하려면 회원 가입을 하시기 바랍니다.
신고된 질문입니다
1 회신
5737 화면


I need to create new records who need to have a specific ID. For
example, a new product.template with the ID 2. The prolem is that the
create() method from the ORM create my new record with anothed ID that
the one I give him as values.

Is it possible, with the Odoo ORM API, to create records with a
specific ID or do I need to do SQL?



아바타
취소
베스트 답변

You should use the External ID for that purpose.

아바타
취소
작성자

Based on this: https://www.odoo.com/documentation/master/glossary.html#term-external-id

External ID is completely different to id field. Not what I need.

작성자

thanks anyway ;)

I know, but you should never touch the internal ID in any system.

twanda AG
Ermin Trevisan
Artherstrasse 19
CH-6318 Walchwil
T +41 41 758 1515
M +41 79 208 7373

On 11 Jun 2019, at 09:15, Sebastien G <sebastien.gendre@hasa.ch> wrote:

thanks anyway ;)

Sent by Odoo S.A. using Odoo.

관련 게시물 답글 화면 활동
5
2월 24
12782
1
3월 15
9643
0
3월 15
4891
1
6월 18
3622
4
1월 17
8241