909
909
if ((!mysql_query($query, $this->dbh))&&(mysql_errno($this->dbh) != CACHEDB::MYSQL_ER_SP_ALREADY_EXISTS)) {
910
910
throw new ADEIException(translate("CACHE is not able to create stored procedure (%s), error: %s", "ADEI_TIMESTAMP", mysql_error($this->dbh)));
913
$query = "CREATE FUNCTION EXTENDED_UNIX_TIMESTAMP(dt DATETIME) RETURNS BIGINT DETERMINISTIC RETURN TIMESTAMPDIFF(SECOND, '1970-01-01 00:00:00+00', dt)";
915
throw new ADEIException(translate("CACHE is not able to create stored procedure (%s), error: %s", "EXTENDED_UNIX_TIMESTAMP", mysql_error($this->dbh)));
914
919
function CreateTable($resolution, $items, $postfix = false) {