Table: dbo.Custom_Excel_Grid
This table will hold data for custom excel grid
Columns
Name | Type | Constraints | Description
trial_balance_grid_KEY | int (4) | NOT NULL | Primary key. Foreign key to Trial Balance Grid table
workpaper_KEY | int (4) |  | Foreign key to workpaper table
custom_excel_grid_guid | uniqueidentifier (16) | NOT NULL | Stores a guid for the custom excel grid
sheet_name | nvarchar (62) | NOT NULL | Name for excel sheet
page_orientation | bit (1) | NOT NULL | Landscape or Portrait
include_inactive | bit (1) | NOT NULL | Boolean that tells us whether we want to include inactive accounts
client_consolidation_grouping_type_KEY | int (4) | NOT NULL | Foreign key to client consolidation grouping type table
include_account_details | bit (1) | NOT NULL | Whether or not to include account details for a tax code based custom Excel grid.

Primary key
Name | Columns | Description
PK_Custom_Excel_Grid$trial_balance_grid_KEY | trial_balance_grid_KEY |
Unique constraints
Name | Columns | Description
UK_Custom_Excel_Grid$custom_excel_grid_guid | custom_excel_grid_guid |
UK_Custom_Excel_Grid$workpaper_KEY$sheet_name | workpaper_KEY, sheet_name |

Foreign keys
Name | Columns | Referenced table | Description
FK_Custom_Excel_Grid__Client_Consolidation_Grouping_Type__client_consolidation_grouping_type_KEY | client_consolidation_grouping_type_KEY | Client_Consolidation_Grouping_Type (client_consolidation_grouping_type_KEY) |
FK_Custom_Excel_Grid__Trial_Balance_Grid__trial_balance_grid_KEY | trial_balance_grid_KEY | Trial_Balance_Grid (trial_balance_grid_KEY) |
FK_Custom_Excel_Grid__Workpaper__workpaper_KEY | workpaper_KEY | Workpaper (workpaper_KEY) |