
USE fetchmetrics;

-- DROP TABLE IF EXISTS fetchmetrics.DOG_Assessment_Response_Temp;

SELECT CONCAT('WARNING: Table ', TABLE_SCHEMA, '.', TABLE_NAME, ' already exists.') AS msg_warning 
FROM INFORMATION_SCHEMA.TABLES 
WHERE 
        TABLE_SCHEMA = 'fetchmetrics' 
    AND TABLE_NAME = 'DOG_Assessment_Response_Temp'
;

CREATE TABLE IF NOT EXISTS fetchmetrics.DOG_Assessment_Response_Temp (
	  id_temp INT NOT NULL PRIMARY KEY AUTO_INCREMENT
    , id_response INT
	, id_assessment_command_modality_link INT
	, id_response_quality_metric INT
    , id_obedience_level INT
    , value_measured DOUBLE
	, notes TEXT
	, active BIT

    , does_meet_id_filters BIT
    , does_meet_non_id_filters BIT
    
    , guid BINARY(36)
);
