Changed all column names from "STATE" to "STATE_LABEL"
Removed the usage of TEMPORARY tables as DatabaseConnector had problems with them in SQL server, now regular relations in DB
Fixed error for SQL server, does not support operation "-" between dates