
USE parts;

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

CREATE TABLE IF NOT EXISTS parts.DOG_Assessment_Temp (
	  id_temp INT NOT NULL PRIMARY KEY AUTO_INCREMENT
	, id_assessment INT
	, id_weather INT
	, id_lighting_level INT
	, id_location INT
	, id_user_handler INT
	, notes TEXT
    , temperature_celcius DECIMAL(5, 2)
--    , difficulty_level DOUBLE
	, active BIT

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