# Ordway schema ERD

Table and field reference for the Fivetran Ordway connector.

## Table & Field Reference

### statement

| Column | Type | Keys |
| --- | --- | --- |
| statement_id | Unknown | PK |
| customer_id | Unknown | FK |
| company_id | Unknown |  |
| created_by | Unknown |  |
| created_date | Unknown |  |
| end_date | Unknown |  |
| integer | Unknown |  |
| start_date | Unknown |  |
| statement_date | Unknown |  |
| template_id | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Unknown |  |
| url | Unknown |  |

### credit_line_item

| Column | Type | Keys |
| --- | --- | --- |
| line_no | Unknown | PK |
| credit_id | Unknown | PK, FK |
| product_id | Unknown | FK |
| credit_account | Unknown |  |
| description | Unknown |  |
| effective_price | Unknown |  |
| line_tax | Unknown |  |
| product_name | Unknown |  |
| quantity | Unknown |  |
| tax_override | Unknown |  |
| taxable | Unknown |  |
| unit_price | Unknown |  |

### credit_subtotal

| Column | Type | Keys |
| --- | --- | --- |
| _fivetran_id | String | PK |
| credit_id | Unknown | FK |
| subtotal_name | Unknown |  |
| value | Unknown |  |

### credit_invoice

| Column | Type | Keys |
| --- | --- | --- |
| credit_id | Unknown | PK, FK |
| id | Unknown | PK, FK |
| amount_applied | Unknown |  |
| created_by | Unknown |  |
| created_date | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Unknown |  |

### credit_custom_field

| Column | Type | Keys |
| --- | --- | --- |
| name | Unknown | PK |
| credit_id | Unknown | PK, FK |
| value | Unknown |  |

### credit

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| customer_id | Unknown | FK |
| applied_amount | Unknown |  |
| auto_apply | Unknown |  |
| billing_contact_address_1 | Unknown |  |
| billing_contact_address_2 | Unknown |  |
| billing_contact_city | Unknown |  |
| billing_contact_country | Unknown |  |
| billing_contact_county | Unknown |  |
| billing_contact_department | Unknown |  |
| billing_contact_display_name | Unknown |  |
| billing_contact_email | Unknown |  |
| billing_contact_first_name | Unknown |  |
| billing_contact_job_title | Unknown |  |
| billing_contact_last_name | Unknown |  |
| billing_contact_mobile | Unknown |  |
| billing_contact_notes | Unknown |  |
| billing_contact_phone | Unknown |  |
| billing_contact_state | Unknown |  |
| billing_contact_zip | Unknown |  |
| conversion_rate | Unknown |  |
| created_by | Unknown |  |
| created_date | Unknown |  |
| credit_amount | Unknown |  |
| credit_date | Unknown |  |
| credit_tax | Unknown |  |
| credit_type | Unknown |  |
| currency | Unknown |  |
| gl_account | Unknown |  |
| l_grouping_for_calculations | Unknown |  |
| notes | Unknown |  |
| reference_number | Unknown |  |
| refunds | Json |  |
| reversed_on | Unknown |  |
| shipping_contact_address_1 | Unknown |  |
| shipping_contact_address_2 | Unknown |  |
| shipping_contact_city | Unknown |  |
| shipping_contact_country | Unknown |  |
| shipping_contact_county | Unknown |  |
| shipping_contact_department | Unknown |  |
| shipping_contact_display_name | Unknown |  |
| shipping_contact_email | Unknown |  |
| shipping_contact_first_name | Unknown |  |
| shipping_contact_job_title | Unknown |  |
| shipping_contact_last_name | Unknown |  |
| shipping_contact_mobile | Unknown |  |
| shipping_contact_notes | Unknown |  |
| shipping_contact_phone | Unknown |  |
| shipping_contact_state | Unknown |  |
| shipping_contact_zip | Unknown |  |
| status | Unknown |  |
| subtotal | Unknown |  |
| unapplied_amount | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Instant |  |

### revenue_rule_custom_field

| Column | Type | Keys |
| --- | --- | --- |
| name | Unknown | PK |
| revenue_rule_id | Unknown | PK, FK |
| value | Unknown |  |

### revenue_rule

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| created_by | Unknown |  |
| created_date | Unknown |  |
| name | Unknown |  |
| posting_day | Unknown |  |
| posting_method | Unknown |  |
| recognition_method | Unknown |  |
| recognition_schedule_period | Unknown |  |
| recognition_term | Unknown |  |
| status | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Unknown |  |

### plan_charge_transaction_posting_entries

| Column | Type | Keys |
| --- | --- | --- |
| _fivetran_id | String | PK |
| plan_charge_id | Unknown | PK, FK |
| plan_id | Unknown | PK, FK |
| credit_account | Unknown |  |
| debit_account | Unknown |  |
| transaction_type | Unknown |  |

### plan_charge_tier

| Column | Type | Keys |
| --- | --- | --- |
| _fivetran_id | String | PK |
| plan_charge_id | Unknown | PK, FK |
| plan_id | Unknown | PK, FK |
| ending_unit | Unknown |  |
| price | Unknown |  |
| starting_unit | Unknown |  |
| tier | Unknown |  |
| type | Unknown |  |

### plan_charge_custom_field

| Column | Type | Keys |
| --- | --- | --- |
| name | Unknown | PK |
| plan_charge_id | Unknown | PK, FK |
| plan_id | Unknown | PK, FK |
| value | Unknown |  |

### plan_charge

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| plan_id | Unknown | PK, FK |
| product_id | Unknown | FK |
| revenue_rule_id | Unknown | FK |
| auto_refill_prepayment_units | Unknown |  |
| backcharge_current_period | Unknown |  |
| billing_day | Unknown |  |
| billing_period | Unknown |  |
| billing_period_start_alignment | Unknown |  |
| charge_billing_date | Unknown |  |
| charge_inherited_product | Unknown |  |
| dealhub_name | Unknown |  |
| defaults_from_product | Unknown |  |
| description | Unknown |  |
| effective_date | Unknown |  |
| included_units | Unknown |  |
| line_no | Unknown |  |
| list_price | Unknown |  |
| name | Unknown |  |
| original_type | Unknown |  |
| prepaid_units_enable | Unknown |  |
| prepaid_units_expiry | Unknown |  |
| prepayment_amount | Unknown |  |
| prepayment_periods | Unknown |  |
| pricing_model | Unknown |  |
| recognition_start_date | Unknown |  |
| refill_prepaid_units_for | Unknown |  |
| refill_qty | Unknown |  |
| refund_units_on_cancel | Unknown |  |
| salesforce_charge_id | Unknown |  |
| salesforce_id | Unknown |  |
| timing | Unknown |  |
| transaction_price | Unknown |  |
| type | Unknown |  |
| unit_of_measure | Unknown |  |
| unused_prepayment_units | Unknown |  |

### plan_custom_field

| Column | Type | Keys |
| --- | --- | --- |
| name | Unknown | PK |
| plan_id | Unknown | PK, FK |
| value | Unknown |  |

### plan

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| created_by | Unknown |  |
| created_date | Unknown |  |
| description | Unknown |  |
| discount_tiers | Unknown |  |
| historical_zuora_id | Unknown |  |
| name | Unknown |  |
| public_url | Unknown |  |
| salesforce_id | Unknown |  |
| status | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Instant |  |

### product_transaction_posting_entry

| Column | Type | Keys |
| --- | --- | --- |
| _fivetran_id | String | PK |
| product_id | Unknown | FK |
| credit_account | Unknown |  |
| debit_account | Unknown |  |
| transaction_type | Unknown |  |

### product_custom_field

| Column | Type | Keys |
| --- | --- | --- |
| name | Unknown | PK |
| product_id | Unknown | PK, FK |
| value | Unknown |  |

### product

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| revenue_rule_id | Unknown | FK |
| country | Unknown |  |
| created_by | Unknown |  |
| created_date | Unknown |  |
| currency | Unknown |  |
| description | Unknown |  |
| location_id | Unknown |  |
| name | Unknown |  |
| price | Unknown |  |
| primary_tag | Unknown |  |
| product_code | Unknown |  |
| recognition_start_date | Unknown |  |
| region | Unknown |  |
| salesforce_id | Unknown |  |
| show_revenue_schedules | Unknown |  |
| sku | Unknown |  |
| status | Unknown |  |
| taxable | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Unknown |  |

### orders_line_item_custom_field

| Column | Type | Keys |
| --- | --- | --- |
| name | Unknown | PK |
| orders_line_item_line_no | Unknown | PK, FK |
| orders_line_item_orders_id | Unknown | PK, FK |
| value | Unknown |  |

### orders_line_item

| Column | Type | Keys |
| --- | --- | --- |
| line_no | Unknown | PK |
| orders_id | Unknown | PK, FK |
| product_id | Unknown | FK |
| description | Unknown |  |
| discount | Unknown |  |
| effective_price | Unknown |  |
| product_name | Unknown |  |
| quantity | Unknown |  |
| unit_price | Unknown |  |

### orders_custom_field

| Column | Type | Keys |
| --- | --- | --- |
| name | Unknown | PK |
| orders_id | Unknown | PK, FK |
| value | Unknown |  |

### orders

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| coupon_code | Unknown | FK |
| customer_id | Unknown | FK |
| invoice_id | Unknown | FK |
| bill_contact_id | Unknown |  |
| company_name | Unknown |  |
| created_by | Unknown |  |
| created_date | Unknown |  |
| currency | Unknown |  |
| notes | Unknown |  |
| order_amount | Unknown |  |
| order_date | Unknown |  |
| payment_terms | Unknown |  |
| separate_invoice | Unknown |  |
| shipping_contact_id | Unknown |  |
| status | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Instant |  |

