Documentation

CurrentTimeFunction

string
CDatabase::CurrentTimeFunction()

The method "SYSDATE" string for Oracle version and "now()" string for MySQL. Non-static method.

Parameters

No parameters.

See Also

Examples of use

<?
$DB->Upd ate("my_table", Array("TIME_CHANGE" => $DB->CurrentTimeFunction()), 
"WHERE ID=45", $err_mess.__LINE__);
?>
<?
$strSql = "
    UPDATE my_table SE T 
        TIME_CHANGE=".$DB->CurrentTimeFunction()." 
    WHERE ID=45
    ";
$Query($strSql, false, "FILE: ".__FILE__."<br>LINE: ".__LINE__);
?>
<?
$strSql = "
    SEL ECT 
        ID
    FR OM 
        my_table
    WHERE 
        TIME_CHANGE <= ".$DB->CurrentTimeFunction()."
    ";
$rs = $DB->Query($strSql, false, $err_mess.__LINE__);
?>


© «Bitrix24», 2001-2024