summaryrefslogtreecommitdiffstats
path: root/user_guide/database/fields.html
diff options
context:
space:
mode:
authoradmin <devnull@localhost>2006-09-30 21:24:45 +0200
committeradmin <devnull@localhost>2006-09-30 21:24:45 +0200
commit3dd978f680076be842bfcb5c9e2cbf35b926373b (patch)
treee4cd05724744ee70eb497118692581e750539548 /user_guide/database/fields.html
parent3ed8c51254a5b26d951fa675802fcf69adf9638e (diff)
Diffstat (limited to 'user_guide/database/fields.html')
-rw-r--r--user_guide/database/fields.html16
1 files changed, 5 insertions, 11 deletions
diff --git a/user_guide/database/fields.html b/user_guide/database/fields.html
index 5c872eca9..260cd222f 100644
--- a/user_guide/database/fields.html
+++ b/user_guide/database/fields.html
@@ -65,17 +65,14 @@ Field Names
<h1>Field Data</h1>
-<h2>Retrieving Field Names</h2>
-<p>Sometimes it's helpful to gather the field names for a particular table or with a paritcular query result.</p>
-
-<h2>$this->db->field_names();</h2>
+<h2>$this->db->list_fields();</h2>
<p>Returns an array containing the field names. This query can be called two ways:</p>
<p>1. You can supply the table name and call it from the <dfn>$this->db-></dfn> object:</p>
<code>
-$fields = $this->db->field_names('table_name');<br /><br />
+$fields = $this->db->list_fields('table_name');<br /><br />
foreach ($fields as $field)<br />
{<br />
@@ -90,7 +87,7 @@ from your query result object:</p>
$query = $this->db->query('SELECT * FROM some_table');
<br /><br />
-foreach ($query->field_names() as $field)<br />
+foreach ($query->list_fields() as $field)<br />
{<br />
&nbsp;&nbsp;&nbsp;echo $field;<br />
}
@@ -98,13 +95,10 @@ foreach ($query->field_names() as $field)<br />
-
-
-<h2>Retrieving Field MetaData</h2>
-<p>Sometimes it's helpful to gather the field names or other metadata, like the column type, max length, etc.</p>
-
<h2>$this->db->field_data();</h2>
<p>Returns an array of objects containing field information.</p>
+<p>Sometimes it's helpful to gather the field names or other metadata, like the column type, max length, etc.</p>
+
<p class="important">Note: Not all databases provide meta-data.</p>