### refund

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| credit_id | Unknown | FK |
| customer_id | Unknown | FK |
| invoice_id | Unknown | FK |
| payment_id | Unknown | FK |
| created_by | Unknown |  |
| created_date | Unknown |  |
| currency | Unknown |  |
| notes | Unknown |  |
| reference_number | Unknown |  |
| refund_amount | Unknown |  |
| refund_date | Unknown |  |
| refund_status | Unknown |  |
| refund_type | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Instant |  |

### chart_of_account_custom_field

| Column | Type | Keys |
| --- | --- | --- |
| name | Unknown | PK |
| chart_of_account_code | Unknown | PK, FK |
| value | Unknown |  |

### chart_of_account

| Column | Type | Keys |
| --- | --- | --- |
| code | Unknown | PK |
| account_type | Unknown |  |
| created_by | Unknown |  |
| created_date | Unknown |  |
| description | Unknown |  |
| name | Unknown |  |
| parent_account | Unknown |  |
| status | Unknown |  |
| sub_type | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Instant |  |

### payments_run

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| created_by | Unknown |  |
| currency | Unknown |  |
| failure_count | Unknown |  |
| filter_options | Json |  |
| payments_failed_value | Unknown |  |
| payments_success_value | Unknown |  |
| payments_total_value | Unknown |  |
| refunds_failed_value | Unknown |  |
| refunds_success_value | Unknown |  |
| refunds_total_value | Unknown |  |
| status | Unknown |  |
| success_count | Unknown |  |
| target_date | Unknown |  |
| updated_by | Unknown |  |

### billing_run

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| charge_type | Unknown |  |
| created_by | Unknown |  |
| created_date | Unknown |  |
| currency | Unknown |  |
| customer_filter_options | Unknown |  |
| filter_options | Json |  |
| invoice_date | Unknown |  |
| invoices_count | Unknown |  |
| invoices_total | Unknown |  |
| status | Unknown |  |
| subscription_filter_options | Json |  |
| target_date | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Instant |  |

### subscription_plan_transaction_posting_entries

| Column | Type | Keys |
| --- | --- | --- |
| _fivetran_id | String | PK |
| subscription_id | Unknown | FK |
| subscription_plan_id | Unknown | FK |
| subscription_plan_index | Unknown | FK |
| subscription_version | Unknown | FK |
| credit_account | Unknown |  |
| debit_account | Unknown |  |
| transaction_type | Unknown |  |

### subscription_plan_custom_field

| Column | Type | Keys |
| --- | --- | --- |
| name | Unknown | PK |
| subscription_id | Unknown | PK, FK |
| subscription_plan_index | Unknown | PK, FK |
| subscription_version | Unknown | PK, FK |
| subscription_plan_id | Unknown | FK |
| value | Unknown |  |

### subscription_plan

| Column | Type | Keys |
| --- | --- | --- |
| index | Unknown | PK |
| id | Unknown | PK, FK |
| subscription_id | Unknown | PK, FK |
| subscription_version | Unknown | PK, FK |
| charge_id | Unknown | FK |
| product_id | Unknown | FK |
| revenue_rule_id | Unknown | FK |
| revenue_schedule_id | Unknown | FK |
| backcharge_current_period | Unknown |  |
| billing_day | Unknown |  |
| billing_period | Unknown |  |
| billing_period_start_alignment | Unknown |  |
| billing_schedule_id | Unknown |  |
| charge_billing_date | Unknown |  |
| charge_end_date | Unknown |  |
| charge_start_date | Unknown |  |
| charge_timing | Unknown |  |
| charge_type | Unknown |  |
| completion_date | Unknown |  |
| current_period_end_date | Unknown |  |
| current_period_start_date | Unknown |  |
| defaults_from_plan | Unknown |  |
| discount | Unknown |  |
| discount_tiers | Unknown |  |
| effective_date | Unknown |  |
| effective_price | Unknown |  |
| included_units | Unknown |  |
| l_grouping_for_calculations | Unknown |  |
| list_price | Unknown |  |
| list_price_base | Unknown |  |
| original_type | Unknown |  |
| override_renewal_increment_percent | Unknown |  |
| prepayment_enabled | Unknown |  |
| price_base | Unknown |  |
| pricing_model | Unknown |  |
| product_code | Unknown |  |
| prorate_partial_periods | Unknown |  |
| quantity | Unknown |  |
| recognition_start_date | Unknown |  |
| refund_units_on_cancel | Unknown |  |
| region | Unknown |  |
| remove_units_on_cancel | Unknown |  |
| renewal_increment_percent | Unknown |  |
| rewards_discount_eligible | Unknown |  |
| salesforce_id | Unknown |  |
| subscription_line_id | Unknown |  |
| transaction_price | Unknown |  |
| true_up_eligible | Unknown |  |
| unit_of_measure | Unknown |  |
| updated_transaction_price | Unknown |  |

