summaryrefslogtreecommitdiffstats
path: root/user_guide/database/forge.html
diff options
context:
space:
mode:
authorTimothy Warren <tim@timshomepage.net>2011-09-23 16:28:13 +0200
committerTimothy Warren <tim@timshomepage.net>2011-09-23 16:28:13 +0200
commit4d292bdb56ba6afc26878d9bcd82892f48d9f1a4 (patch)
treea894323d2e896adcb7d25d7d1edb806295147384 /user_guide/database/forge.html
parent5fc36d8c9dc0bd5d41ed7dea36f999c6e07e1615 (diff)
parentd26133be24eef68b1bead61e7e808f4424a71a0a (diff)
Merge branch 'develop' of git://github.com/EllisLab/CodeIgniter into develop
Diffstat (limited to 'user_guide/database/forge.html')
-rw-r--r--user_guide/database/forge.html4
1 files changed, 4 insertions, 0 deletions
diff --git a/user_guide/database/forge.html b/user_guide/database/forge.html
index 6b8709892..528d1a24c 100644
--- a/user_guide/database/forge.html
+++ b/user_guide/database/forge.html
@@ -201,6 +201,10 @@ already be running, since the forge class relies on it.</p>
$this-&gt;dbforge-&gt;add_column('table_name', $fields);<br />
<br />
// gives ALTER TABLE table_name ADD preferences TEXT</code></p>
+<p>An optional third parameter can be used to specify which existing column to add the new column after.</p>
+<p><code>
+$this-&gt;dbforge-&gt;add_column('table_name', $fields, 'after_field');
+</code></p>
<h2>$this-&gt;dbforge-&gt;drop_column()</h2>
<p>Used to remove a column from a table. </p>
<p><code>$this-&gt;dbforge-&gt;drop_column('table_name', 'column_to_drop');</code></p>