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
6b86c9fa
Commit
6b86c9fa
authored
May 24, 2007
by
zYne
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
--no commit message
--no commit message
parent
b4bcc51c
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
6 deletions
+18
-6
Hydrate.php
lib/Doctrine/Hydrate.php
+16
-4
Query.php
lib/Doctrine/Query.php
+1
-1
RawSql.php
lib/Doctrine/RawSql.php
+1
-1
No files found.
lib/Doctrine/Hydrate.php
View file @
6b86c9fa
...
...
@@ -162,12 +162,24 @@ class Doctrine_Hydrate
return
$alias
;
}
public
function
hasAlias
(
$tableName
)
/**
* hasTableAlias
* whether or not this object has given tableAlias
*
* @param string $tableAlias the table alias to be checked
* @return boolean true if this object has given alias, otherwise false
*/
public
function
hasTableAlias
(
$tableAlias
)
{
return
(
isset
(
$this
->
_tableAliases
[
$table
Name
]));
return
(
isset
(
$this
->
_tableAliases
[
$table
Alias
]));
}
/**
* getComponentAlias
* get component alias associated with given table alias
*
* @param string $tableAlias the table alias that identifies the component alias
* @return string component alias
*/
public
function
getComponentAlias
(
$tableAlias
)
{
if
(
!
isset
(
$this
->
_tableAliases
[
$tableAlias
]))
{
...
...
lib/Doctrine/Query.php
View file @
6b86c9fa
...
...
@@ -755,7 +755,7 @@ class Doctrine_Query extends Doctrine_Query_Abstract implements Countable
continue
;
}
if
(
$this
->
hasAlias
(
$part
))
{
if
(
$this
->
has
Table
Alias
(
$part
))
{
$parts
[
$k
]
=
$this
->
generateNewTableAlias
(
$part
);
}
...
...
lib/Doctrine/RawSql.php
View file @
6b86c9fa
...
...
@@ -135,7 +135,7 @@ class Doctrine_RawSql extends Doctrine_Query_Abstract
throw
new
Doctrine_RawSql_Exception
(
'All selected fields in Sql query must be in format tableAlias.fieldName'
);
}
// try to auto-add component
if
(
!
$this
->
hasAlias
(
$e
[
0
]))
{
if
(
!
$this
->
has
Table
Alias
(
$e
[
0
]))
{
try
{
$this
->
addComponent
(
$e
[
0
],
ucwords
(
$e
[
0
]));
}
catch
(
Doctrine_Exception
$exception
)
{
...
...
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