### subscription_custom_field

| Column | Type | Keys |
| --- | --- | --- |
| name | Unknown | PK |
| subscription_id | Unknown | PK, FK |
| subscription_version | Unknown | PK, FK |
| value | Unknown |  |

### subscription

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| version | Unknown | PK |
| customer_id | Unknown | FK |
| auto_renew | Unknown |  |
| bill_contact_id | Unknown |  |
| bill_contact_sf_id | Unknown |  |
| billing_start_date | Unknown |  |
| cancellation_date | Unknown |  |
| cancellation_type | Unknown |  |
| cmrr | Unknown |  |
| contract_effective_date | Unknown |  |
| contract_term | Unknown |  |
| coupon_code | Unknown |  |
| created_by | Unknown |  |
| created_date | Unknown |  |
| currency | Unknown |  |
| current_term_end_date | Unknown |  |
| current_term_start_date | Unknown |  |
| customer_salesforce_id | Unknown |  |
| defer_start_date | Unknown |  |
| discounted_cmrr | Unknown |  |
| historical_zuora_id | Unknown |  |
| min_commited_value | Unknown |  |
| min_commited_value_docv | Unknown |  |
| min_commited_value_idv | Unknown |  |
| min_commited_value_kyb | Unknown |  |
| min_commited_value_mobile_id | Unknown |  |
| min_commited_value_utility_id | Unknown |  |
| min_commited_value_watchlist | Unknown |  |
| min_commitment_end_date | Unknown |  |
| min_commitment_end_date_docv | Unknown |  |
| min_commitment_end_date_idv | Unknown |  |
| min_commitment_end_date_kyb | Unknown |  |
| min_commitment_end_date_mobile_id | Unknown |  |
| min_commitment_end_date_utility_id | Unknown |  |
| min_commitment_end_date_watchlist | Unknown |  |
| mrr | Unknown |  |
| notes | Unknown |  |
| order_placed_at | Unknown |  |
| payment_terms | Unknown |  |
| renewal_increment_percent | Unknown |  |
| renewal_term | Unknown |  |
| salesforce_id | Unknown |  |
| separate_invoice | Unknown |  |
| service_start_date | Unknown |  |
| shipping_contact_id | Unknown |  |
| shipping_contact_sf_id | Unknown |  |
| status | Unknown |  |
| tcv | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Instant |  |
| version_type | Unknown |  |

### billing_schedule_line_custom_field

| Column | Type | Keys |
| --- | --- | --- |
| name | Unknown | PK |
| billing_schedule_line_id | Unknown | PK, FK |
| value | Unknown |  |

### billing_schedule_line

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| billing_schedule_id | Unknown | PK, FK |
| amount | Unknown |  |
| charge_ready_date | Unknown |  |
| created_by | Unknown |  |
| created_date | Unknown |  |
| description | Unknown |  |
| discount | Unknown |  |
| end_date | Unknown |  |
| expired_units | Unknown |  |
| invoiced | Unknown |  |
| l_grouping_for_calculations | Unknown |  |
| line_type | Unknown |  |
| list_price | Unknown |  |
| list_price_base | Unknown |  |
| quantity | Unknown |  |
| start_date | Unknown |  |
| unit_price | Unknown |  |
| unused_prepayment_units | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Unknown |  |
| usages | Json |  |

### billing_schedule_custom_field

| Column | Type | Keys |
| --- | --- | --- |
| name | Unknown | PK |
| billing_schedule_id | Unknown | PK, FK |
| value | Unknown |  |

### billing_schedule

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| charge_id | Unknown | FK |
| customer_id | Unknown | FK |
| product_id | Unknown | FK |
| subscription_id | Unknown | FK |
| created_by | Unknown |  |
| created_date | Unknown |  |
| currency | Unknown |  |
| end_date | Unknown |  |
| key_metrics_amount_invoiced | Unknown |  |
| key_metrics_annual_contract_revenue | Unknown |  |
| key_metrics_monthly_recurring_revenue | Unknown |  |
| key_metrics_total_contract_revenue | Unknown |  |
| start_date | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Instant |  |

### coupon

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| code | Unknown |  |
| created_by | Unknown |  |
| created_date | Unknown |  |
| criteria_value | Unknown |  |
| discount_criteria | Unknown |  |
| discount_type | Unknown |  |
| discount_value | Unknown |  |
| display_text | Unknown |  |
| duration_period | Unknown |  |
| expiration_date | Unknown |  |
| status | Unknown |  |
| trial_type | Unknown |  |
| trial_value | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Unknown |  |
| usage_count | Unknown |  |
| usage_limit | Unknown |  |

