コード例 #1
0
 /**
  * Gets the historical journal for an object from the log database.
  * Objects will have VirtualAttributes available to lookup login, date, and action information from the journal object.
  * @param integer intId
  * @return Registry[]
  */
 public static function GetJournalForId($intId)
 {
     $objDatabase = Registry::GetDatabase()->JournalingDatabase;
     $objResult = $objDatabase->Query('SELECT * FROM registry WHERE id = ' . $objDatabase->SqlVariable($intId) . ' ORDER BY __sys_date');
     return Registry::InstantiateDbResult($objResult);
 }
コード例 #2
0
    /**
     * Truncate registry table
     * @return void
     */
    public static function Truncate()
    {
        // Get the Database Object for this Class
        $objDatabase = Registry::GetDatabase();
        // Perform the Query
        $objDatabase->NonQuery('
				TRUNCATE `registry`');
    }