Table: dbo.Quick_Books_Payroll_Item
This table contains information about payroll items that we have imported from quickbooks.
Columns
Name | Type | Constraints | Description
quick_books_payroll_item_KEY | int (4) | NOT NULL | The primary key.
client_KEY | int (4) | NOT NULL | Foreign key to Client table. Client for whom this payroll item was imported.
quick_books_payroll_item_type_KEY | int (4) | NOT NULL | The quickbooks payroll item type. Foreign key to the Quick Books Payroll Item Type table.
is_wage_item | bit (1) | NOT NULL | payroll items in quickboks are divided into two categories: wage and non wage.
list_id | nvarchar (120) | NOT NULL | Unique identifier of the payroll item, according to Intuit documentation.
name | nvarchar (100) | NOT NULL | The name of the payroll item in quick books.
is_active | bit (1) | NOT NULL | flag to tell us if the payroll item is active or not in quickbooks.

Primary key
Name | Columns | Description
PK_Quick_Books_Payroll_Item | quick_books_payroll_item_KEY |
Unique constraints
Name | Columns | Description
UK_Quick_Books_Payroll_Item$list_id$client_KEY | list_id, client_KEY |
UK_Quick_Books_Payroll_Item$name$client_KEY | name, client_KEY |

Foreign keys
Name | Columns | Referenced table | Description
FK_Quick_Books_Payroll_Item__Client__client_KEY | client_KEY | Client (client_KEY) |
FK_Quick_Books_Payroll_Item__Quick_Books_Payroll_Item_Type__quick_books_payroll_item_type_KEY | quick_books_payroll_item_type_KEY | Quick_Books_Payroll_Item_Type (quick_books_payroll_item_type_KEY) |

Incoming foreign keys
Name | Columns | Referencing table | Description
FK_Quick_Books_Payroll_Item_N_Client_Payroll_Item__Quick_Books_Payroll_Item__quick_books_payroll_item_KEY | quick_books_payroll_item_KEY | Quick_Books_Payroll_Item_N_Client_Payroll_Item |
FK_Quick_Books_Payroll_Item_N_Client_Tax_Item__Quick_Books_Payroll_Item__quick_books_payroll_item_KEY | quick_books_payroll_item_KEY | Quick_Books_Payroll_Item_N_Client_Tax_Item |