/**
  * PDO Compability 
  * Returns the last value inserted into an IDENTITY column or a DEFAULT AUTOINCREMENT column, or zero if the most recent insert was into a table that did not contain an IDENTITY or DEFAULT AUTOINCREMENT column. 
  * @return integer Last insert ID.
  */
 public function lastInsertId()
 {
     return sasql_insert_id($this->connection);
 }
示例#2
0
 /**
  * Insert ID
  *
  * @access	public
  * @return	integer
  */
 function insert_id()
 {
     return @sasql_insert_id($this->conn_id);
 }
示例#3
0
 /**
  * {@inheritdoc}
  */
 public function lastInsertId($name = null)
 {
     if (null === $name) {
         return sasql_insert_id($this->connection);
     }
     return $this->query('SELECT ' . $name . '.CURRVAL')->fetchColumn();
 }
示例#4
0
 protected function get_new_id()
 {
     return sasql_insert_id($this->connection);
 }
示例#5
0
 /**
  * Fetch the insert id generated by the most recent insert statement
  */
 function db_insert_id()
 {
     return sasql_insert_id($this->_dbh);
 }