---
title: "rule (Odoo)"
description: "itgen_odoo_rule"
language: en
source_language: en
translation_state: complete
canonical: https://documentation.invantive.eu/en/datamodels/odoo/Odoo.stock.rule
original: https://documentation.invantive.eu/en/datamodels/odoo/Odoo.stock.rule
updated: 2023-03-01T15:29:04Z
license: https://documentation.invantive.eu/en/
---

# rule: Odoo itgen_odoo_rule

`read only` `per partition`

- Catalog: `Odoo`
- Schema: `stock`
- Label: itgen_odoo_rule

Stock Rule

Can only retrieve data.

## Summary

A rule describe what a procurement should do; produce, buy, move, ...

## Table Columns

The columns of the table `rule` are shown below. Each column has an SQL data type. A new non-null value must be provided for every required column at all times during insert and update.

| Name | Data Type | Label | Required | Marks | Documentation |
|---|---|---|:---:|---|---|
| `action` | `varchar2` | Action | [x] |  |  |
| `active` | `boolean` | Active | [ ] |  | If unchecked, it will allow you to hide the rule without removing it. |
| `auto` | `varchar2` | Automatic Move | [x] |  | The 'Manual Operation' value will create a stock move after the current one. With 'Automatic No Step Added', the location is replaced in the original move. |
| `company_id` | `varchar2` |  | [ ] |  |  |
| `company_id_label` | `varchar2` |  | [ ] |  |  |
| `create_date` | `datetime` | Created on | [ ] |  |  |
| `create_uid` | `varchar2` |  | [ ] |  |  |
| `create_uid_label` | `varchar2` |  | [ ] |  |  |
| `delay` | `int32` | Lead Time | [ ] |  | The expected date of the created transfer will be computed based on this lead time. |
| `display_name` | `varchar2` | Display Name | [ ] |  |  |
| `group_id` | `varchar2` |  | [ ] |  |  |
| `group_id_label` | `varchar2` |  | [ ] |  |  |
| `group_propagation_option` | `varchar2` | Propagation of Procurement Group | [ ] |  |  |
| `id` | `int32` | ID | [ ] |  |  |
| `location_dest_id` | `varchar2` |  | [ ] |  |  |
| `location_dest_id_label` | `varchar2` |  | [ ] |  |  |
| `location_src_id` | `varchar2` |  | [ ] |  |  |
| `location_src_id_label` | `varchar2` |  | [ ] |  |  |
| `name` | `varchar2` | Name | [x] |  | This field will fill the packing origin and the name of its moves |
| `partner_address_id` | `varchar2` |  | [ ] |  | Address where goods should be delivered. Optional. |
| `partner_address_id_label` | `varchar2` |  | [ ] |  | Address where goods should be delivered. Optional. |
| `picking_type_code_domain` | `varchar2` | Picking Type Code Domain | [ ] |  |  |
| `picking_type_id` | `varchar2` |  | [ ] |  |  |
| `picking_type_id_label` | `varchar2` |  | [ ] |  |  |
| `procure_method` | `varchar2` | Supply Method | [x] |  | Take From Stock: the products will be taken from the available stock of the source location. Trigger Another Rule: the system will try to find a stock rule to bring the products in the source location. The available stock will be ignored. Take From Stock, if Unavailable, Trigger Another Rule: the products will be taken from the available stock of the source location.If there is no stock available, the system will try to find a  rule to bring the products in the source location. |
| `propagate_cancel` | `boolean` | Cancel Next Move | [ ] |  | When ticked, if the move created by this rule is cancelled, the next move will be cancelled too. |
| `propagate_carrier` | `boolean` | Propagation of carrier | [ ] |  | When ticked, carrier of shipment will be propagated. |
| `propagate_warehouse_id` | `varchar2` |  | [ ] |  | The warehouse to propagate on the created move/procurement, which can be different of the warehouse this rule is for (e.g for resupplying rules from another warehouse) |
| `propagate_warehouse_id_label` | `varchar2` |  | [ ] |  | The warehouse to propagate on the created move/procurement, which can be different of the warehouse this rule is for (e.g for resupplying rules from another warehouse) |
| `route_company_id` | `varchar2` |  | [ ] |  | Leave this field empty if this route is shared between all companies |
| `route_company_id_label` | `varchar2` |  | [ ] |  | Leave this field empty if this route is shared between all companies |
| `route_id` | `varchar2` |  | [ ] |  |  |
| `route_id_label` | `varchar2` |  | [ ] |  |  |
| `route_sequence` | `int32` | Route Sequence | [ ] |  |  |
| `rule_message` | `varchar2` | Rule Message | [ ] |  |  |
| `sequence` | `int32` | Sequence | [ ] |  |  |
| `warehouse_id` | `varchar2` |  | [ ] |  |  |
| `warehouse_id_label` | `varchar2` |  | [ ] |  |  |
| `write_date` | `datetime` | Last Updated on | [ ] |  |  |
| `write_uid` | `varchar2` |  | [ ] |  |  |
| `write_uid_label` | `varchar2` |  | [ ] |  |  |



## Release Notes

What changed per release in the tables, columns, attributes and capabilities of the driver:

- [Odoo](/en/release-notes/drivers?driver=odoo)

