Commit d1c45859 authored by chtito's avatar chtito

added a setDateFormat method (primarily intended for the Oracle connection)

parent cb924af3
......@@ -480,6 +480,16 @@ abstract class Doctrine_Connection extends Doctrine_Configurable implements Coun
public function setCharset($charset)
{
}
/**
* Set the date/time format for the current connection
*
* @param string time format
*
* @return void
*/
public function setDateFormat($format = null)
{
}
/**
* fetchAll
*
......
......@@ -69,6 +69,14 @@ class Doctrine_Connection_Oracle extends Doctrine_Connection
$this->options['result_prefetching'] = false;
*/
parent::__construct($manager, $adapter);
}
/**
* Sets up the date/time format
*
*/
public function setDateFormat($format = 'YYYY-MM-DD HH24:MI:SS')
{
$this->exec('ALTER SESSION NLS_DATE_FORMAT "'.$format.'";');
}
/**
* Adds an driver-specific LIMIT clause to the query
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment