My favorites | Sign in
Project Home Downloads Wiki Issues Source
Search
for
UsingTriangulum  
Top level programmer documentation page
Updated Feb 5, 2011 by KenDown...@gmail.com

Previous: SystemRequirements

Next: UsageDetails

Introduction

A development iteration using Triangulum follows these three steps:

  1. Edit your data schema, your .dd.yaml file
  2. Run the Triangulum database builder
  3. Create any specific application code that may be required

This basic cycle extends to teams as well. When a code set is advanced to QA, Staging, or Production, the Triangulum database builder is run at the same time the code is deployed.

Basics of Making a Dictionary File

When using Triangulum, your database is described in one or more text files in the YAML format. The Triangulum builder resolves all dependencies and generates a SQL upgrade script for you.

The simplest Triangulum database spec contains at least one module, which contains at least one table, which contains at least one column:

main:
  customers:
    customername:
      type: char(30)

If this spec were saved in file "/path/to/simplest.dd.yaml", you could turn it into a SQL build script by typing:

$ php triMain.php \ 
      yaml=/path/to/simplest.dd.yaml \
      db-host=localhost  \
      db-name=simplest   \
      db-user=postgres   \ 
      db-passwd=*****    

This will create a database "simplest" (if it does not already exist) on the localhost, and add the single table with its single column.

If you then edit the simplest.dd.yaml file to add more tables and columns, and re-run the command above, Triangulum will add the new tables and columns to the database.

Previous: SystemRequirements

Next: UsageDetails


Sign in to add a comment
Powered by Google Project Hosting