Onit Documentation

Reporting Database Objects

Updated on

This page is specific to database objects created in the warehouse when prepared for a client.

This content is intended for members of the reporting team and support and implementation teams. ​

bp_currencies materialized view

​Purpose

  • ​This materialized view is created to reduce the joins with the ebilling_ro.currencies foreign table.
  • The currencies data is cached in the warehouse schema using this materialized view.
  • ​This materialized view is refreshed daily during the nightly refresh process.

Query Joins

Data Dictionary

Foreign Table: ebilling_ro.currencies -> ebilling.currencies in the ebilling master database

Column Name

 
Data Type

 
Unique Key
 
Description
 
Source Field


 
uuid

 
uuid

 
Yes
 
Id of the currency
 
currencies.id
 
currency_code

 
character varying
 
 Currency Code
 
currencies.currency_code
 
currency_symbol
 
character varying Currency Symbol
 
currencies.currency_symbol

bp_accounts materialized view

Purpose

  • ​This materialized view is created to reduce the joins with the ebilling.accounts view that internally references a foreign table.
  • The warehouse's attributes for the client are cached in the warehouse schema using this materialized view. This view has only 1 row for the client.
  • ​This materialized view is refreshed daily during the nightly refresh process.

Query Joins

Data Dictionary

Column Name
 
Data Type
 
Unique KeyDescriptionSource Field
iduuid?Yes
 
Id of the client accountaccounts.id
suppress_diversity_infoboolean
 
Specifies whether to supress diversity informationaccounts.suppress_diversity_info
currency_iduuid
 
Id of the client currencycurrencies.id
client_base_currency_codecurrcharacter varying
 
Client currency codecurrencies.currency_code
client_base_currency_symbolcharacter varying Client currency symbolcurrencies.currency_symbol

bp_users materialized view

Purpose

  • This materialized view stores the IDs and names of all the users who made invoice line item adjustments. 
  • The details of the users who performed the adjustments are cached in the warehouse schema using this materialized view.
  • ​This materialized view is refreshed daily during the nightly refresh process.

Query Joins

Data Dictionary

Column Name
 
Data Type
 
Unique KeyDescriptionSource field
iduuidYesId of the userusers.id
user_namecharacter varying Name of the userusers.name

bp_staff_classifications materialized view

Purpose

  • This materialized view stores the union of staff classifications from ebilling master and the client's private staff classifications. 
  • The staff classifications are cached in the warehouse schema using this materialized view. 
  • ​This materialized view is refreshed daily as part of the nightly refresh process.​

Query Joins

Data Dictionary

bp_projects view

Purpose

  • This view contains the fields used in the warehouse from ebilling.client_projects. 
  • This view is just a wrapper on the ebilling.client_projects table from the client's private database.​

Query Joins

Data Dictionary

Column Name
 
Data Type
 
Unique KeyDescriptionSource Field
iduuidYes
 
psb_client_project id, ID of the record, primary keyclient_projects.id
account_idcharacter varying id of the vendor in Counsel Exchangeclient_projects.account_id
client_idcharacter varying id of the client vendor associationclient_projects.client_id
client_account_iduuid id of the client account in Counsel Exchange?client_projects.client_account_id
namecharacter varying Client project nameclient_projects.name
numbercharacter varying
 
client project numberclient_projects.number
created_attimestamp without time zone date on which record got created in Counsel Exchangeclient_projects.created_at
updated_attimestamp without time zone
 
date on which record got updated last time in Counsel Exchangeclient_projects.updated_at
remote_keycharacter varying
 
id of VATM record in AppBuilderclient_projects.remote_key
typecharacter varying type of client projectclient.projects.type

bp_billing_authorization_requests view

Purpose

  • This view stores the fields used in the warehouse from the ebilling.billing_authorization_requests table. 
  • This view is just a wrapper on the ebilling.client_projects table from the client's private database.​

Query Joins

Data Dictionary

bp_invoices view

Purpose

  • This view stores the fields used in the warehouse from the ebilling.invoices table. 
  • This view is just a wrapper on the ebilling.invoices table from the client's private database.​

Query Joins

Data Dictionary

Column NameData TypeUnique KeyDescription Source Field
iduuidYesInvoice id, IF of the record, primary keyinvoices.id
Client_iduuid Id of the clientinvoices.client_id
payment_terms_iduuid Id of the payment terminvoices.payments_terms_id
Office_iduuid Id of officeinvoices.office_id
Account_iduuid Id of the vendor accountinvoices.account_id
Billing_authorization_iduuid Id of BARinvoices.billing_authorization_id
Currency_iduuid Id of the invoice currencyinvoices.currency_id
Client_account_iduuid Id of the client accountInvoices.client_account_id
Project_iduuid Id of the client projectInvoices.client_project_id
Client_supported_currency_iduuid Client supported currency id for the BARinvoices.client_supported_currency_id
Account_supported_currency_iduuid Vendor supported currency id for the BARinvoices.account_supported_currency_id
Client_project_bar_iduuid BAR id of the client projectInvoices.client_project_bar_id
Invoice_numbercharacter varying Vendor invoice numberinvoices.invoice_number
Invoice_datetimestamp without time zone Invoice dateInvoices.invoice_date
Po_numbercharacter varying Client PO # from vendor BARInvoices.po_number
Discount_percentageNumeric (20,6) Invoice discount in percentageinvoices.discount_percentage
Termstext Terms of invoiceinvoices.terms
Notestext Invoices description in LEDESinvoices.notes
Sub_totalNumeric (20,6) Invoice sub totalinvoices.sub_total
discountNumeric (20,6) Invoice discountinvoices.discount
Tax_amountNumeric (20,6) Invoice tax amountinvoices.tax_amount
Invoice_totalNumeric (20,6) Invoice total in submitted currencyinvoices.invoice_total
Archive_numbercharacter varying Archive number if this Record is archivesinvoices.archive_number
Archives_atTimestamp w/o time zone Date on which invoice was archived in Counsel Exchangeinvoices.archived_at
Deleted_atTimestamp w/o time zone Date on which invoice was marked for soft deleteInvoices.deleted_at
created_atTimestamp w/o time zone Date on which invoice got created in Counsel Exchangeinvoices.created_at
Updated_atTimestamp w/o timezone Date on which the invoice got updated in Counsel ExchangeInvoices.updated_at
Due_datedate Due date of invoiceinvoices.due_date
Last_invoice_statusCharacter varying Last status of invoiceinvoices.last_invoice_status
Discount_typecharacter varying Type of invoice discount - Fee, Expenseinvoices.discount_type
Billing_start_dateTimestamp w/o time zone Billing start dateInvoices.billing_start_date
Billing_end_dateTimestamp w/o time zone Billing end dateinvoices.billing_end_date
statecharacter varying Invoice BP phase (Failed, Pending Approval, Approved, Disputed, Voided, Paid, Draft)invoices.state
Invoice_feesnumeric (20,6) Fees total in submitted currencyInvoices.invoice_fees
Invoice_expensesNumeric (20,6) Expenses in total submitted currencyinvoices.invoice_expenses
resubmittedBoolean DEFAULT false True if invoice was resubmittedinvoices.resubmitted
remote_keycharacter varying AB Invoice atom IDInvoices.remote_key
Invoice_orig_amountNumeric (20,6) Invoice total on first time submission in submitted currencyinvoices.invoice_orig_amount
Client_spot_rateNumeric (20,) Spot rate of client on invoiceInvoices.client_spot_rate
Account_spot_rateNumeric (20,6) Spot rate of vendor on invoiceInvoices.client_spot_rate
Received_dateTimestamp w/o time zone Date invoice first went to phase = Pending ApprovalInvoice.received_date
Invoice_orig_feesNumeric (20,6) Invoice total fees on first time submission in submitted currencyinvoices.invoice_orig_fees
Invoice_orig_discountNumeric (20,6) Invoice total expenses on first time submission in submitted currencyInvoices.invoice_orig_expenses
Invoice_orig_discountNumeric (20,6) Invoice total discount on first time submission in submitted currencyinvoices.invoice_orig_discount
Submission_typeCharacter varying Is this LEDES 98b, 98bi, xml, via UI? {LEDES | Manual} Currently, its “LEDES” for all LEDES formats and “Manual” for manually created invoicesInvoices.submission_type
Header_short_pay_adjustNumeric (20,6) Not in useInvoices.header_short_pay_adjustment
Line_item_short_pay_adjustmentNumeric (20,6) Not in useinvoices.line_item_short_pay_adjustment
Short_pay_adjustment_totalNumeric (20,6) Not in useinvoices.short_pay_adjustment_total
Pay_totalNumeric (20,6) Its invoice_total - short_pay_total. Since short pay may not be in use, so it’s most likley qual to invoice_totalinvoices.pay_total
Approved_dateTimestampe w/o time zone Date invoice approval is completed bu all client approvers in Onit and invoices is readuy for payment processinginvoices.approved_date
Edited_since_discputedBoolean DEFAULT false Billing authorization requests edited since disputedInvoices.edited_sinces_disputed
ap_detailstext Legacy data. THis waas used by AppBuilder to populate Legal Entity info. Replaced by current Legal Entity processInvoices.ap_details
Orig_fee_discountNumeric (20,6) Fee discount in submitted currencyInvoices.fee_discount
Fee_discountNumeric (20,6) Expense discount in submitted currencyinvoices.expense_discount
Header_dispute_adjustmentNumeric (20,6)  invoices.header_dispute_adjustment
fee_line_item_dispute_adjustmentNumeric (20,6) Fee line item discpute adjustment in submitted currencyinvoices.fee_line_item_dispute_adjustment
Expense_line_item_dispute_adjustmentNumeric (20,6) Expense line item dispute adjustment in submitted currencyinvoices.expense_line_item_dispute_adjustment
Dispute_adjustment_totalNumeric (20,6) Total invoice adjustments in submitted currnecyinvoices.dispute_adjustment_total
Adjustments_enabledBoolean DEAULT true True if adjustments are enabled, otherwise falseinvoice.adjustment_enabled
Fee_header_dispute_adjustmentNumeric (20,6) Total header fee adjustments in submitted currencyInvoices.fee_header_dispute_adjustment
Expense_header_dispute_adjustmentNumeric (20,6) Total header expense adjustments in submitted currencyinvoices.expense_header_dispute_adjustment
Vat_processingBoolean DEFAULT false  invoices.vat_processing

