Book Image

Mastering phpMyAdmin 2.11 for Effective MySQL Management

Book Image

Mastering phpMyAdmin 2.11 for Effective MySQL Management

Overview of this book

Table of Contents (25 chapters)
Mastering phpMyAdmin 2.11 for Effective MySQL Management
Credits
About the Author
About the Reviewers
Preface

Adding a Field


Suppose that we need a new field to store a book's language and, that by default, the books on which we keep data are written in English. We decide that the field will be called language and will contain a code composed of two characters (en by default).

In the Structure sub-page of the Table view for the book table, we can find the Add field dialog. Here, we specify how many new fields we want and where they will go.

The positions of the new fields in the table only matter from a developer's point of view; we usually group the fields logically so that we can find them more easily in the list of fields. The exact position of the fields will not play a role in the intended results (output from the queries), because these results can be adjusted regardless of the table structure. Usually, the most important fields (including the keys) are located at the beginning of the table, but this is a matter of personal preference.

We choose to put the new field At End of Table, so we check...