# Fixing product cost prices

**URL:** https://discuss.tryton.org/t/fixing-product-cost-prices/8224
**Category:** User
**Tags:** stock
**Created:** [January 23, 2025, 9:03am UTC](https://discuss.tryton.org/t/fixing-product-cost-prices/8224 "2025-01-23T09:03:45Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![Xavi](https://discuss-cdn.tryton.org/letter_avatar_proxy/v4/letter/x/8e8cbc/32.png) [@Xavi](https://discuss.tryton.org/u/Xavi)
#### Post date: [January 23, 2025, 9:03am UTC](https://discuss.tryton.org/t/fixing-product-cost-prices/8224/1 "2025-01-23T09:03:45Z")

</div>

Hi, I have an old database which has been running for years, and sometimes an user reports a product with a wrong cost price, and always find an old record (purchase, production, whatever) with wrong user input which is causing the wrong value on the product’s cost price.  
After manually fixing data, it turns out that this product is used as input in productions for other products, which means the produced product also has a wrong cost price, and this is a loop until there is no more productions/products involved.  
It just happened a few times but if there’s a lot of records involved, it its quite complex to fix, so, as products have a “Recompute cost price” wizard, is there any existent tool in tryton to recursively recompute products/productions costs given a product and a date? and in case there’s not, is there any easier/friendly way to face this kind of problems?  
Thanks.

---

<div class="post-metadata">

### Author: ![ced](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/ced/32/1237_2.png) [@ced](https://discuss.tryton.org/u/ced)
#### Post date: [January 23, 2025, 10:26am UTC](https://discuss.tryton.org/t/fixing-product-cost-prices/8224/2 "2025-01-23T10:26:20Z")

</div>

The [scheduled task](https://docs.tryton.org/latest/modules-stock/usage/index.html#updating-a-product-s-cost-price) will recompute the cost prices for every products that needed it from the proper date when a price is modified on a related stock move.

---

<div class="post-metadata">

### Author: ![Xavi](https://discuss-cdn.tryton.org/letter_avatar_proxy/v4/letter/x/8e8cbc/32.png) [@Xavi](https://discuss.tryton.org/u/Xavi)
#### Post date: [January 23, 2025, 12:14pm UTC](https://discuss.tryton.org/t/fixing-product-cost-prices/8224/3 "2025-01-23T12:14:43Z")

</div>

If I modify the price of a stock move, the scheduled task will recompute the cost price of THIS product, but if this product is used as input to produce others, will the scheduled task update the output price of this production, and then recompute the products cost price, and check if this product is also used on others productions to do exactly the same?

ps: Im not asking to implement such thing in tryton, or modify what tryton already has, just want to know if there’s already tools to manage this kind of situations.

---

<div class="post-metadata">

### Author: ![ced](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/ced/32/1237_2.png) [@ced](https://discuss.tryton.org/u/ced)
#### Post date: [January 23, 2025, 12:20pm UTC](https://discuss.tryton.org/t/fixing-product-cost-prices/8224/4 "2025-01-23T12:20:57Z")

</div>

> [@Xavi](#):
>
> but if this product is used as input to produce others, will the scheduled task update the output price of this production

Yes with the [_Set Cost from Moves_ task](https://docs.tryton.org/latest/modules-production/design.html#production).

> [@Xavi](#):
>
> check if this product is also used on others productions to do exactly the same?

Yes because as the system will update the price of the output of the production (which is an input for the warehouse), the task will detect it.

---

<div class="post-metadata">

### Author: ![Xavi](https://discuss-cdn.tryton.org/letter_avatar_proxy/v4/letter/x/8e8cbc/32.png) [@Xavi](https://discuss.tryton.org/u/Xavi)
#### Post date: [January 23, 2025, 12:25pm UTC](https://discuss.tryton.org/t/fixing-product-cost-prices/8224/5 "2025-01-23T12:25:46Z")

</div>

> [@ced](#):
>
> Yes with the [_Set Cost from Moves_ task](https://docs.tryton.org/latest/modules-production/design.html#production).

Ok, I was not aware of this task, looks like it is exactly what I was looking for.  
Thank you so much for the answers.

---

<div class="post-metadata">

### Author: ![system](https://discuss-cdn.tryton.org/uploads/default/original/1X/c6f8ec0a40525cdcd50058c734283450a4b3d38b.png) [@system](https://discuss.tryton.org/u/system)
#### Post date: [January 24, 2025, 12:26pm UTC](https://discuss.tryton.org/t/fixing-product-cost-prices/8224/6 "2025-01-24T12:26:23Z")

</div>

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.