bp_invoice_line_items view

Purpose

  • This view stores the fields used in the warehouse from the ebilling.invoice_line_items table
  • This view is just a wrapper on the ebilling.invoice_line_items table from the client's private database

Query Joins

Data Dictionary

Column NameData TypeUnique KeyDescriptionSource Field
IduuidYesInvoice line item id, ID of the record, primary keyInvoice_line_items.id
Invoice_iduuid Id of the invoiceInvoice_line_items.invoice_id
Account_iduuid Id of the vendorInvoice_line_items.account_id
Project_iduuid Id of the client projectInvoice_line_items.project_id
Time_keeper_iduuid Id of the timekeeperInvoice_line_items.time_keeper_id
Time_keeper_rate_iduuid Id of the time keeper rateInvoice_line_items.time_keeper_rate_id
Client_account_iduuid Id of the client accountInvoice_line_items.client_account_id
parent_iduuid Id of the parent line itemInvoice_line_items.parent_id
Adjuster_iduuid Id of the adjuster userInvoice_line_items.adjuster_id
Item_descriptiontext Description of the line itemInvoice_line_items.item_description
Item_unit_costNumeric (20,6) Unit cost of the line itemInvoice_line_items.item_unit_cost
Itme_quantityNumeric (20,6) Unit quantity of the line itemInvoice_line_items.item_quantity
archive_numberCharacter varying Archive number of the line itemInvoice_line_items.archive_number
Archived_atTimestamp w/o time zone Date on which line item got archived in Counsel ExchangeInvoice_line_items.archived_at
Deleted_atTimestamp w/o time zone Date on which line item got deleted in Counsel ExchangeInvoice_line_items.deleted_at
Created_atTimestamp w/o time zone Date on which line item got created in Counsel ExchangeInvoice_line_items.created_at
Updated_atTimestamp w/o time zone Date on which line item got updated in Counsel ExchangeInvoice_line_items.updated_at
Line_item_totalNumeric (20,6) Line item total in vendor base currencyInvoice_line_items.line_item_total
discountNumeric (20,6) DiscountInvoice_line_items.discount
Timekeeper_rateNumeric (20,6) Timekeeper rateInvoice_line_items.timekeeper_rate
Activity_datedate Line item activity dateInvoice_line_items.activity_date
Invoice_line_item_typeCharacter varying Type of the invoice line itemInvoice_line_items.line_item_type
Parent_typeCharacter varying Parent of the line item, it may be a line item or invoiceInvoice_line_items.parent_type
Adjustment_unitNumeric (20,6) No longer usedInvoice_line_items.adjustment_unit
Adjustment_costNumeric (20,6) No longer usedInvoice_line_items.adjustment_cost
Adjustment_totalNumeric (20,6) No longer used Invoice_line_items.adjustment_total
System_CreatedBoolean DEFAULT false True if this is system createdInvoice_line_items.system_created
Dispute_adjustment_typeCharacter varying Type of adjustment e.g. set_amount_to, reduce_by_pct, reduce_by_amount, set_rate_to, set_net_toInvoice_line_items.dispute_adjustment_type
adjustment_valueNumeric (20,6) Value by an line item is adjusted, it may be hours, rate, percentage, or netInvoice_line_items.adjustment_value
Inactive Boolean DEFAULT false True, if item is inactiveInvoice_line_items.inactive
Task_codeCharacter varying Task codeInvoice_line_items.task_code
Task_descriptioncharacter varying Description for the task codeTask_codes.description
Expense_codeCharacter varying Expense codeInvoice_line_items.expense_code
Expense_descriptionCharacter varying Description for expense codeExpense_codes.description
Activity_codeCharacter varying Activity code Invoice_line_items.activity_code
Activity_descriptionCharacter varying Description of activity codeActivity_codes.description
Adjustment_codeCharacter varying Adjustment codeInvoice_line_items.adjustment_code
Adjustment_descriptionCharacter varying Description for adjustment codeAdjustment_codes.description
Tax_codeCharacter varying Tax codeInvoice_line_items.tax_code
Tax_descriptionCharacter varying Description for the tax codeTax_codes.description 
Discount_codeCharacter varying Discount codeInvoice_line_items.discount_code
Discount_descriptionCharacter varying Description of discount codeDiscount_codes.description
Adjuster_nameCharacter varying Name of user who made the adjustmentsbp_users.user_name
Optional_tax_rateNumeric (20,6)  Invoice_line_items.optional_tax_rate
Staff_classification_iduuid Id of the staff classificationInvoice_line_items.staff_classification_id
Staff_classification_descriptionCharacter varying​​ Description of the staff classificationInvoice_line_items.staff_classification_description

