ILIAS  release_5-1 Revision 5.0.0-5477-g43f3e3fab5f
class.arSelect.php
Go to the documentation of this file.
1<?php
2require_once(dirname(__FILE__) . '/../Statement/class.arStatement.php');
3
11class arSelect extends arStatement {
12
16 protected $table_name = '';
20 protected $as = '';
24 protected $field_name = '';
25
26
32 public function asSQLStatement(ActiveRecord $ar) {
33 $return = '';
34 if ($this->getTableName()) {
35 $return .= $this->getTableName() . '.';
36 }
37 $return .= $this->getFieldName();
38 if ($this->getAs() AND $this->getFieldName() != '*') {
39 $return .= ' AS ' . $this->getAs();
40 }
41
42 return $return;
43 }
44
45
49 public function getTableName() {
50 return $this->table_name;
51 }
52
53
57 public function setTableName($table_name) {
58 $this->table_name = $table_name;
59 }
60
61
65 public function getAs() {
66 return $this->as;
67 }
68
69
73 public function setAs($as) {
74 $this->as = $as;
75 }
76
77
81 public function getFieldName() {
82 return $this->field_name;
83 }
84
85
89 public function setFieldName($field_name) {
90 $this->field_name = $field_name;
91 }
92}
93
94?>
Class ActiveRecord.
Class arSelect.
setFieldName($field_name)
asSQLStatement(ActiveRecord $ar)
setTableName($table_name)
Class arStatement.