getRawSql() public method

Note that the return value of this method should mainly be used for logging purpose. It is likely that this method returns an invalid SQL due to improper replacement of parameter placeholders.
public getRawSql ( ) : string
return string the raw SQL with parameter values inserted into the corresponding placeholders in [[sql]].
Exemplo n.º 1
0
 /**
  * Extended functional: caching rawSql data between queryInternal() calls for one query execution
  * @inheritdoc
  */
 public function getRawSql()
 {
     if ($rawSql = static::$requestLocalCache->get('rawSql')) {
         static::$requestLocalCache->delete('rawSql');
         return $rawSql;
     }
     return parent::getRawSql();
 }