bp_timekeepers materialized view

Purpose

  • This materialized view stores the data related to the client's timekeepers
  • The timekeepers are cached in the warehouse schema using this materialized view. This reduces the number of joins with foreign tables from cube-related views.
  • The materialized view is refreshed daily as part of the nightly refresh process.

Query Joins

Data Dictionary

Column NameData Type Unique KeyDescriptionSource Field
Client_time_keeper_iduuidYesClient timekeepr id, ID of the record, primary keyClient_timekeepers.id
Time_keeper_iduuid Id of the time keeperClient_timekeepers.time_keeper_id
Account_iduuid Id of the vendorClient_timekeepers.account_id
Client_account_iduuid Id of the client accountClient_timekeeprs.client_account_id
Pending_rateNumeric (20,6) Rate pending for approval on this timekeeperClient_timekeepers.pending_rate
Approved_rateNumeric (20,6) Rate approved for this timekeeperClient_timekeepers.approved_rate
Currency_iduuid Currency Id of the time keeper rateClient_timekeepers.currency_id
Employee_iduuid Employee Id of the time keeperTime_keepers.employee_id
Full_nameCharacter varying  Full name of the time keeperTime_keepers.full_name
InitialsCharacter varying Initials of the time keeperTime_keepers.initials
EmailCharacter varying Email id of the time keeperTime_keepers.email
LawyerBoolean True, if timekeeper is a lawyer, otherwise falseTime_keepers.lawyer
PhoneCharacter varying Phone number of the time keeperTime_keepers.phone
First_practicedBigint Year time keeper first practicesTime_keepers.first_practiced
UrlCharacter varying URL of the time keeper profileTime_keepers.url
GenderChracter varying Gender of the time keeperTime_keepers.gender
EthnicityCharacter varying Ethnicity of the time keeperTime_keepers.ethnicity
Other_ethnicityCharacter varying Other ethnicity of the time keeperTime_keepers.other_ethnicity
Date_bar_passedBigint Date of BAR passesTime_keepers.date_bar_passed
Default_rate_effective_dateTimestamp w/o time zone Effective date for the default rateTime_keepers.default_rate_effictive_date
Default_rateNumeric (20,6) Default rate of the time keeperTime_keepers.default_rate
Office_iduuid Id of the time keeper office recordTime_keepers.office_id
Office_nameCharacter varying Office name of the time keeperOffices.office_name
CountryCharacter varying Country of the time keeperoffices.country
CityCharacter varying  City of the timekeeperOffices.city
Street_address_1Character varying Address line 1 of the time keeperoffices.street_address_1
Street_address_2Character varying Address line 2 of the time keeperOffices.street_address_2
Province_or_stateCharacter varying Province or state of time keeperoffices.province_or_state
Postal_or_zipcodeCharacter varying Postal or zip code of time keeperOffices.postal_or_zipcode
Currency_codeCharacter varying Currency code for the time keeper rate currencyBp_currencies.currency_code
Currency_symbolCharacter varying Currency symbol for the time keeper rate currencyBp_currencies.currency_symbol
Staff_class_descriptionCharacter varying Staff classification of the time keeperbp_staff_classifications.description
Staff_class_codeCharacter varying  Staff classificatino code of the time keeperbp_staff_classifications.code
RateNumeric (20,6) Rate for the staff classificationbp_staff_classifications.rate
bp_tk_derived_pending_rateNumeric (20,6) Last updated rate from client timekeeper rates from Counsel Exchange where state is pending or pending_approval or resubmit or unapproveclient_timekeeper_rates.rate. Derived using the function bp_get_tk_pending_rate since the existing pending_rate field is no more used in Counsel Exchange

bp_timekeeper_rate view

Purpose

  • This view stores contains the fields that are used in the warehouse from the ebilling.client_timekeeper_rates table.
  • This view is just a wrapper on the ebilling.client_timekeepr_rates table from the client's private database

Query Joins

Data Dictionary

Column NameData TypeUnique KeyDescriptionSource Field
iduuidYesClient timekeeper id, Id of record, primary keyClient_timekeeper_rates.id
Staff_classification_iduuidq Id of the staff classification for the time keeperClient_timekeeper_rates.staff_classification_id
Client_timekeeper_id  Id of the client time keeper recordClient_timekeeper_rates.client_timekeeper_id
Account_iduuid Id of the vendor account Client_timekeeper_rates.account_id
Effective_dateTimestamp w/o time zone Effective date for the time keeper rateClient_timekeeper_rates.effective_date
rateNumeric (20,6) Rate of the time keeperClient_timekeeper_rates.rate
StateCharacter varying State of the client timekeeper rate - pending, pending_approval, resubmit, unapprove, draft, sending, disputed, voided, edited_since_disputedClient_timekeeper_rates.state
Rate_increase_reasonText Reason for the rate increaseClient_timekeeper_rates.rate_increase_reason
Remote_keyCharacter varying Id of the timekeeper in Onit AppBuilderClient_timekeeper_rates.remote_key
Currency_iduuid Id of the currencyClient_timekeeper_rates.currency_id
Currency_codeCharacter varying Currency code for the timekeeper ratebp_currencies.currency_code
Currency_symbolCharater varying Currency symbol for the timekeeper rateBp_currencies.currency_symbol
Time_keeper_iduuid Id of the timekeeper recordClient_timekeeper_rates.time_keeper_id

bp_timekeeper_rate_histories materialized view

Purpose

  • This materialized view stores the timekeeper rate histories from the ebilling master. 
  • The timekeeper rate histories are cached in the warehouse schema using this materialized view. This reduces the number of joins with foreign tables from cube-related views. 
  • ​This materialized view is refreshed daily during the nightly refresh process.​

Query Joins

Data Dictionary

Column NameData TypeUnique KeyDescriptionSource Field
Tkr_iduuidYesClient timekeepr rate history id, Id of the record, primary keyTimekeepr_rate_histories.id
Time_keeper_iduuid Time keeper idTimekeepr_rate_histories.time_keeper_id
Tkr_rateNumeric (20,6) Rate for the time keeperTimekeepr_rate_histories.rate
Tkr_effective_start_dateTimestamp w/o time zone Effective start date for the rateTimekeepr_rate_histories.effective_start_date
Tkr_effective_end_dateTimestamp w/o time zone Effective end date for the rateTimekeepr_rate_histories.effective_end_date
Tk_employee_idCharacter varying Employee id of the time keeperTime_keepers.employee_id
Tk_staff_classification_descriptionCharacter varying Staff classification for the time keeperBp_staff_classifications.description
Tkr_currency_rateCharacter varying Currency code for the rateBp_currencies.currency_code
Tkr_currency_sybmolCharacter varying Currency symbol for the rateBp_currencies.currency_symbol

bp_invoice_validations view

Purpose

  • This view stores the fields used in the warehouse from the ebilling.invoice_validations table. 
  • This view is just a wrapper on the ebilling.invoice_validations table from the client's private database.​​

Query Joins

Data Dictionary

