Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
doctrine-dbal
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Tomáš Trávníček
doctrine-dbal
Commits
d80b9596
Commit
d80b9596
authored
May 28, 2009
by
romanb
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[2.0] Formatting issues.
parent
f0132066
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
39 additions
and
39 deletions
+39
-39
Connection.php
lib/Doctrine/DBAL/Connection.php
+39
-39
No files found.
lib/Doctrine/DBAL/Connection.php
View file @
d80b9596
...
...
@@ -661,48 +661,48 @@ class Connection
* @param string $table Name of the table into which a new row was inserted.
* @param string $field Name of the field into which a new row was inserted.
*/
public
function
lastInsertId
(
$seqName
=
null
)
{
$this
->
connect
();
return
$this
->
_conn
->
lastInsertId
(
$seqName
);
}
public
function
lastInsertId
(
$seqName
=
null
)
{
$this
->
connect
();
return
$this
->
_conn
->
lastInsertId
(
$seqName
);
}
/**
* Start a transaction or set a savepoint.
*
* if trying to set a savepoint and there is no active transaction
* a new transaction is being started.
*
* @return boolean
*/
public
function
beginTransaction
()
{
$this
->
connect
();
if
(
$this
->
_transactionNestingLevel
==
0
)
{
$this
->
_conn
->
beginTransaction
();
}
++
$this
->
_transactionNestingLevel
;
return
true
;
}
/**
* Start a transaction or set a savepoint.
*
* if trying to set a savepoint and there is no active transaction
* a new transaction is being started.
*
* @return boolean
*/
public
function
beginTransaction
()
{
$this
->
connect
();
if
(
$this
->
_transactionNestingLevel
==
0
)
{
$this
->
_conn
->
beginTransaction
();
}
++
$this
->
_transactionNestingLevel
;
return
true
;
}
/**
* Commits the database changes done during a transaction that is in
* progress or release a savepoint. This function may only be called when
* auto-committing is disabled, otherwise it will fail.
*
* @return boolean FALSE if commit couldn't be performed, TRUE otherwise
*/
public
function
commit
()
{
if
(
$this
->
_transactionNestingLevel
==
0
)
{
throw
ConnectionException
::
commitFailedNoActiveTransaction
();
}
/**
* Commits the database changes done during a transaction that is in
* progress or release a savepoint. This function may only be called when
* auto-committing is disabled, otherwise it will fail.
*
* @return boolean FALSE if commit couldn't be performed, TRUE otherwise
*/
public
function
commit
()
{
if
(
$this
->
_transactionNestingLevel
==
0
)
{
throw
ConnectionException
::
commitFailedNoActiveTransaction
();
}
$this
->
connect
();
$this
->
connect
();
if
(
$this
->
_transactionNestingLevel
==
1
)
{
$this
->
_conn
->
commit
();
}
if
(
$this
->
_transactionNestingLevel
==
1
)
{
$this
->
_conn
->
commit
();
}
--
$this
->
_transactionNestingLevel
;
return
true
;
...
...
@@ -722,7 +722,7 @@ class Connection
* @return boolean FALSE if rollback couldn't be performed, TRUE otherwise.
*/
public
function
rollback
()
{
{
if
(
$this
->
_transactionNestingLevel
==
0
)
{
throw
ConnectionException
::
rollbackFailedNoActiveTransaction
();
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment