Proposal for "Database_dbQuery"

» Metadata » Status
  • Status: Proposed
» Description

With this library you can update multiple interrelated tables at the same time without writing separated SQL statements.

The following examples updates (or eventually inserts) a record in the table 'content' and the tables 'image', 'video' and 'file' at the same time:

<?php
// connects to the database
$db = new DbConnector("database", "username", "password");

// updates the record "content.id = 101"
$t = new DbTable($db, "content", 101);
$t->set("description", "Record description...");
$t->set("image.path", "/path/to/image.jpg");
$t->set("video.path", "/path/to/video.mp4");
$t->set("file.path", "/path/to/file.pdf");
$t->update();
?>
» Dependencies » Links
» Timeline » Changelog
  • First Draft: 2014-11-09
  • Proposal: 2014-11-09
  • Call for Votes: 1970-01-01
  • Voting Extended: 1970-01-01