Column NameData TypeUnique KeyDescriptionSource Field
iduuidYesInvoice validation, ID of the record, primary keyInvoice_validations.id
Invoice_iduuid Id of the invoice recordInvoice_validations.invoice_id
Context_typeCharacter varying Context type can be Fee, Expense, HeaderTax, FeeDiscount, ExpenseDiscount, LineItemTaxInvoice_validations.context_type
Context_iduuid Line item Id for line item level validation messages

Invoice id for invoice level validation messages
Invoice_validations.context_id
Message_severityCharacter varying Message severity can be ERROR, WARNINGInvoice_validations.message_severity
MessageText Validation messageInvoice_validations.message
Created_atTimestamp w/o time zone Date on which invoice got created in Counsel ExchangeInvoice_validations.created_at
Updated_atTimestamp w/o time zone Date on which invoice got updated in Counsel ExchangeInvoice_validations.updated_at
Rule_typeCharacter varying Name of the ruleInvoice_validations.rule_type
Invoice_numberCharacter varying Vendor invoice numberInvoices.invoice_number

manual_invoice_line_item_cube materialized view

Purpose

  • This materialized view transforms the manual invoices into line items. One manual invoice will be transformed into one or more line item rows based on whether manual fields (fees, fees discount, expenses, expenses_discount, taxes) 
  • The transformed manual invoice line items are cached in the warehouse schema using this materialized view. 
  • ​This materialized view is refreshed daily during the nightly refresh process.​

Query Joins

Data Dictionary

Column NameData TypeUnique KeyDescriptionSource Field
Client_project_numberuuidYesInvoice validation id, ID of the record, primary keyinvoices.matter_number
Account_iduuid Pub_vendor_id from the vendors appVendors.psb_vendor_id
Vendor_end_dateTimestamp w/o time zone Ended at date of the atom from the vendor appvendors.ended_at
Vendor_iduuid Id of the atom in the vendor appvendors.id
Vendor_start_dateTimestamp w/o time zone Created date of the atom from the vendor appVendors.created_at
Vendor_stateCharacter varying State of the atom in the vendor appvendors.state
Vendor_currency_codeCharacter varying One of the below fields dependeing on the type of manual invoice line item:

Currency code of manual fees
OR
Currency code of manual fee discount
OR
Currency code of manual expenses
OR
Currency code of manual expense discount
OR
Currency code of manual taxes
Invoices.manual_fees_c
OR
invoices.manual_fees_discount_c
OR
Invoices.manual_expenses_c
OR
Invoices.manual_expense_discount_c
OR
Invoices.manual_taxes_c
Inv_curr_state_nameCharacter varying Phase of the atom from the invoice appInvoices.curr_state_name
Inv_invoice_fees_submittedNumeric (20,6) Manual_fees field value from invoices appInvoices.manual_fees
Inv_invoice_fees_baseNumeric (20,6) Invoice_fees field value from invoices appInvoices.invoice_fees
Inv_invoice_orig_fees_submittedNumeric (20,6) Manual_fees field from invoice appInvoices.manual_fees
Inv_invoice_orig_fees_baseNumeric (20,6) Invoice_fees field value from invoices appInvoices.invoice_fees
Inv_fee_discount_submittedNumeric (20,6) Manual_fees_discount field from invoices appInvoices.manual_fees_discount
Inv_fee_discount_baseNumeric (20,6) (manual_fees_discount field value from invoices app) x (derived spot rate)Invoices.manual_fees_discount  x derived spot rate
Inv_orig_fee_discount_submittedNumeric (20,6) (manual_fees_discount field value) + (manual_expenses_discount field value) from invoices appInvoices.manual_fees_discount
Inv_orig_fee_discount_baseNumeric (20,6) Discount_amount field from invoices appInvoices.manual_fees_discount x derived spot rate
Inv_invoice_orig_discount_submittedNumeric (20,6) (Manual_fees_discount fieldvalue from invoices app) x (derived spot rate)Invoices.manual_fees_discount + invoices.manual_expenses_discount
Inv_invoice_orig_discount_baseNumeric (20,6) Discount_amount field value from invoices appInvoices.discount_amount
Inv_invoice_expenses_submittedNumeric (20,6) Manual_expenses field from invoices appInvoices.manual_expenses
Inv_invoice_expenses_baseNumeric (20,6) Invoice_expenses field value from invoices appInvoices.invoice_expenses
Inv_invoice_orig_expenses_submittedNumeric (20,6) Manual_expenses field value from invoices appInvoices.manual_expenses
Inv_invoices_orig_expenses_baseNumeric (20,6) invoice_expenses field from invoice appInvoices.invoice_expenses
Inv_expense_discount_submittedNumeric (20,6) Manual_expenses field from invoices appInvoices.manual_expense_discount
Inv_expense_discount_baseNumeric (20,6) (Manual_expenses_discount field from the invoices app) x (derived spot rate)Invoices.manual_expenses_discount x derived spot rate
Inv_orig_expense_discount_submittedNumeric (20,6) Manual_expenses_dsicount field from invoice appInvoice.manual_expense_discount
Inv_orig_expense_discount_baseNumeric (20,6) (Manual_expenses_discount field value from the invoices app) x (derived spot rate)Invoices.manual_expenses_discount x derived spot rate
Inv_orig_manual_taxes_submittedNumeric (20,6) Manual_taxes field value from invoices appInvoices.manual_taxes
Inv_orig_manual_taxes_baseNumeric (20,6) (Manual_taxes field value from the invoices app) x (derived spot rate)Invoices.manual_taxes x derived spot rate
Inv_invoice_orig_amount_submittedNumeric (20,6) (manual_fees field value)
+
(manual_fees_discount field value)
+
(manual_expenses field value)
+ (manual_expenses_discount field value)
+
(manual_taxes field value) from the Invoices app
invoices.manual_fees
+
invoices.manual_fees_discount
+
invoices.manual_expenses
+ invoices.manual_expenses_discount +
invoices.manual_taxes
Inv_invoice_orig_amount_baseNumeric (20,6) Invoice_orig_amount field value from invoices appInvoices.invoice_orig_amount
Inv_invoice_total_submittedNumeric (20,6) (manual_fees field value)
+
(manual_fees_discount field value)
+
(manual_expenses field value)
+ (manual_expenses_discount field value)
+
(manual_taxes field value) from the Invoices app
invoices.manual_fees
+
invoices.manual_fees_discount
+
invoices.manual_expenses
+
invoices.manual_expenses_discount +
invoices.manual_taxes
Inv_invoice_total_baseNumeric (20,6) Invoice total in base currency. Invoice_total field value from invoices appInvoices.invoice_total
Inv_pay_total_submittedNumeric (20,6) Its invoice_total - short_pay_total. Since short_pay may not be in use (need to confirm) so it's most likely equals to invoice_totalInvoices.payment_amount
Inv_pay_total_baseNumeric (20,6) Same as above but in base currencyInvoices.invoice_total
Inv_billing_end_dateTimestamp w/o time zone billing_end_date field value from invoice appInvoices.billing_end_date
Inv_billing_start_dateTimestamp w/o time zone Billing_start_date field value from invoices appInvoices.billing_start_date
Inv_invoice_dateTimestamp w/o time zone Invoice_date field value from invoices fieldInvoices.invoice_date
Inv_invoice_numberCharacter varying Value of the name field from invoices appinvoices.name
Inv_notesCharacter varying Value of notes field from invoices appinvoices.notes
Inv_received_dateTimestamp w/o time zone Value of the created_at field from invoices appinvoices.created_at
Li_item_unit_costNumeric (20,6) One of the below fields depending on the type of manual invoice line item

