summaryrefslogtreecommitdiff
path: root/idiorm.php
diff options
context:
space:
mode:
authorJamie Matthews <[email protected]>2010-10-25 18:37:37 +0100
committerJamie Matthews <[email protected]>2010-10-25 18:37:37 +0100
commite305fcaf7446818c7ddd498ca950b0d4fd595570 (patch)
tree27ef929f816de92599bdec1e26676d90fef1f5f7 /idiorm.php
parent31558e93f67c17b715741f395699fc902d9bd552 (diff)
Add inner, left outer, right outer, full outer joins
Diffstat (limited to 'idiorm.php')
-rw-r--r--idiorm.php28
1 files changed, 28 insertions, 0 deletions
diff --git a/idiorm.php b/idiorm.php
index ca1adfc..4ac01f8 100644
--- a/idiorm.php
+++ b/idiorm.php
@@ -449,6 +449,34 @@
}
/**
+ * Add an INNER JOIN souce to the query
+ */
+ public function inner_join($table, $constraint, $table_alias=null) {
+ return $this->_add_join_source("INNER", $table, $constraint, $table_alias);
+ }
+
+ /**
+ * Add a LEFT OUTER JOIN souce to the query
+ */
+ public function left_outer_join($table, $constraint, $table_alias=null) {
+ return $this->_add_join_source("LEFT OUTER", $table, $constraint, $table_alias);
+ }
+
+ /**
+ * Add an RIGHT OUTER JOIN souce to the query
+ */
+ public function right_outer_join($table, $constraint, $table_alias=null) {
+ return $this->_add_join_source("RIGHT OUTER", $table, $constraint, $table_alias);
+ }
+
+ /**
+ * Add an FULL OUTER JOIN souce to the query
+ */
+ public function full_outer_join($table, $constraint, $table_alias=null) {
+ return $this->_add_join_source("FULL OUTER", $table, $constraint, $table_alias);
+ }
+
+ /**
* Internal method to add a WHERE condition to the query
*/
protected function _add_where($fragment, $values) {