# OrganizationRelationshipsByOrganizationId ## Documentation The relationships of one organization with other organizations, such as parent and daughter. Each request costs 20 tokens of the daily budget of the company. - Catalog: `Pipedrive` - Schema: `Contacts` - Primary Keys: `id` - Retrieve: True - Insert: True - Update: False - Delete: False ## Parameters of Table Function The following parameters can be used to control the behaviour of the table function `OrganizationRelationshipsByOrganizationId`. A value must be provided at all times for required parameters, but optional parameters in general do not need to have a value and the execution will default to a pre-defined behaviour. Values can be specified by position and by name. In both cases, all parameters not specified will be evaluated using their default values. Value specification by position is done by listing all values from the first to the last needed value. For example: a `select * from table(value1, value2, value3)` on a table with four parameters will use the default value for the fourth parameter and the specified values for the first three. Value specification by name is done by listing all values that require a value. For example with `select * from table(name1 => value1, name3 => value3)` on the same table will use the default values for the second and fourth parameters and the specified values for the first and third. | Name | Data Type | Required | Default Value | Documentation | |---|:---:|:---:|:---:|---| | `organization_id` | `int64` | ☑ | | The organization id. | ## Columns of Table Function The columns of the table function `OrganizationRelationshipsByOrganizationId` 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. | Name | Data Type | Label | Required | Documentation | |---|:---:|---|:---:|---| | `active_flag` | `varchar2` | | ☐ | Whether the relationship is active or not. | | `add_time` | `datetime` | | ☐ | The creation date and time of the relationship. | | `calculated_related_org_id` | `int64` | | ☐ | The ID of the linked organization. | | `calculated_type` | `varchar2` | | ☐ | The calculated type of the relationship with the linked organization. | | `id` | `int64` | | ☑ | The ID of the organization relationship. | | `org_id` | `int64` | | ☐ | The ID of the base organization for the returned calculated values. Only taken when writing; empty when read. | | `organization_id` | `int64` | | ☐ | The organization id the rows were read for. | | `rel_linked_org_id_address` | `varchar2` | | ☐ | The address of the organization. | | `rel_linked_org_id_cc_email` | `varchar2` | | ☐ | The BCC email of the organization associated with the item. | | `rel_linked_org_id_name` | `varchar2` | | ☐ | The name of the organization associated with the item. | | `rel_linked_org_id_owner_id` | `int64` | | ☐ | The ID of the owner of the organization that is associated with the item. | | `rel_linked_org_id_people_count` | `int64` | | ☐ | The number of people connected with the organization that is associated with the item. | | `rel_linked_org_id_value` | `int64` | | ☐ | The ID of the organization. | | `rel_linked_org_id` | `int64` | | ☐ | The linked organization in this relationship. Only taken when writing; empty when read. | | `rel_owner_org_id_address` | `varchar2` | | ☐ | The address of the organization. | | `rel_owner_org_id_cc_email` | `varchar2` | | ☐ | The BCC email of the organization associated with the item. | | `rel_owner_org_id_name` | `varchar2` | | ☐ | The name of the organization associated with the item. | | `rel_owner_org_id_owner_id` | `int64` | | ☐ | The ID of the owner of the organization that is associated with the item. | | `rel_owner_org_id_people_count` | `int64` | | ☐ | The number of people connected with the organization that is associated with the item. | | `rel_owner_org_id_value` | `int64` | | ☐ | The ID of the organization. | | `rel_owner_org_id` | `int64` | | ☐ | The owner of this relationship. Only taken when writing; empty when read. | | `related_organization_name` | `varchar2` | | ☐ | The name of the linked organization. | | `type` | `varchar2` | | ☐ | The type of the relationship. | | `update_time` | `datetime` | | ☐ | The last updated date and time of the relationship. |