MINOR Removed unncessary use of LEFT() in MSSQLDatabase::datetimeIntervalClause()

This commit is contained in:
Sean Harvey 2010-05-19 10:09:51 +00:00
parent 39576dd4e0
commit 7fad117464

View File

@ -1444,7 +1444,8 @@ class MSSQLDatabase extends SS_Database {
} else if(preg_match('/^\d{4}-\d{2}-\d{2} \d{2}:\d{2}:\d{2}$/i', $date)) {
$date = "'$date'";
}
return "LEFT(CONVERT(VARCHAR, DATEADD(" . $trans[strtolower($matches[2])] . ", " . (int)$matches[1] . ", $date), 120), 19)";
return "CONVERT(VARCHAR, DATEADD(" . $trans[strtolower($matches[2])] . ", " . (int)$matches[1] . ", $date), 120)";
}
/**