diff options
author | Derek Allard <derek.allard@ellislab.com> | 2008-01-02 22:51:31 +0100 |
---|---|---|
committer | Derek Allard <derek.allard@ellislab.com> | 2008-01-02 22:51:31 +0100 |
commit | 032a5c0b61746e1dd82e400ad8ac639f92d3788c (patch) | |
tree | 0918ff50fa13058a88a5916c6e26a9c3bfeb420e /user_guide/database | |
parent | a0fa90b1bbb61d47bcc9bc95d983e66dfc8732dd (diff) |
Documented distinct() in Active Record.
Diffstat (limited to 'user_guide/database')
-rw-r--r-- | user_guide/database/active_record.html | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/user_guide/database/active_record.html b/user_guide/database/active_record.html index e7c823fde..d43101642 100644 --- a/user_guide/database/active_record.html +++ b/user_guide/database/active_record.html @@ -370,8 +370,15 @@ $this->db->or_not_like('body', 'match'); <br /> <br />
<br />// Produces: GROUP BY title, date</code>
-
<p class="important">Note: group_by() was formerly known as groupby(), which has been deprecated. </p>
+
+<h2> $this->db->distinct();<br />
+</h2>
+<p>Adds the "DISTINCT" keyword to to a query</p>
+<p><code>$this->db->distinct();<br />
+ $this->db->get('table');<br />
+ <br />
+ // Produces: SELECT DISTINCT * FROM table</code></p>
<h2>$this->db->having();</h2>
<p>Permits you to write the HAVING portion of your query:</p>
|