Delimiter //
/**
 */
Drop Procedure If Exists LOADER_LINKEDACCOUNTS_NORMALIZE//
Create Procedure LOADER_LINKEDACCOUNTS_NORMALIZE(
    In batchnum Int
)
MAIN_LINKEDACCOUNTS_NORMALIZE: Begin
	call LOADER_LINKEDACCOUNTS_NORMALIZE_ACCOUNT_REF_NOT_NULL(batchnum);
	call LOADER_LINKEDACCOUNTS_NORMALIZE_ACCOUNT_NOT_EQUALS(batchnum);
	call LOADER_LINKEDACCOUNTS_NORMALIZE_MAP_ACCOUNTS(batchnum);
	call LOADER_LINKEDACCOUNTS_NORMALIZE_MAP_ACCOUNTS_LINK(batchnum);
	call LOADER_LINKEDACCOUNTS_NORMALIZE_ACCOUNT_REF_IS_UNIQUE(batchnum);

	-- doit être précéder de LOADER_LINKEDACCOUNTS_NORMALIZE_MAP_ACCOUNTS_LINK et LOADER_LINKEDACCOUNTS_NORMALIZE_MAP_ACCOUNTS
	call LOADER_LINKEDACCOUNTS_NORMALIZE_MAP_LINK_EXISTS(batchnum); 
	
End//
Delimiter ;