USE catalogdb;

INSERT INTO northbound_request_ref_lookup(MACRO_ACTION, ACTION, REQUEST_SCOPE, IS_ALACARTE, MIN_API_VERSION, MAX_API_VERSION, IS_TOPLEVELFLOW) VALUES
('Network-Update', 'updateInstance', 'Network', true, '7','7','1');

INSERT INTO orchestration_flow_reference(COMPOSITE_ACTION, SEQ_NO, FLOW_NAME, FLOW_VERSION, NB_REQ_REF_LOOKUP_ID) VALUES
('Network-Update', '1', 'UpdateNetworkBB', 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'Network-Update'));

INSERT INTO building_block_detail(BUILDING_BLOCK_NAME,RESOURCE_TYPE,TARGET_ACTION) VALUES
('UpdateNetworkBB','NETWORK','UPDATE');

INSERT INTO orchestration_status_state_transition_directive(RESOURCE_TYPE, ORCHESTRATION_STATUS,TARGET_ACTION,FLOW_DIRECTIVE) VALUES
('NETWORK','PRECREATED','UPDATE','FAIL'),
('NETWORK','INVENTORIED','UPDATE','FAIL'),
('NETWORK','ASSIGNED','UPDATE','FAIL'),
('NETWORK','CREATED','UPDATE','FAIL'),
('NETWORK','PENDING_CREATE','UPDATE','FAIL'),
('NETWORK','PENDING_DELETE','UPDATE','FAIL'),
('NETWORK','PENDING_ACTIVATION','UPDATE','FAIL'),
('NETWORK','ACTIVE','UPDATE','CONTINUE');