### revenue_schedule_line

| Column | Type | Keys |
| --- | --- | --- |
| _fivetran_id | String | PK |
| revenue_schedule_id | Unknown | FK |
| amount | Unknown |  |
| currency | Unknown |  |
| custom_fields | Json |  |
| exchange_rate | Unknown |  |
| financial_period | Unknown |  |
| period_revenue | Unknown |  |
| posted | Unknown |  |
| posting_date | Unknown |  |

### revenue_schedule

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| charge_id | Unknown | FK |
| customer_id | Unknown | FK |
| plan_id | Unknown | FK |
| product_id | Unknown | FK |
| charge_timing | Unknown |  |
| created_by | Unknown |  |
| created_date | Unknown |  |
| end_date | Unknown |  |
| recognized_revenue | Unknown |  |
| source_transaction | Unknown |  |
| start_date | Unknown |  |
| total_revenue | Unknown |  |
| unrecognized_revenue | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Instant |  |

### customer_contact_custom_field

| Column | Type | Keys |
| --- | --- | --- |
| name | Unknown | PK |
| customer_contact_customer_id | Unknown | PK, FK |
| customer_contact_id | Unknown | PK, FK |
| value | Unknown |  |

### customer_contact

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| customer_id | Unknown | PK, FK |
| address_1 | Unknown |  |
| address_2 | Unknown |  |
| city | Unknown |  |
| country | Unknown |  |
| county | Unknown |  |
| created_by | Unknown |  |
| created_date | Unknown |  |
| department | Unknown |  |
| display_name | Unknown |  |
| email | Unknown |  |
| first_name | Unknown |  |
| is_unrelated_contact | Unknown |  |
| job_title | Unknown |  |
| last_name | Unknown |  |
| mobile | Unknown |  |
| notes | Unknown |  |
| phone | Unknown |  |
| salesforce_id | Unknown |  |
| state | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Unknown |  |
| zip | Unknown |  |

### customer_custom_field

| Column | Type | Keys |
| --- | --- | --- |
| name | Unknown | PK |
| customer_id | Unknown | PK, FK |
| value | Unknown |  |

### customer

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| ach_enabled | Unknown |  |
| auto_pay | Unknown |  |
| balance | Unknown |  |
| banking_info | Unknown |  |
| billing_batch | Unknown |  |
| billing_contact_email | Unknown |  |
| billing_contact_id | Unknown |  |
| billing_cycle_day | Unknown |  |
| child_customers | Unknown |  |
| cmrr | Unknown |  |
| created_by | Unknown |  |
| created_date | Unknown |  |
| credit_enabled | Unknown |  |
| cumulative_rewards | Unknown |  |
| currency | Unknown |  |
| customer_type | Unknown |  |
| description | Unknown |  |
| discount_amt | Unknown |  |
| discount_month | Unknown |  |
| discount_tiers | Unknown |  |
| discount_tiers_docv | Unknown |  |
| discount_tiers_idv | Unknown |  |
| discount_tiers_kyb | Unknown |  |
| discount_tiers_mobile_id | Unknown |  |
| discount_tiers_utility_id | Unknown |  |
| discount_tiers_watchlist | Unknown |  |
| discounted_cmrr | Unknown |  |
| edit_auto_pay | Unknown |  |
| email | Unknown |  |
| email_preference | Unknown |  |
| flat_discount_percent | Unknown |  |
| flat_discount_percent_docv | Unknown |  |
| flat_discount_percent_idv | Unknown |  |
| flat_discount_percent_kyb | Unknown |  |
| flat_discount_percent_mobile_id | Unknown |  |
| flat_discount_percent_utility_id | Unknown |  |
| flat_discount_percent_watchlist | Unknown |  |
| historical_zuora_id | Unknown |  |
| last_day_previous_month | Unknown |  |
| name | Unknown |  |
| open_invoices_url | Unknown |  |
| participating_in_rewards_discount | Unknown |  |
| participating_in_true_up | Unknown |  |
| pay_now_url | Unknown |  |
| payment_gateway_id | Unknown |  |
| payment_terms | Unknown |  |
| print | Unknown |  |
| print_preference | Unknown |  |
| salesforce_id | Unknown |  |
| shipping_contact_email | Unknown |  |
| shipping_contact_id | Unknown |  |
| status | Unknown |  |
| suspended | Unknown |  |
| tax_exempt | Unknown |  |
| true_up_start_date | Unknown |  |
| update_payment_method_url | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Instant |  |
| vip | Unknown |  |
| website | Unknown |  |
| zero_balance_needed | Unknown |  |

