Fix returning check for Postgres.
This commit is contained in:
parent
c878a18fdb
commit
d1ae2324fd
|
@ -197,7 +197,7 @@ public function query($sql, $bindings = array())
|
|||
// For insert statements that use the "returning" clause, which is allowed
|
||||
// by database systems such as Postgres, we need to actually return the
|
||||
// real query result so the consumer can get the ID.
|
||||
elseif (stripos($sql, 'insert') === 0 and stripos($sql, 'returning') !== false)
|
||||
elseif (stripos($sql, 'insert') === 0 and stripos($sql, ') returning') !== false)
|
||||
{
|
||||
return $this->fetch($statement, Config::get('database.fetch'));
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue