Skip to Content
Meniu
Trebuie să fiți înregistrat pentru a interacționa cu comunitatea.
Această întrebare a fost marcată
2 Răspunsuri
143 Vizualizări

I tried to import journal entries with analytic distribution, I tried to put them in a JSON form but when I made the import the analytic distribution was empty

this form I tried:
{"analytic account name": percentage}

here is an example

01/04/2025 JV Tax invoice# CR-13531 Materials & Raw Materials 625.00 {"Al Khan G + 15 - 211": 100}
Vat 5% 31.25
Suppliers & Creditors Al Dammam Elect. & Sanit. Ware Trdg. 656.25


what should I do so the analytic distribution is imported correctly?

Imagine profil
Abandonează
Cel mai bun răspuns

Hi,


In Odoo, analytic distributions must be imported using the analytic account’s external ID or database ID, not its name. When you tried {"Al Khan G + 15 - 211": 100}, Odoo couldn’t match the name, so the distribution was left empty. To fix this, you should first get the external ID of the analytic account (via Settings → Technical → External Identifiers), then use that in the JSON field, for example {"analytic_al_khan_211": 100}. If you need to split across multiple accounts, you can add more keys and percentages, like {"analytic_al_khan_211": 70, "analytic_other_project": 30}. This way, the analytic distribution will import correctly.



For more information, refer to  the following


OCA Module

* https://odoo-community.org/groups/contributors-15/contributors-1936163


Solved Forum

* https://www.odoo.com/es/forum/ayuda-1/analytic-distribution-analytic-account-import-journal-entry-via-excel-236457

* https://www.odoo.com/es/forum/ayuda-1/v16-how-do-i-import-journal-entries-with-an-analytic-account-distribution-226866


Hope it helps

Imagine profil
Abandonează
Autor

thank you for the help
I took the database id for the analytic account and it worked perfectly

Cel mai bun răspuns

The most reliable and dependable way to understand how to import anything in Odoo is to first create a record representing what you want to import and EXPORT it first.

You will then see that the format of the Analytic Distribution field is the ID (ie: 90) of the Analytic Account:

{"90", 100.0}
Imagine profil
Abandonează
Related Posts Răspunsuri Vizualizări Activitate
0
sept. 25
106
4
sept. 25
1216
3
sept. 25
312
1
aug. 25
238
1
aug. 25
314