manual_fees, when manual_fees is not equal 0

manual_fees_discount, when manual_fees_discount is not equal 0

manual_expenses, when manual_expenses is not equal 0

manual_expenses_discount, when manual_expenses_discount is not equal 0

manual_taxes, when manual_taxes is not equal 0
invoices.manual_fees, when manual_fees is not equal 0

invoices.manual_fees_discount, when manual_fees_discount is not equal 0

invoices.manual_expenses, when manual_expenses is not equal 0

invoices.manual_expenses_discount, when manual_expenses_discount is not equal 0

invoices.manual_taxes, when manual_taxes is not equal 0
Li_line_item_total_submittedNumeric (20,6) One of the below fields depending on the type of manual invoice line item

manual_fees, when manual_fees is not equal 0

manual_fees_discount, when manual_fees_discount is not equal 0

manual_expenses, when manual_expenses is not equal 0

manual_expenses_discount, when manual_expenses_discount is not equal 0

manual_taxes, when manual_taxes is not equal 0
invoices.manual_fees, when manual_fees is not equal 0

invoices.manual_fees_discount, when manual_fees_discount is not equal 0

invoices.manual_expenses, when manual_expenses is not equal 0

invoices.manual_expenses_discount, when manual_expenses_discount is not equal 0

invoices.manual_taxes, when manual_taxes is not equal 0
Li_line_item_total_baseNumeric (20,6) One of the below fields depending on the type of manual invoice line item

manual_fees x (derived spot rate), when manual_fees is not equal 0

manual_fees_discount x (derived spot rate), when manual_fees_discount is not equal 0

manual_expenses x (derived spot rate), when manual_expenses is not equal 0

manual_expenses_discount x (derived spot rate), when manual_expenses_discount is not equal 0

manual_taxes x (derived spot rate), when manual_taxes is not equal 0
invoices.manual_fees x (derived spot rate), when manual_fees is not equal 0

invoices.manual_fees_discount x (derived spot rate), when manual_fees_discount is not equal 0

invoices.manual_expenses x (derived spot rate), when manual_expenses is not equal 0

invoices.manual_expenses_discount x (derived spot rate), when manual_expenses_discount is not equal 0

invoices.manual_taxes x (derived spot rate), when manual_taxes is not equal 0
Li_idCharacter varying Time UUID created for each line item rowMd5(random()::text || clock_timestamp()::text)
Inv_iduuid _id of the atom from the invoices appInvoices._id
Inv_remote_keyuuid _id of the atom from the invoices appinvoices._id
Li_activity_dateTimestamp w/o time zone Invoice_date field from the invoices appInvoices.invoice_date
Line_item_typeCharacter varying  Type of the manual line item. This field is derived.

'Fee' when manual_fees in Invoices app is not equal to 0

'FeeDiscount' when manual_fees_discount in Invoices app is not equal to 0

'Expense' when manual_expenses in Invoices app is not equal to 0

'ExpenseDiscount' when manual_expenses_discount in Invoices app is not equal to 0

'HeaderTax' when manual_taxes in Invoices app is not equal to 0
Type of the manual line item. This field is derived.

'Fee' when invoices.manual_fees in Invoices app is not equal to 0

'FeeDiscount' when invoices.manual_fees_discount in Invoices app is not equal to 0

'Expense' when invoices.manual_expenses in Invoices app is not equal to 0

'ExpenseDiscount' when invoices.manual_expenses_discount in Invoices app is not equal to 0

'HeaderTax' when invoices.manual_taxes in Invoices app is not equal to 0

invoices_line_item_cube materialized view

Purpose

  • This materialized view stores the union of line items from Counsel Exchange and the line items transformed for manual invoices from AppBuilder. 
  • The invoice line items are cached in the warehouse schema using this materialized view. 
  • ​This materialized view is refreshed daily during the nightly refresh process.​

Query Joins

Data Dictionary

