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
a81e1d76
Commit
a81e1d76
authored
Dec 15, 2006
by
zYne
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
added leftJoin and innerJoin methods
parent
e33bd03a
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
4 deletions
+24
-4
Query.php
lib/Doctrine/Query.php
+24
-4
No files found.
lib/Doctrine/Query.php
View file @
a81e1d76
...
...
@@ -273,9 +273,9 @@ class Doctrine_Query extends Doctrine_Hydrate implements Countable {
foreach
(
$names
as
$name
)
{
if
(
$count
==
0
)
{
$this
->
parts
[
"select"
][]
=
$tablename
.
'.'
.
$name
;
$this
->
parts
[
'select'
][]
=
$tablename
.
'.'
.
$name
;
}
else
{
$this
->
parts
[
"select"
][]
=
$tablename
.
'.'
.
$name
.
' AS '
.
$tablename
.
'__'
.
$name
;
$this
->
parts
[
'select'
][]
=
$tablename
.
'.'
.
$name
.
' AS '
.
$tablename
.
'__'
.
$name
;
}
}
}
...
...
@@ -285,10 +285,30 @@ class Doctrine_Query extends Doctrine_Hydrate implements Countable {
* @param strint $from
*/
public
function
addFrom
(
$from
)
{
$class
=
"Doctrine_Query_From"
;
$class
=
'Doctrine_Query_From'
;
$parser
=
new
$class
(
$this
);
$parser
->
parse
(
$from
);
}
/**
* leftJoin
*
* @param strint $join
*/
public
function
leftJoin
(
$join
)
{
$class
=
'Doctrine_Query_From'
;
$parser
=
new
$class
(
$this
);
$parser
->
parse
(
'LEFT JOIN '
.
$join
);
}
/**
* innerJoin
*
* @param strint $join
*/
public
function
innerJoin
(
$join
)
{
$class
=
'Doctrine_Query_From'
;
$parser
=
new
$class
(
$this
);
$parser
->
parse
(
'INNER JOIN '
.
$join
);
}
/**
* addWhere
*
...
...
@@ -296,7 +316,7 @@ class Doctrine_Query extends Doctrine_Hydrate implements Countable {
* @param mixed $params
*/
public
function
addWhere
(
$where
,
$params
=
array
())
{
$class
=
"Doctrine_Query_Where"
;
$class
=
'Doctrine_Query_Where'
;
$parser
=
new
$class
(
$this
);
$this
->
parts
[
'where'
][]
=
$parser
->
parse
(
$where
);
...
...
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