### payments_invoice

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK, FK |
| payments_id | Unknown | PK, FK |
| amount_applied | Unknown |  |
| created_by | Unknown |  |
| created_date | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Unknown |  |

### payments_refund

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK, FK |
| payments_id | Unknown | PK, FK |
| amount_applied | Unknown |  |
| created_by | Unknown |  |
| created_date | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Unknown |  |

### payments_custom_field

| Column | Type | Keys |
| --- | --- | --- |
| name | Unknown | PK |
| payments_id | Unknown | PK, FK |
| value | Unknown |  |

### payments

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| customer_id | Unknown | FK |
| payment_run_id | Unknown | FK |
| applied_amount | Unknown |  |
| auto_apply | Unknown |  |
| conversion_rate | Unknown |  |
| created_by | Unknown |  |
| created_date | Unknown |  |
| currency | Unknown |  |
| email_status | Unknown |  |
| failed_attempt | Unknown |  |
| failure_reason | Unknown |  |
| fee_amount | Unknown |  |
| gl_account | Unknown |  |
| notes | Unknown |  |
| opt | Json |  |
| payment_amount | Unknown |  |
| payment_date | Unknown |  |
| payment_method | Unknown |  |
| payment_type | Unknown |  |
| reference_number | Unknown |  |
| refunded_amount | Unknown |  |
| retried_attempts | Unknown |  |
| status | Unknown |  |
| unapplied_amount | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Instant |  |

### journal_entry_custom_field

| Column | Type | Keys |
| --- | --- | --- |
| name | Unknown | PK |
| journal_entry_journal_id | Unknown | PK, FK |
| journal_entry_line_no | Unknown | PK, FK |
| value | Unknown |  |

### journal_entry

| Column | Type | Keys |
| --- | --- | --- |
| line_no | Unknown | PK |
| journal_id | Unknown | PK, FK |
| customer_id | Unknown | FK |
| account | Unknown |  |
| credit | Unknown |  |
| customer_name | Unknown |  |
| debit | Unknown |  |
| description | Unknown |  |

### journal

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| conversion_rate | Unknown |  |
| created_by | Unknown |  |
| created_date | Unknown |  |
| date | Unknown |  |
| description | Unknown |  |
| source_id | Unknown |  |
| source_type | Unknown |  |
| transaction_amount | Unknown |  |
| transaction_currency | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Instant |  |

### invoice_line_item_tax_line

| Column | Type | Keys |
| --- | --- | --- |
| _fivetran_id | String | PK |
| invoice_line_item_line_no | Unknown | FK |
| name | Unknown |  |
| value | Unknown |  |

### invoice_line_item_custom_field

| Column | Type | Keys |
| --- | --- | --- |
| name | Unknown | PK |
| invoice_line_item_invoice_id | Unknown | PK, FK |
| invoice_line_item_line_no | Unknown | PK, FK |
| value | Unknown |  |

### invoice_line_item

| Column | Type | Keys |
| --- | --- | --- |
| line_no | Unknown | PK |
| invoice_id | Unknown | PK, FK |
| charge_id | Unknown | FK |
| customer_id | Unknown | FK |
| plan_id | Unknown | FK |
| product_id | Unknown | FK |
| subscription_id | Unknown | FK |
| subscription_line_id | Unknown | FK |
| applied_tiers | Json |  |
| charge_type | Unknown |  |
| description | Unknown |  |
| discount | Unknown |  |
| effective_price | Unknown |  |
| end_date | Unknown |  |
| included_quantity | Unknown |  |
| line_tax | Unknown |  |
| list_price | Unknown |  |
| list_price_base | Unknown |  |
| quantity | Unknown |  |
| start_date | Unknown |  |
| taxable | Unknown |  |
| unit_price | Unknown |  |

### invoice_subtotal

| Column | Type | Keys |
| --- | --- | --- |
| _fivetran_id | String | PK |
| invoice_id | Unknown | FK |
| subtotal_name | Unknown |  |
| value | Unknown |  |

### invoice_custom_field

| Column | Type | Keys |
| --- | --- | --- |
| name | Unknown | PK |
| invoice_id | Unknown | PK, FK |
| value | Unknown |  |

### invoice

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| customer_id | Unknown | FK |
| balance | Unknown |  |
| billing_contact_address_1 | Unknown |  |
| billing_contact_address_2 | Unknown |  |
| billing_contact_city | Unknown |  |
| billing_contact_country | Unknown |  |
| billing_contact_county | Unknown |  |
| billing_contact_department | Unknown |  |
| billing_contact_display_name | Unknown |  |
| billing_contact_email | Unknown |  |
| billing_contact_first_name | Unknown |  |
| billing_contact_job_title | Unknown |  |
| billing_contact_last_name | Unknown |  |
| billing_contact_mobile | Unknown |  |
| billing_contact_phone | Unknown |  |
| billing_contact_state | Unknown |  |
| billing_contact_zip | Unknown |  |
| billing_run_id | Unknown |  |
| created_by | Unknown |  |
| created_date | Unknown |  |
| credits | Json |  |
| currency | Unknown |  |
| discount_display_name | Unknown |  |
| due_date | Unknown |  |
| emailed | Unknown |  |
| end_date | Unknown |  |
| exchange_rate | Unknown |  |
| invoice_amount | Unknown |  |
| invoice_date | Unknown |  |
| invoice_tax | Unknown |  |
| notes | Unknown |  |
| paid_amount | Unknown |  |
| payment_term_id | Unknown |  |
| payment_terms | Unknown |  |
| payments | Json |  |
| refunds | Json |  |
| shipping_contact_address_1 | Unknown |  |
| shipping_contact_address_2 | Unknown |  |
| shipping_contact_city | Unknown |  |
| shipping_contact_country | Unknown |  |
| shipping_contact_county | Unknown |  |
| shipping_contact_department | Unknown |  |
| shipping_contact_display_name | Unknown |  |
| shipping_contact_email | Unknown |  |
| shipping_contact_first_name | Unknown |  |
| shipping_contact_job_title | Unknown |  |
| shipping_contact_last_name | Unknown |  |
| shipping_contact_mobile | Unknown |  |
| shipping_contact_phone | Unknown |  |
| shipping_contact_state | Unknown |  |
| shipping_contact_zip | Unknown |  |
| start_date | Unknown |  |
| status | Unknown |  |
| subtotal | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Instant |  |

### usage_custom_field

| Column | Type | Keys |
| --- | --- | --- |
| name | Unknown | PK |
| usage_id | Unknown | PK, FK |
| value | Unknown |  |

### usage

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| charge_id | Unknown | FK |
| customer_id | Unknown | FK |
| subscription_id | Unknown | FK |
| subscription_line_id | Unknown | FK |
| created_by | Unknown |  |
| created_date | Unknown |  |
| currency | Unknown |  |
| date | Unknown |  |
| description | Unknown |  |
| error_message | Unknown |  |
| invoiced | Unknown |  |
| l_grouping_for_calculations | Unknown |  |
| quantity | Unknown |  |
| status | Unknown |  |
| unit_of_measure | Unknown |  |
| updated_by | Unknown |  |
| updated_date | Unknown |  |

### payments_method

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| customer_id | Unknown | FK |
| customer_payment_gateway_id | Unknown | FK |
| account_holder_name | Unknown |  |
| account_number | Unknown |  |
| country | Unknown |  |
| cvc | Unknown |  |
| defaults | Unknown |  |
| expiry | Unknown |  |
| payment_method_id | Unknown |  |
| payment_type | Unknown |  |
| status | Unknown |  |
| type | Unknown |  |
| url | Unknown |  |

### customer_note

| Column | Type | Keys |
| --- | --- | --- |
| id | Unknown | PK |
| customer_id | Unknown | FK |
| company_id | Unknown |  |
| created_at | Unknown |  |
| description | Unknown |  |
| file_upload_content_type | Unknown |  |
| file_upload_file_name | Unknown |  |
| file_upload_file_size | Unknown |  |
| file_upload_updated_at | Unknown |  |
| has_versions | Unknown |  |
| title | Unknown |  |
| updated_at | Unknown |  |
| user_id | Unknown |  |

## Relationships