Column NameData TypeUnique KeyDescriptionSource Field
Client_project_numberCharacter varyingYesInvoice validation id, ID of the record, primary keyBp_projects.number
Account_idCharacter varying Psb_vendor_id from the vendor appbp_invoices.account_id
Client_account_idCharacter varying Client account id of the invoiceBp_invoices.client_account_id
Vendor_end_dateTimestamp w/o time zone BAR end dateBp_billing_authorization_requests.end_date
Vendor_idText BAR idbp_billing_authorization_requests.id
Vendor_fee_arrangement_nameCharacter varying Fee arrangement name on BARBp_billing_authorization_requests.fee_arrangement_name
Vendor_modification_reasonText Reason for which vendor asked modification on BARBp_billing_authorization_requests.modification_reason
Vendor_purchase_order_numberCharacter varying Purchase order number from BAR recordBp_billing_authorization_requests.purchase_order_number
Vendor_start_dateTimestamp w/o time zone Start date of the BARBp_billing_authorization_requests.start_date
Vendor_stateCharacter varying State of BARBp_billing_authorization_requests.state
Vendor_budget_amount_submittedNumeric (20,6) Budget amount in submitted currencyBp_billing_authorization_requests.budget_amount
Vendors_budget_amount_baseNumeric (20,6) Budget amount in client base currencyBp_billing_authorization_requests.client_spot_rate x Bp_billing_authorization_requests.budget_amount
Vendor_client_spot_rateNumeric (20,6) Spot rate of vendor on invoiceBp_billing_authorization_requests.client_spot_rate
Vendor_currency_codeCharacter varying Currency code for the spot rate of vendor of invoiceBp_billing_authorization_requests.currency_code
Vendor_currency_symbolCharacter varying Currency symbol for the spot rate of vendor of invoiceBp_billing_authorization_requests.currency_symbol
Vendor_edited_since_disputedBigint 1 if BAR is edited since disputed, 0 otherwiseBp_billing_authorization_requests.edited_since_disputed
Inv_idCharacter varying  BP invoice IDBp_invoices.id
Inv_adjustments_enabledBigint 1 if adjustments are enabled, 0 otherwiseBp_invoices.adjustments_enabled
Inv_ap_detailsText Legacy data. This was used by AppBuilder to populate Legal Entity info. The was replaced by current Legal Entity processBp_invoices.ap_details
Inv_approved_dateTimestamp w/o time zone Date invoice approval is completed by all client approvers in Onit and invoices is ready for payment processing.Bp_invoices.approved_date
Inv_billing_end_dateTimestamp w/o time zone Billing end dateBp_invoices.billing_end_date
Inv_billing_start_dateTimestamp w/o time zone Billing start dateBp_invoices.billing_start_date
Inv_client_spot_rateNumeric (20,6) Client spot rate sotred on invoice recordBp_invoices.client_spot_rate
Inv_invoice_dateTimestamp w/o time zone Invoice dateBp_invoices.invoice_date
Inv_invoice_numberCharacter varying Vendor invoice numberBp_invoices.invoice_number
Inv_notesText Invoice_description in LEDESBp_invoices.notes
Inv_po_numberCharacter varying Clinet PO # from vendor BARBp_invoices.po_number
Inv_received_dateTimestamp w/o time zone Date invoice first went to phase = Pending ApprovalBp_invoices.received_date
Inv_resubmittedBigint 1 if invoice resubmitted, 0 otherwiseBp_invoices.resubmitted
Inv_stateCharacter varying Invoice BP phase (Failed, Pending Approval, Approved, Disputed, Voided, Paid, Draft)Bp_invoices.state
Inv_submission_typeCharacter varying Submission_type e.g., Manual, LEDESBp_invoices.submission_type
Inv_dispute_adjustment_total_submittedNumeric (20,6) Total invoice adjustments in vendor base currencyBp_invoices.dispute_adjustment_total
Inv_dispute_adjustment_total_baseNumeric (20,6) Invoice adjustments total in submitted currencyBp_billing_authorization_requests.client_spot_rate x bp_invoices.expense_discount
Inv_expense_discount_submittedNumeric (20,6) Total expense discount in submitted currencyBp_invoices.expense_discount
Inv_expense_discount_baseNumeric (20,6) Total expense discount in base currencyBp_billing_authorization_requests.client_spot_rate x bp_invoices.expense_discount
Inv_expense_header_dispute_adjustment_submittedNumeric (20,6) Total header expense adjustments in submitted currencyBp_invoices.expense_header_dispute_adjustment
Inv_expense_header_dispute_adjustment_baseNumeric (20,6) Total header expense adjustments in base currencyBp_billing_authorization_requests.client_spot_rate x bp_invoices.expense_header_dispute_adjustment
Inv_expense_line_item_dispute_adjustment_submittedNumeric (20,6) Total line item expense adjustments in submitted currencyBp_invoices.expense_line_item_dispute_adjustment
Inv_expense_line_item_dispute_adjustment_baseNumeric (20,6) Total line item expense adjustments in base currency Bp_billing_authorization_requests.client_spot_rate x bp_invoices.expense_line_item_dispute_adjustment
Inv_fee_discount_submittedNumeric (20,6) Total fee discount (header and line item) in submitted currencybp_invoices.fee_discount
Inv_fee_discount_baseNumeric (20,6) Total fee discount (header and line item) in base currencyBp_billing_authorization_requests.client_spot_rate x bp_invoices.fee_discount
Inv_fee_header_dispute_adjustment_submittedNumeric (20,6) Fee header adjustments total in submitted currencyBp_invoices.fee_header_dispute_adjustment
Inv_fee_header_dispute_adjustment_baseNumeric (20,6) Fee header adjustments in total base currencyBp_billing_authorization_requests.client_spot_rate x bp_invoice.fee_header_dispute_adjustment
Inv_fee_line_item_dispute_adjustment_submittedNumeric (20,6) Fee line item adjustments total in submitted currencyBp_invoices.fee_line_item_dispute_adjustment
Inv_fee_line_item_dispute_adjustment_baseNumeric (20,6) Fee line item adjustments total in base currencybp_billing_authorization_requests.client_spot_rate x bp_invoices.fee_line_item_dispute_adjustment
Inv_header_dispute_adjustment_submittedNumeric (20,6) Header adjustments total (fee header + expense header adjustments) in submitted currencybp_invoices.header_dispute_adjustment_submitted
Inv_header_dispute_adjustment_baseNumeric (20,6) Header adjustments total (ffe header + expense header) in base currencybp_billing_authorization_requests.client_spot_rate x bp_invoices.header_dispute_adjustment_base
Inv_header_short_pay_adjustment_submittedNumeric (20,6) Not in usebp_invoices.header_short_pay_adjustment
Inv_header_short_pay_adjustment_baseNumeric (20,6) Not in useBp_billing_authorization_requests.client_spot_rate x bp_invoices.header_short_pay_adjustment
Inv_invoice_fees_submittedNumeric (20,6) Fees total in submitted currencyBp_invoices.invoice_fees
Inv.invoice_fees_baseNumeric (20,6) Fees total in base currencybp_billing_authorization_requests.client_spot_rate x bp_invoices.invoice_fees
Inv_invoice_expenses_submittedNumeric (20,6) Expenses total in submitted currency Bp_invoices.invoice_expenses
Inv_invoice_expenses_baseNumeric (20,6) Expenses total in base currencyBp_billing_authorization_requests.client_spot_rate x bp_invoices.invoice_expenses
Inv_invoice_orig_amount_submittedNumeric (20,6) Invoice total on first time submission in submitted currencyBp_invoices.invoice_orig_amount
Inv_invoice_orig_amount_baseNumeric (20,6) Invoice total on first time submission in base currencybp_billing_authorization_requests.client_spot_rate x bp_invoices.invoice_orig_amount
Inv_invoice_orig_discount_submittedNumeric (20,6) Invoice total discount on first time submission in submitted currencybp_invoices.invoice_orig_discount
Inv_invoice_orig_discount_baseNumeric (20,6) Invoice total discount on first time submission in base currencybp_billing_authorization_requests.client_spot_rate x bp_invoices.invoice_orig_discount
Inv_invoice_orig_expenses_submittedNumeric (20,6) Invoice total expenses on first time submission in submitted currencybp_invoices.invoice_orig_expenses
Inv_invoice_expenses_baseNumeric (20,6) Invoice total expenses on first time submission in base currencybp_billing_authorization_requests.client_spot_rate x bp_invoices.invoice_orig_expenses
Inv_invoice_orig_fees_submittedNumeric (20,6) Invoice total fees on first time submission in submitted currencyBp_invoices.invoice_orig_fees_submitted
Inv_invoice_orig_fees_baseNumeric (20,6) Invoice total on first time submission in base currencybp_billing_authorization_requests.client_spot_rate x bp_invoices.invoice_orig_fees_base
Inv_invoice_total_submittedNumeric (20,6) Invoice total in submitted currencybp_invoices.invoice_total
Inv_invoice_total_baseNumeric (20,6) Invoice total in base currencybp_billing_authorization_requests.client_spot_rate x bp_invoice_total
Inv_line_item_short_pay_adjustment_submittedNumeric (20,6) Not in useBp_invoices.line_item_short_pay_adjustment
Inv_line_item_short_pay_adjustment_baseNumeric (20,6) Not in usebp_billing_authorization_requests.client_spot_rate x bp_invoices.line_item_short_pay_adjustment
Inv_orig_expense_discount_submittedNumeric (20,6) Total expense discount on first time submission in submitted currencybp_invoices.orig_expense_discount
Inv_orig_expense_discount_baseNumeric (20,6) Total expense discount on first time submission in base currencybp_billing_authorization_requests.client_spot_rate x bp_invoices.orig_expense_discount
Inv_orig_fee_discount_submittedNumeric (20,6) Total fee discount on first time submission in submitted currencybp_invoices.orig_fee_discount
Inv_orig_fee_discount_baseNumeric (20,6) Total fee discount on first time submission in base currencybp_billing_authorization_requests.client_spot_rate x bp_invoices.orig_fee_discount
Inv_pay_total_submittedNumeric (20,6) Its invoice_total -short_pay_total. Since short_pay may not be in use (need to confirm) so its most likely equals to invoice_totalbp_invoices.pay_total
Inv_pay_total_baseNumeric (20,6) Same as above but in base currencybp_billing_authorization_requests.client_spot_rate x bp_invoices.pay_total
Inv_short_pay_adjustment_total_submittedNumeric (20,6) Not in usebp_invoice.short_pay_adjustment_total
Inv_short_pay_adjustment_total_baseNumeric (20,6) Not in usebp_billing_authorization_requests.client_spot_rate x bp_invoices.short_pay_adjustment_total
Inv_remote_keyCharacter varying AB invoice atom IDBp_invoices.remote_key
Li_task_descriptionCharacter varying Description of task codeBp_invoice_line_items.task_description
Li_tax_descriptionCharacter varying Description of tax codebp_invoice_line_items.tax_description
Li_expense_descriptionCharacter varying Description of the expense codebp_invoice_line_items.expense_description
Li_discount_descriptionCharacter varying Description of the discount codebp_invoice_line_items.discount_description
Li_activity_descriptionCharcter varying Description of activity codebp_invoice_line_items.activity_description
Li_adjustment_descriptionCharacter varying Description of adjustment codebp_invoice_line_items.adjustment_description
Li_idtext Id of the invoice line itembp_invoice_line_items.id
Li_activity_codeCharacter varying Activity codebp_invoice_line_items.activity_code
Li_activity_dateTimestamp w/o time zone Date for which timekeeper is billing on invoice, activity date of line itembp_invoice_line_items.activity_date
Li_adjuster_idText Id of the adjuster user is Counsel Exchangebp_invoice_line_items.adjuster_id
Li_adjuster_nameCharacter varying Name of the adjuster user in Counsel Exchangebp_invoice_line_items.adjuster_name
Li_adjustment_codeCharacter varying Adjustment codebp_invoice_line_items.adjustment_code
Li_adjustment_valueNumeric (20,6) Value by an line item is adjusted, it may be hours, rate, percentage or netbp_invoice_line_items.adjustment_value
Li_discount_codeCharacter varying Discount codebp_invoice_line_items.discount_code
Li_dispute_adjustment_typeCharacter varying Type of adjustment e.g., set_amount_to, reduce_by_pct, reduce_by_amount,set_rate_to,set_net_tobp_invoice_line_items.dispute_adjustment_type
Li_expense_codeCharacter varying Expense codebp_invoice_line_items.expense_code
Li_inactiveBigint 1 if line item is inactive, 0 otherwisebp_invoice_line_items.inactive
Li_invoice_line_item_typeCharacter varying Type of line itembp_invoice_line_items.invoice_line_item_type
Li_item_descriptionText Description of the line itembp_invoice_line_items.item_description
Li_parent_typeCharacter varying Parent of this line item, it may be a line item or invoicebp_invoice_line_items.parent_type
Li_parent_idUuid Parent Id. When FeeDispute adjustment is made, this field stores the line item id of the fee line itembp_invoice_line_items.parent_id
Li_system_createdBigint 1 if system created, 0 otherwisebp_invoice_line_items.system_created
Li_task_codeCharacter varying Task codebp_invoice_line_items.task_code
Li_tax_codeCharacter varying Tax codebp_invoice_line_items.tax_code
Li_adjustment_cost_submittedNumeric (20,6) No longer usedbp_invoice_line_items.adjustment_cost
Li_adjustment_cost_baseNumeric (20,6) No longer usedbp_billing_authorization_requests.client_spot_rate x bp_invoice_line_items.adjustment_cost
Li_adjustment_total_submittedNumeric (20,6) No longer usedbp_invoice_line_items.adjustment_total
Li_adjustment_total_baseNumeric (20,6) No longer usedbp_billing_authorization_requests.client_spot_rate x bp_invoice_line_items.adjustment_total
Li_adjustment_unitNumeric (20,6) No longer usedBp_invoice_line_items.adjustment_unit
Li_item_quantityNumeric (20,6) Line item number of unitsbp_invoice_line_items.item_quantity
Li_item_unit_costNumeric (20,6) Line item unit costbp_invoice_line_items.item_unit_cost
Li_line_item_total_submittedNumeric (20,6) Line item total in vendor base currencybp_invoice_line_items.line_item_total
Li_discount_submittedNumeric (20,6) Line item total in submitted currencybp_invoice_line_items.discount
Li_discount_baseNumeric (20,6) Submitted discount in client’s base currency. Client’s spot rate x discountbp_billing_authorization_requests.client_spot_rate x bp_invoice_line_items.discount
Li_line_item_total_baseNumeric (20,6) Line item total in vendor base. Client’s spot rate x line item totalbp_billing_authorization_requests.client_spot_rate x bp_invoice_line_items.line_item_total_base
Li_timekeeper_rate_submittedNumeric (20,6) Submitted rate of the timekeeperBp_invoice_line_items.timekeeper_rate
Li_timekeeper_rate_baseNumeric (20,6) Client’s spot rate x Submitted rate for the time keeperbp_billing_authorization_requests.client_spot_rate x bp_invoice_line_items.timekeeper_rate
Tk_time_keeper_idUuid Id of the time keeperbp_timekeepers.time_keeper_id
Tk_currency_codeCharacter varying Currency code for the time keeper’s currencybp_timekeepers.currency_code
Tk_currency_symbolCharacter varying Currency symbol for the time keeper’s currencybp_timekeepers.currency_symbol
Tk_date_bar_passedBigint Date of bar passedbp_timekeepers.date_bar_passed
Tk_default_rate_effective_dateTimestamp w/o time zone Effective date for the default rate for the time keeperbp_timekeepers.default_rate_effective_rate
Tk_emailCharacter varying Email id of the timekeeperbp_timekeepers.email
Tk_employee_idCharacter varying Employee id of the timekeeperbp_timekeepers.employee_id
Tk_ethnicityCharacter varying Ethnicity of the time keeper. This field will contain ‘Not Disclosed’ when supress diversity info it true.bp_timekeepers.ethnicity
Tk_first_practicedBigint Year when time keeper first practicedbp_timekeepers.first_practiced
Tk_full_nameCharacter varying Full name of the time keeperbp_timekeepers.full_name
Tk_genderCharacter varying Gender of the time keeperbp_timekeepers.gender
Tk_default_rateNumeric (20,6) Default rate of the time keeperbp_timekeepers.default_rate
Tk_default_rate_baseNumeric (20,6) Client’s spot rate x Default rate of the time keeperbp_timekeepers.default_base_rate
Tk_initialsCharacter varying Initials of the time keeperbp_timekeepers.initials
Tk_lawyerBigint 1 when timekeepr is a lawyer, 0 otherwisebp_timekeepers.lawyer
Tk_other_ethnicityCharacter varying Other ethnicity of the time keeper. This field is blank when supress diversty is truebp_timekeepers.other_ethnicity
Tk_phoneCharacter varying Phone of the timekeeperbp_timekeepers.phone
Tk_staff_class_codeCharacter varying Code of the staff classification for the timekeeperbp_staff_classifications.code if available on line item, else bp_timekeepers.staff_class_code
Tk_staff_class_descriptionCharacter varying Description of the staff classification for the timekeeperbp_staff_classifications.description if available on line item, else bp_timekeepers.staff_class_description
Tk_urlCharacter varying URL of the timekeepr’s profilebp_timekeeper.url
Tk_approved_rateNumeric (20,6) Rate approved for this timekeeperbp_timekeeper.approved_rate
Tk_pending_rateNumeric (20,6) Rate pending for approval for this timekeeperbp_timekeeper.pending_rate
Tk_approved_rate_baseNumeric (20,6) Client’s spot rate x Rate approved for this timekeeperbp_billing_authorization_requests.client_spot_rate x bp_timekeeper.approved_rate
Tk_pending_rate_baseNumeric (20,6) Client’s spot rate x Rate pending for approval for this timekeeperbp_billing_authorization_requests.client_spot_rate x bp_timekeeper.pending_rate
Tk_client_time_keeper_idUuid Id of the client timekeeperbp_timekeepr.client_time_keeper_id
Tk_office_idUuid Id of the office of the timekeeperBp_timekeeper.office_id
Tk_office_nameCharacter varying Name of the office of the time keeperbp_timekeeper.office_name
Bp_tk_client_approved_rateNumeric (20,6) Last approved rate for the time keeper for the clientBp_timekeeper_rates.rate
Bp_tk_standard_rateNumeric (20,6) Standard rate for the timekeeper that is derieved from the time keeper rate histories based on the line item activity date between effective start date and effective end dateBp_timekeeper_rates_histories.rate
Client_base_currency_codeCharacter varying Currency code for client’s abse currencybp_account.client_base_currency_code
Client_base_currency_symbolCharacter varying Currency symbol for client’s base currency Bp_accounts.client_base_currency_symbol
Tk_countryCharacter varying Country of the time keeperBp_timekeeper.country
Tk_time_keeper_id_textText Text format of the timekeepr idbp_timekeepers.time_keeper_id
Inv_vat_processingBoolean DEFAULT false VAT flag on invoiceBp_invoices.vat_processing
Warehouse_refresh_dateTimestamp w/o time zone System date time when this view was refreshedNow()
bp_tk_derived_pending_rateNumeric (20,6) Last updated rate from the client timekeeper rates from Counsel Exchange where state is pending or pending_approval or resubmit or unapproveBp_timekeepers.bp_tk_derived_pending_rate
Bp_tk_derived_pending_rate_baseNumeric (20,6) Client’s pot rate x Last updated rate from client’s timekeeper rates from Counsel Exchange where state is pending or pending_approval or resubmit or unapprovebp_billing_authorization_requests.client_spot_rate xbp_timekeepers.bp_tk_derived_pending_rate

