From 445694a64adaf1ee917cdb10fac06c767d333565 Mon Sep 17 00:00:00 2001 From: Derek Allard Date: Thu, 31 Jan 2008 23:43:58 +0000 Subject: typo fix, $this->Db to $this->db --- user_guide/database/active_record.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'user_guide/database/active_record.html') diff --git a/user_guide/database/active_record.html b/user_guide/database/active_record.html index 427389680..5425f013a 100644 --- a/user_guide/database/active_record.html +++ b/user_guide/database/active_record.html @@ -139,7 +139,7 @@ $query = $this->db->get('mytable');
// Produces: SELECT title, content, date FROM mytable

Note: If you are selecting all (*) from a table you do not need to use this function. When omitted, CodeIgniter assumes you wish to SELECT *

-

$this->Db->select() accepts an optional second parameter. If you set it to FALSE, CodeIgniter will not try to protect your field or table names with backticks. This is useful if you need a compound select statement.

+

$this->db->select() accepts an optional second parameter. If you set it to FALSE, CodeIgniter will not try to protect your field or table names with backticks. This is useful if you need a compound select statement.

$this->db->select('(SELECT SUM(payments.amount) FROM payments WHERE payments.invoice_id=4') AS amount_paid', FALSE);
$query = $this->db->get('mytable');

-- cgit v1.2.3-24-g4f1b