Note:

If you want to create a new page for developers, you should create it on the Moodle Developer Resource site.

Data manipulation API

From MoodleDocs
Revision as of 16:48, 13 August 2006 by Eloy Lafuente (stronk7) (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Starting with Moodle 1.7, an important change has been done to practically all the DB abstraction layer in order to improve the number of RDBMS supported by Moodle.

One of the basic points to achieve this improvement is to have a well-defined group of functions able to handle all the DB structure (DDL statements) using one neutral description, being able to execute the correct SQL statements required by each RDBMS. All these functions are used exclusively by the installation and upgrade processes.

In this page you'll see a complete list of such functions, with some explanations, tricks and examples of their use. If you are interested, it's also highly recommendable to take a look to the DML functions page where everything about how to handle DB data (select, insert, update, delete i.e. DML statements) is defined.

Of course, feel free to clarify, complete and add more info to all this documentation. It will be welcome, absolutely!

Main info

The functions

See also

  • DDL functions: Where all the functions used to handle DB objects (DDL) are defined.