You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/3. Active Table.md
+4-4
Original file line number
Diff line number
Diff line change
@@ -25,13 +25,13 @@ You can add an AND or OR clause to the condition easily:
25
25
```php
26
26
$condition->and('firstName', 'Barney');
27
27
```
28
-
The above will produce `'lastName' = ? AND 'firstName' = ?`
28
+
The above will produce the PDO equivalent of `lastName = 'Rubble' AND firstName = 'Barney'`
29
29
30
30
You can also OR in a condition like:
31
31
```php
32
32
$condition->or('firstName', 'Fred');
33
33
```
34
-
The above will now produce `'lastName' = ? AND 'firstName' = ? OR 'firstName' = ?`
34
+
The above will now produce the PDO equivalent of `lastName = 'Rubble' AND firstName = 'Barney' OR firstName = 'Fred'`
35
35
36
36
You can parenthesize a condition by adding to another condition:
37
37
```php
@@ -43,7 +43,7 @@ $condition = new \PHPFUI\ORM\Condition();
43
43
$condition->or($conditionA);
44
44
$condition->or($conditionB);
45
45
```
46
-
The above will produce '('lastName' = ? AND 'firstName' = ?) OR ('lastName' = ? AND 'firstName' = ?)'
46
+
The above will produce the PDO equivalent of '(lastName = 'Rubble' AND firstName = 'Barney') OR (lastName = 'Flintstone' AND firstName = 'Fred')'
47
47
48
48
#### Other operators
49
49
You can also make conditions with the following operators as the third parameter to [\PHPFUI\ORM\Condition](http://phpfui.com/?n=PHPFUI%5CORM&c=Condition):
@@ -70,7 +70,7 @@ $condition = new \PHPFUI\ORM\Condition();
70
70
$condition->or($conditionA);
71
71
$condition->or($conditionB);
72
72
```
73
-
The above will produce `('lastName' >= ? AND 'lastName' < ?) OR ('lastName' >= ? AND 'lastName' < ?)`
73
+
The above will produce the PDO equivalent of `(lastName >= 'R' AND lastName < 'S') OR (lastName >= 'F' AND lastName < 'G')`
74
74
75
75
The [In](http://phpfui.com/?n=PHPFUI\ORM\Operator&c=In) and [NotIn](http://phpfui.com/?n=PHPFUI\ORM\Operator&c=NotIn) operators require the second parameter to [Condition](http://phpfui.com/?n=PHPFUI\ORM&c=Condition). The [Like](http://phpfui.com/?n=PHPFUI\ORM\Operator&c=Like) and [NotLike](http://phpfui.com/?n=PHPFUI\ORM\Operator&c=NotLike) operators will respect the % and _ characters, but you are responsible for putting them in the correct positions.
Copy file name to clipboardExpand all lines: docs/4. Cursors.md
+1-1
Original file line number
Diff line number
Diff line change
@@ -24,7 +24,7 @@ foreach ($customerTable->getArrayCursor() as $row)
24
24
}
25
25
```
26
26
### DataObjectCursor
27
-
A **DataObjectCursor** returns a **DataObject** that uses object notation to access fields. It does not have any settable properties or methods associated with it. It also implements [ArrayAccess](https://www.php.net/manual/en/class.arrayaccess.php), but is not an array. It also implements related
27
+
A **DataObjectCursor** returns a **DataObject** that uses object notation to access fields. It does not have any settable properties or methods associated with it. It implements [ArrayAccess](https://www.php.net/manual/en/class.arrayaccess.php), but is not an array. It also can return related records on valid fields.
Copy file name to clipboardExpand all lines: docs/7. Validation.md
+1-1
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,7 @@
1
1
# PHPFUI\ORM Validation
2
2
*__Note__: Referenced namespaces in this document refer to the **PHPFUI\ORM** defaults.*
3
3
4
-
Validator is an abstract class for Record validation See [\App\Record\Validation](/System/sayaPhpDocumentation?n=App%5CRecord%5CValidation) namespace for examples.
4
+
Validator is an abstract class for Record validation See [\PHPFUI\ORM\Validator](http://phpfui.com/?n=PHPFUI%5CORM&c=Validator) namespace for examples.
5
5
6
6
Individual validators are listed in the table below. Validators can be combined. For example, a field can be **required**, and have a **minlength** and **maxlength**. Validators can have parameters. Parameters are separated by a colon (:) and then commas for each separate parameter.
0 commit comments