Permalink
Browse files

Fix indentation and useless blank line

  • Loading branch information...
1 parent aeeb66d commit 2e74a912bb7b649547c036d1176a615f61a415b0 @ddalmais ddalmais committed Mar 19, 2012
View
14 runtime/lib/adapter/DBAdapter.php
@@ -582,13 +582,13 @@ public function bindValue(PDOStatement $stmt, $parameter, $value, ColumnMap $cMa
}
/**
- * Do Explain Plan for query object or query string
- *
- * @param PropelPDO $con propel connection
- * @param ModelCriteria|string $query query the criteria or the query string
- * @throws PropelException if explain plan is not implemented for adapter
- * @return PDOStatement A PDO statement executed using the connection, ready to be fetched
- */
+ * Do Explain Plan for query object or query string
+ *
+ * @param PropelPDO $con propel connection
+ * @param ModelCriteria|string $query query the criteria or the query string
+ * @throws PropelException if explain plan is not implemented for adapter
+ * @return PDOStatement A PDO statement executed using the connection, ready to be fetched
+ */
public function doExplainPlan(PropelPDO $con, $query)
{
throw new PropelException("Explain plan is not implemented for this adapter");
View
16 runtime/lib/adapter/DBMySQL.php
@@ -252,13 +252,13 @@ public function prepareParams($params)
}
/**
- * Do Explain Plan for query object or query string
- *
- * @param PropelPDO $con propel connection
- * @param ModelCriteria|string $query query the criteria or the query string
- * @throws PropelException
- * @return PDOStatement A PDO statement executed using the connection, ready to be fetched
- */
+ * Do Explain Plan for query object or query string
+ *
+ * @param PropelPDO $con propel connection
+ * @param ModelCriteria|string $query query the criteria or the query string
+ * @throws PropelException
+ * @return PDOStatement A PDO statement executed using the connection, ready to be fetched
+ */
public function doExplainPlan(PropelPDO $con, $query)
{
if ($query instanceof ModelCriteria) {
@@ -279,4 +279,4 @@ public function doExplainPlan(PropelPDO $con, $query)
$stmt->execute();
return $stmt;
}
-}
+}
View
14 runtime/lib/adapter/DBOracle.php
@@ -238,13 +238,13 @@ public function bindValue(PDOStatement $stmt, $parameter, $value, ColumnMap $cMa
}
/**
- * Do Explain Plan for query object or query string
- *
- * @param PropelPDO $con propel connection
- * @param ModelCriteria|string $query query the criteria or the query string
- * @throws PropelException
- * @return PDOStatement A PDO statement executed using the connection, ready to be fetched
- */
+ * Do Explain Plan for query object or query string
+ *
+ * @param PropelPDO $con propel connection
+ * @param ModelCriteria|string $query query the criteria or the query string
+ * @throws PropelException
+ * @return PDOStatement A PDO statement executed using the connection, ready to be fetched
+ */
public function doExplainPlan(PropelPDO $con, $query)
{
$con->beginTransaction();
View
14 runtime/lib/connection/PropelPDO.php
@@ -339,8 +339,8 @@ public function setAttribute($attribute, $value)
$this->cachePreparedStatements = $value;
break;
case self::PROPEL_ATTR_CONNECTION_NAME:
- $this->connectionName = $value;
- break;
+ $this->connectionName = $value;
+ break;
default:
parent::setAttribute($attribute, $value);
}
@@ -360,9 +360,9 @@ public function getAttribute($attribute)
case self::PROPEL_ATTR_CACHE_PREPARES:
return $this->cachePreparedStatements;
break;
- case self::PROPEL_ATTR_CONNECTION_NAME:
- return $this->connectionName;
- break;
+ case self::PROPEL_ATTR_CONNECTION_NAME:
+ return $this->connectionName;
+ break;
default:
return parent::getAttribute($attribute);
}
@@ -743,8 +743,8 @@ protected function getLogPrefix($methodName, $debugSnapshot)
break;
case 'connection':
- $value = $this->connectionName;
- break;
+ $value = $this->connectionName;
+ break;
default:
$value = 'n/a';
View
2 test/testsuite/runtime/adapter/DBOracleTest.php
@@ -78,7 +78,5 @@ public function testGetExplainPlanQuery()
$db = new DBOracle();
$explainQuery = $db->getExplainPlanQuery('SELECT B.* FROM (SELECT A.*, rownum AS PROPEL_ROWNUM FROM (SELECT book.ID AS ORA_COL_ALIAS_0, book.TITLE AS ORA_COL_ALIAS_1, book.ISBN AS ORA_COL_ALIAS_2, book.PRICE AS ORA_COL_ALIAS_3, book.PUBLISHER_ID AS ORA_COL_ALIAS_4, book.AUTHOR_ID AS ORA_COL_ALIAS_5, author.ID AS ORA_COL_ALIAS_6, author.FIRST_NAME AS ORA_COL_ALIAS_7, author.LAST_NAME AS ORA_COL_ALIAS_8, author.EMAIL AS ORA_COL_ALIAS_9, author.AGE AS ORA_COL_ALIAS_10, book.PRICE AS BOOK_PRICE FROM book, author) A ) B WHERE B.PROPEL_ROWNUM <= 1', 'iuyiuyiu');
$this->assertEquals('EXPLAIN PLAN SET STATEMENT_ID = \'iuyiuyiu\' FOR SELECT B.* FROM (SELECT A.*, rownum AS PROPEL_ROWNUM FROM (SELECT book.ID AS ORA_COL_ALIAS_0, book.TITLE AS ORA_COL_ALIAS_1, book.ISBN AS ORA_COL_ALIAS_2, book.PRICE AS ORA_COL_ALIAS_3, book.PUBLISHER_ID AS ORA_COL_ALIAS_4, book.AUTHOR_ID AS ORA_COL_ALIAS_5, author.ID AS ORA_COL_ALIAS_6, author.FIRST_NAME AS ORA_COL_ALIAS_7, author.LAST_NAME AS ORA_COL_ALIAS_8, author.EMAIL AS ORA_COL_ALIAS_9, author.AGE AS ORA_COL_ALIAS_10, book.PRICE AS BOOK_PRICE FROM book, author) A ) B WHERE B.PROPEL_ROWNUM <= 1', $explainQuery, 'getExplainPlanQuery() returns a SQL Explain query');
-
}
-
}

0 comments on commit 2e74a91

Please sign in to comment.