bp_invoices_line_item_cube view

Purpose

  • This is just a wrapper view for the invoices_line_item_cube  materialized view. This is added since Tableau Desktop does not show the materialized views to the Report writers.
  • All the columns in this view are the same as invocies_line_item_cube. Please refer to the invocies_cube for a data dictionary for this view.

Query Joins

Data Dictionary

Refer to the data dictionary for invoices_line_item_cube materialized view for details

view_timekeeper_rate_report view

Purpose

  • This view extracts the data related to the ELM timekeeper rate report.

Query Joins

Data Dictionary

Column nameData TypeUnique KeyDescriptionSource Field
Li_invoice_line_item_typeCharacter varying Type of the line iteminvoices_line_item_cube.li_invoice_line_item_type
Li_activity_dateTimestamp w/o time zone Line item activity typeinvoices_line_item_cube.li_activity_type
Tk_currency_codeCharacter varying Currency code for the time keeper’s currencyinvoices_line_item_cube.tk_currency_code
Tk_full_nameCharacter varying Full name of the timekeeperinvoices_line_item_cube.tk_full_name
Tk_staff_class_descriptionCharacter varying Description of the staff classification for the timekeeprinvoices_line_item_cube.tk_staff_class_description
Bp_tk_client_approved_rateNumeric (20,6) Line item number of unitsinvoices_line_item_cube.li_item_quantity
Li_line_item_total_baseNumeric (20,6) Line item total in vendor base. Client’s spot rate x Line item totalinvoices_line_item_cube.li_line_item_total_base
Tk_time_keeper_idUuid Id of the time keeperinvoices_line_item_cube.tk_time_keeper_id
Tk_first_practicedBigint Year when the timekeeper first practicedinvoices_line_item_cube.tk_first_practiced
Inv_remote_keyCharacter varying _id of the atom from the invoice appinvoices_line_item_cube.inv_remote_key
Tk_client_time_keeper_idUuid Id of the client timekeeperinvoices_line_item_cube.client_timekeeper_id
Invoice_idUuid Id of the invoiceinvoices._id AS invoice_id
Invoices_manual_invoiceCharacter varying “True” if manual invoice, else “false"Invoices.manual_invoice AS invoices_manual_invoice
Invoices_psb_vendor_nameCharacte varying Name of the vendor from Counsel Exchangeinvoices.psb_vendor_name AS invoices_psb_vendor_name
invoices_officeCharacter varying Officeinvoices.office AS invoices_office
Offices_idUuid Id of the officeOffices._id AS offices_id
Office_cityCharacter varying City of the officeOffices.city AS offices_city
Office_countryCharacter varying Country of the officeOffices.country AS office_country
Tk_default_rateNumeric (20,6) Default rate of the time keeperinvoices_line_item_cube.tk_default_rate
Tk_default_rate_baseNumeric (20,6) Client’s spot rate x Default rate of the time keeperinvoices_line_item_cube.tk_default_rate_based
Tk_approved_rateNumeric (20,6) Approved rate of the time keeperinvoices_line_item_cube.tk_approved_rate
Tk_approved_rate_baseNumeric (20,6) Client’s spot rate x Rate pending approval for this timekeeperinvoices_line_item_cube.tk_approved_rate
Tk_pending_rateNumeric (20,6) Rate pending for approval for this timekeeperinvoices_line_item_cube.tk_pending_rate
Tk_pending_rate_baseNumeric (20,6) Client’s spot rate x Rate pending for approval for this timekeeperinvoices_line_item_cube.tk_pending_rate_base
Bp_tk_dervied_pending_rateNumeric (20,6) last updated rate from client timekeepr rates from Counsel Exchange where stat is pending or pending_approval or resubmit or unapproveinvoices_line_item_cube.tk_derived_pending_rate
Bp_tk_dervied_pending_rate_baseNumeric (20,6) Client's spot rate x Last updated rate from client timekeeper rates from Counsel Exchange where state is pending or pending_approval or resubmit or unapproveinvoices_line_item_cube.bp_tk_derived_pending_rate_base

bp_bar_line_items materialized view

Purpose:

  • This materialized view contains the matter rate,matter_rate_submitted date, matter_rate_currency_code from ebilling bar line items. 
  • ​This materialized view is refreshed daily during the nightly refresh process.​

Query Joins

Data Dictionary

Column NameData TypeUnique KeyDescriptionDefault
iduuidYesBAR id, ID of the record, primary keybar_line_items.id
billing_authorization_request_iduuid Billing authorization requestbar_line_items.billing_authorization_request_id
client_timekeeperuuid Client Timekeeper IDbar_line_items.client_timekeeper_id
client_timekeeper_rate_iduuid Client Timekeeper IDbar_line_items.client_timekeeper_rate_id
time_keeper_iduuid Time Keeper IDbar_line_items.timekeeper_id
account_iduuid Account IDbar_line_items.account_id
remote_iduuid ID of BAR record in Appbuilderbar_line_items.account_id
time_keeper_ratenumeric Bar timekeeper ratebar_line_items.time_keeper_rate
updated_attimestamp without time zone BAR updated datebar_line_items.updated_at
created_attimestampe without time zone BAR creation datebar_line_items.created_at
deleted_attimestamp without time zone BAR deleted datebar_line_items.deleted_at
namenumeric Type of fee arrangementfee_arrangements.name
currency_codecharacter varying Currency code for client sup[ported currencybp_currencies.currency_code
Next Article Reporting Data Flow

© 2026 Onit, Inc.

docs.onit.com contains proprietary and confidential information owned by Onit, Inc. that is subject to copyright. Onit presents it exclusively to you for your sole use in conjunction with using Onit products. No portion of the materials contained herein may be used for any other purpose. No portion of the materials contained herein may be shared with third parties or reproduced in any form.