Skip to content

Commit

Permalink
#DtoI-1826
Browse files Browse the repository at this point in the history
  • Loading branch information
robjharrison committed Oct 4, 2024
1 parent e5263e1 commit 8d4270a
Show file tree
Hide file tree
Showing 165 changed files with 14,858 additions and 1,259 deletions.

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,6 @@ DECLARE @CaseloadTimeframeStartDate DATE = DATEADD(YEAR, -@ssd_timeframe_years,
-- Point to DB/TABLE_CATALOG if required (SSD tables created here)
USE HDM_Local; -- used in logging (and seperate clean-up script(s))
DECLARE @schema_name NVARCHAR(128) = N'ssd_development'; -- set your schema name here OR leave empty for default behaviour. Used towards ssd_extract_log
DECLARE @TableName NVARCHAR(128) = N'table_name_placeholder'; -- Note: also/seperately use of @table_name in non-test|live elements of script.


-- META-END
Expand Down

Large diffs are not rendered by default.

3,931 changes: 3,923 additions & 8 deletions deployment_extracts__future_release/350_bradford_systemc_sqlserver_v1.2.2_1.sql

Large diffs are not rendered by default.

Large diffs are not rendered by default.

134 changes: 0 additions & 134 deletions la_config_files__future_release/332.yml

This file was deleted.

123 changes: 123 additions & 0 deletions la_config_files__future_release/332_eastsussex.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,123 @@
332:
la_code: 332
la_name: EastSussex

deployment_system: # META-ELEMENT: {"type": "deployment_system"}
cms: SystemC
cms_db: 'SQLServer'
db_vers: null
ics_universe_vers: null
data_warehouse_vers: null
front_end_vers: null

config_metadata: # META-ELEMENT: {"type": "config_metadata"}
last_updated: 2024-09-09
version: 1.0
updated_by: rharrison
change_description: null
approved_by: null
documentation_link: https://data-to-insight.github.io/ssd-data-model

header: # META-ELEMENT: {"type": "header"}
header_text: |
*********************************************************************************************************
STANDARD SAFEGUARDING DATASET EXTRACT
https://data-to-insight.github.io/ssd-data-model/
We strongly recommend that initial pilot/trials of SSD scripts occur in a development|test environment.
The SQL script is non-destructive. SSD clean-up scripts are available seperately, these are destructive.
*********************************************************************************************************
# EXTRACT SETTINGS
settings:
# params used within SQL SSD extract

extract_parameters: # META-ELEMENT: {"type": "ssd_timeframe"}
ssd_timeframe_years: 3
ssd_sub1_range_years: 1

persistent_ssd: # META-ELEMENT: {"type": "persistent_ssd"}
deploy_temp_tables: false # true = temporary tables, false = persistent tables
temp_table_prefix: "#ssd_"


dbschema: # META-ELEMENT: {"type": "dbschema"} # la schema definition
data_source_schema: HDM.Child_Social
deployment_database_name: HDM_Local
deployment_schema_name: null

dev_setup: # META-ELEMENT: {"type": "dev_setup"}
no_count_on: false

# REMOVE | CLEAN UP SQL

# remove ALL in script refs of named META-ELEMENT: block type using: true/false flags
global_sql_tag_remove:
remove_drop_table: false
remove_insert_data: false
remove_test: true
remove_console: false
remove_deployment_status_note: true
remove_ssd_non_core_modifications: true

remove_create_pk: false
remove_create_fk: false
remove_create_idx: false


named_sql_container_remove:
- involvements_history

named_sql_tag_remove:
remove_drop_table: # {"type": "drop_table"}
- null
remove_create_table: # {"type": "create_table"}
- null
remove_insert_data:
- ssd_ehcp_active_plans
- ssd_ehcp_named_plan
- ssd_ehcp_assessment
- ssd_ehcp_requests
- ssd_sen_need
- ssd_pre_proceedings
- ssd_voice_of_child
- ssd_s251_finance
remove_create_pk:
- ssd_sdq_scores
remove_create_fk:
- ssd_ehcp_active_plans
- ssd_ehcp_named_plan
- ssd_ehcp_assessment
- ssd_ehcp_requests
- ssd_sen_need
- ssd_pre_proceedings
- ssd_voice_of_child
- ssd_s251_finance
- ssd_cla_reviews
- ssd_cla_previous_permanence
- ssd_cla_visits
- ssd_sdq_scores
- ssd_care_leavers
- ssd_permanence
- ssd_cp_visits
- ssd_cp_reviews
- ssd_department
remove_create_idx:
- ssd_ehcp_active_plans
- ssd_ehcp_named_plan
- ssd_ehcp_assessment
- ssd_ehcp_requests
- ssd_sen_need
- ssd_pre_proceedings
- ssd_voice_of_child
- ssd_s251_finance
extract_sql_custom_la:
customise_db_schema:
- ssd_item_ref: null
ssd_table: null
ssd_item_field_name: null
la_field_name: null
la_table_name: null
la_datatype: null
la_datatype_size: null

Original file line number Diff line number Diff line change
Expand Up @@ -31,91 +31,91 @@
# EXTRACT SETTINGS
settings:
# params used within SQL SSD extract

extract_parameters: # META-ELEMENT: {"type": "ssd_timeframe"}
ssd_timeframe_years: 5
ssd_sub1_range_years: 1
# CaseloadLastSept30th: "2024-09-30" # currently set in sql based on currDate->prevSept30th

persistent_ssd: # META-ELEMENT: {"type": "persistent_ssd"}
deploy_temp_tables: false # true = temporary tables, false = persistent tables
temp_table_prefix: "#ssd_"

dbschema: # META-ELEMENT: {"type": "dbschema"} # la schema definition
database_name: HDM_Local # i.e. default tablespace
schema_name: null
dbschema: # META-ELEMENT: {"type": "dbschema"} # la schema definition
data_source_schema: HDM.Child_Social
deployment_database_name: HDM_Local
deployment_schema_name: null

dev_setup: # META-ELEMENT: {"type": "dev_setup"}
no_count_on: false # true = SET NOCOUNT ON; / false = SET NOCOUNT OFF;
no_count_on: false

# REMOVE | CLEAN UP SQL
# remove ALL in script refs of named META-ELEMENT: block type using: true/false flags
# overides and precedes localised settings in <named_sql_tag_remove:>
global_sql_tag_remove:
remove_drop_table: false # all blocks tagged with -- META-ELEMENT: {"type": "drop_table"} - lossy/destructive SQL
remove_insert_data: true # all blocks tagged with -- META-ELEMENT: {"type": "insert_data"} - towards creating no-data SSD structure
remove_test: true # all blocks tagged with -- META-ELEMENT: {"type": "test"} - towards silent running
remove_console: false # all blocks tagged with -- META-ELEMENT: {"type": "console_output"} - towards silent running
remove_deployment_status_note: true # all blocks tagged with -- META-ELEMENT: {"type": "deployment_status_note"}
remove_ssd_non_core_modifications: true # all blocks tagged with -- META-ELEMENT: {"type": "ssd_non_core_modifications"}
remove_drop_table: true
remove_insert_data: false
remove_test: true
remove_console: false
remove_deployment_status_note: true
remove_ssd_non_core_modifications: true

remove_create_pk: true # all blocks tagged with -- META-ELEMENT: {"type": "create_pk"}
remove_create_fk: true # all blocks tagged with -- META-ELEMENT: {"type": "create_fk"}
remove_create_idx: true # all blocks tagged with -- META-ELEMENT: {"type": "create_idx"}
remove_create_pk: true
remove_create_fk: true
remove_create_idx: true

# BESPOKE SQL | SCHEMA
named_sql_container_remove:
- involvements_history
- ssd_send


# remove named object/table level references <within> labelled parent block type
# e.g. [parent block] -- META-CONTAINER: {"type": "table", "name": "ssd_family"}
# [child type meta block]-- META-ELEMENT: {"type": "drop_table"}
named_sql_tag_remove:
remove_drop_table: # {"type": "drop_table"}
- null
remove_create_table: # {"type": "create_table"}
- null
remove_insert_data: # {"type": "insert_data"}
remove_insert_data:
- ssd_ehcp_active_plans
- ssd_ehcp_named_plan
- ssd_ehcp_assessment
- ssd_ehcp_requests
- ssd_sen_need
- pre_proceedings
- ssd_pre_proceedings
- ssd_voice_of_child
- ssd_s251_finance
remove_create_pk: # {"type": "create_pk"}
- null
remove_create_fk: # {"type": "create_fk"}
remove_create_pk:
- ssd_initial_cp_conference # duplicate key in object 'dbo.#ssd_initial_cp_conference'. The duplicate key value is (12833) 25/07/24 CM
remove_create_fk:
- ssd_ehcp_active_plans
- ssd_ehcp_named_plan
- ssd_ehcp_assessment
- ssd_ehcp_requests
- ssd_sen_need
- pre_proceedings
- ssd_pre_proceedings
- ssd_voice_of_child
- ssd_s251_finance
remove_create_idx: # {"type": "create_idx"}
- ssd_cla_reviews
- ssd_cla_previous_permanence
- ssd_cla_visits
- ssd_sdq_scores
- ssd_care_leavers
- ssd_permanence
- ssd_cp_visits
- ssd_cp_reviews
- ssd_department
remove_create_idx:
- ssd_ehcp_active_plans
- ssd_ehcp_named_plan
- ssd_ehcp_assessment
- ssd_ehcp_requests
- ssd_sen_need
- pre_proceedings
- ssd_pre_proceedings
- ssd_voice_of_child
- ssd_s251_finance


# BESPOKE SQL | SCHEMA
extract_sql_custom_la:
customise_db_schema:
- ssd_item_ref: CINE010A # compulsory: needed to identify all items
ssd_table: ssd_cin_episodes # compulsory: to ensure correct container block to effect edits
- ssd_item_ref: CINE010A
ssd_table: ssd_cin_episodes
ssd_field_name: cine_cin_primary_need_code
la_field_name: null # if you want to replace the field name
la_table_name: null # replacement name/actual db table in LA system (can be different)
la_field_name: null
la_table_name: null
la_datatype: nvarchar
la_datatype_size: 6

# duplicate the above block to add further bespoke changes

Loading

0 comments on commit 8d4270a

Please sign in to comment.