- statement(customer_id) → customer(id)
- credit_line_item(product_id) → product(id)
- credit_line_item(credit_id) → credit(id)
- credit_subtotal(credit_id) → credit(id)
- credit_invoice(id) → invoice(id)
- credit_invoice(credit_id) → credit(id)
- credit_custom_field(credit_id) → credit(id)
- credit(customer_id) → customer(id)
- revenue_rule_custom_field(revenue_rule_id) → revenue_rule(id)
- plan_charge_transaction_posting_entries(plan_id) → plan_charge(plan_id)
- plan_charge_transaction_posting_entries(plan_charge_id) → plan_charge(id)
- plan_charge_tier(plan_id) → plan_charge(plan_id)
- plan_charge_tier(plan_charge_id) → plan_charge(id)
- plan_charge_custom_field(plan_id) → plan_charge(plan_id)
- plan_charge_custom_field(plan_charge_id) → plan_charge(id)
- plan_charge(product_id) → product(id)
- plan_charge(revenue_rule_id) → revenue_rule(id)
- plan_charge(plan_id) → plan(id)
- plan_custom_field(plan_id) → plan(id)
- product_transaction_posting_entry(product_id) → product(id)
- product_custom_field(product_id) → product(id)
- product(revenue_rule_id) → revenue_rule(id)
- orders_line_item_custom_field(orders_line_item_line_no) → orders_line_item(line_no)
- orders_line_item_custom_field(orders_line_item_orders_id) → orders_line_item(orders_id)
- orders_line_item(product_id) → product(id)
- orders_line_item(orders_id) → orders(id)
- orders_custom_field(orders_id) → orders(id)
- orders(invoice_id) → invoice(id)
- orders(customer_id) → customer(id)
- orders(coupon_code) → coupon(code)
- refund(credit_id) → credit(id)
- refund(payment_id) → payments(id)
- refund(invoice_id) → invoice(id)
- refund(customer_id) → customer(id)
- chart_of_account_custom_field(chart_of_account_code) → chart_of_account(code)
- subscription_plan_transaction_posting_entries(subscription_plan_id) → subscription_plan(id)
- subscription_plan_transaction_posting_entries(subscription_plan_index) → subscription_plan(index)
- subscription_plan_transaction_posting_entries(subscription_version) → subscription_plan(subscription_version)
- subscription_plan_transaction_posting_entries(subscription_id) → subscription_plan(subscription_id)
- subscription_plan_custom_field(subscription_plan_id) → subscription_plan(id)
- subscription_plan_custom_field(subscription_version) → subscription_plan(subscription_version)
- subscription_plan_custom_field(subscription_plan_index) → subscription_plan(index)
- subscription_plan_custom_field(subscription_id) → subscription_plan(subscription_id)
- subscription_plan(product_id) → product(id)
- subscription_plan(id) → plan(id)
- subscription_plan(revenue_schedule_id) → revenue_schedule(id)
- subscription_plan(charge_id) → plan_charge(id)
- subscription_plan(revenue_rule_id) → revenue_rule(id)
- subscription_plan(subscription_id) → subscription(id)
- subscription_plan(subscription_version) → subscription(version)
- subscription_custom_field(subscription_id) → subscription(id)
- subscription_custom_field(subscription_version) → subscription(version)
- subscription(customer_id) → customer(id)
- billing_schedule_line_custom_field(billing_schedule_line_id) → billing_schedule_line(id)
- billing_schedule_line(billing_schedule_id) → billing_schedule(id)
- billing_schedule_custom_field(billing_schedule_id) → billing_schedule(id)
- billing_schedule(product_id) → product(id)
- billing_schedule(subscription_id) → subscription(id)
- billing_schedule(customer_id) → customer(id)
- billing_schedule(charge_id) → plan_charge(id)
- revenue_schedule_line(revenue_schedule_id) → revenue_schedule(id)
- revenue_schedule(product_id) → product(id)
- revenue_schedule(plan_id) → plan(id)
- revenue_schedule(customer_id) → customer(id)
- revenue_schedule(charge_id) → plan_charge(id)
- customer_contact_custom_field(customer_contact_id) → customer_contact(id)
- customer_contact_custom_field(customer_contact_customer_id) → customer_contact(customer_id)
- customer_contact(customer_id) → customer(id)
- customer_custom_field(customer_id) → customer(id)
- payments_invoice(id) → invoice(id)
- payments_invoice(payments_id) → payments(id)
- payments_refund(id) → refund(id)
- payments_refund(payments_id) → payments(id)
- payments_custom_field(payments_id) → payments(id)
- payments(payment_run_id) → payments_run(id)
- payments(customer_id) → customer(id)
- journal_entry_custom_field(journal_entry_line_no) → journal_entry(line_no)
- journal_entry_custom_field(journal_entry_journal_id) → journal_entry(journal_id)
- journal_entry(customer_id) → customer(id)
- journal_entry(journal_id) → journal(id)
- invoice_line_item_tax_line(invoice_line_item_line_no) → invoice_line_item(line_no)
- invoice_line_item_custom_field(invoice_line_item_line_no) → invoice_line_item(line_no)
- invoice_line_item_custom_field(invoice_line_item_invoice_id) → invoice_line_item(invoice_id)
- invoice_line_item(product_id) → product(id)
- invoice_line_item(subscription_id) → subscription(id)
- invoice_line_item(subscription_line_id) → subscription_plan(subscription_line_id)
- invoice_line_item(plan_id) → plan(id)
- invoice_line_item(customer_id) → customer(id)
- invoice_line_item(charge_id) → plan_charge(id)
- invoice_line_item(invoice_id) → invoice(id)
- invoice_subtotal(invoice_id) → invoice(id)
- invoice_custom_field(invoice_id) → invoice(id)
- invoice(customer_id) → customer(id)
- usage_custom_field(usage_id) → usage(id)
- usage(subscription_id) → subscription(id)
- usage(subscription_line_id) → subscription_plan(subscription_line_id)
- usage(customer_id) → customer(id)
- usage(charge_id) → plan_charge(id)
- payments_method(customer_payment_gateway_id) → customer(payment_gateway_id)
- payments_method(customer_id) → customer(id)
- customer_note(customer_id) → customer(id)
