Introduction SynApp2 quickly transform your database design into a useful web application Organized, accurate data forms a foundation you can build upon to realize value Audience Anyone who works with data, from simple lists to sophisticated corporate data repositories Novice to seasoned professional developers and everyone in between An excellent platform for learning and teaching database design and application development Applicability Single database web enabled applications for use within your business, school, organization, government agency, or for the World Wide Web Benefits A short straight line between now and valuable productivity for you and your clients An effective alternative to spreadsheets for collection, organization and maintenance of data Helps you to focus on addressing your business problem rather than implementation details Rapidly prototype, test and refine your data models Solid, usable applications without coding ( CRUD / BREAD ) Low support overhead Do more with fewer details manage Key Points Database/schema driven Push button application development Simple, file copy deployment Comprehensive user and data validation Paginated search and browse Tabular PDF reports with statistics One-click export/download of reports to spreadsheet programs Consistent, easy to use applications Valuable results in almost no time Free and Open Source Software Further Points Convenience of web based user interface Highly customizable Minimal effort to incorporate process and/or database model changes Compatible with the environment and tools you use with your databases Generates standards compliant (X)HTML and CSS Simple, straightforward and open - use and modify as needed Concepts High value vs. low effort MVC framework - designed specifically for automated RAD Ideal for Agile development process methodology Time is money Keep focus on your business problem, not implementation and support details Useful tool for learning about database design The whole point of the thing is how much you can get done with how little effort Technical W3C standards compliant browser (FF 1.5+, IE 6+, Safari4+, Chrome, Opera, others) JavaScript/DOM (as supported by browser) AJAX data exchange layer Model View Controller architecture ( MVC framework ) Apache, Microsoft IIS MySQL 4+, Oracle 10g (Express Edition) PHP 4.1+ (w/Oracle PHP5+) Windows/Linux/Unix/Mac/iPhone/iPad/iPod Touch/Sun/LAMP/MAMP/WAMP/XAMPP one database per application, many applications per database custom user authentication per synapp2, direct, database/application, or enterprise-wide custom lookups, triggers, defaults, procedures, filters, sorting, macros, queries, statistics display/print/download/save/email tabular PDF reports flexible data import/export Installation synapp2.install.MySQL.txt synapp2.install.Oracle.txt Establish your database design Analyze your business problem Describe necessary data elements in terms of tables and fields Consider how people, processes and data/information flow and fit together Normalize your table relationships (1 to many, many to many) Iterate over these steps until you have a solution Create the database definition Use a suitable database admin tool - phpMyAdmin, MySQL Workbench/Administrator, etc. Follow SynApp2 Conventions primary key (PK) = 'id' foreign key (FK) = 'id_' Field Comment = form field/table column legend, Field Comment = 'init=function_name()' or 'auto=function_name()', Field Comment = 'min=x' and/or 'max=y', Field Comment = 'ON_EMPTY_VALUE_SET_DEFAULT', update TIMESTAMP - NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP insert TIMESTAMP - timestamp NOT NULL default '0000-00-00 00:00:00' required fields - NOT NULL Consider order of (FK) appearance in the table definition impacts multi-path table navigation FK is automatically expanded to first non-FK value in parent table lookup table vs enum or set data values, for identically named fields, are automatically initialized/copied to a new record child from the parent Requirements All primary and foreign key fields must be numeric (e.g. int(10) or number(10,0)) All primary key values must be automatically assigned (i.e. auto_increment or sequence/trigger) If comment is used, data before first comma is the field display name (i.e. legend) Use a leading comma in comment to provide behavioral customization and have the field name as the legend Generate your application Login to SynApp2 Click the PageGen navigation tab Enter the name of your database - e.g. 'AppID (or database): ' - hit ENTER or click the green checkmark icon Select a 'Basis Table' from the list (of your tables in the database) - i.e. 'QueryID (or table):' Click Run PageGen to generate 1 page of your web app - a link to the page appears Repeat the table select and generate steps for each table in your database Click the link to the last page you generated - the page appears with navigation tabs for the other pages Use the application to work with your data Use appropriate pages to add records to tables in sensible order - i.e. parent record first, then child/children. Establish records in any supporting 'lookup' tables first Enter records into more 'significant' tables as appropriate - you're off and running Use efficient keyboard shortcuts Navigate to the 'Reports' page Click on the secondary links to produce tabular listings of the records in your tables Customization Use the KeyMap page to designate foreign key fields that do not conform to SynApp2 (FK) naming conventions Use the Options page to manage column display options such as: COL_OMIT, COL_SIZE, COL_ALIGN, COL_FORMAT, COL_EDITOR Manage access to app, page, report, query, process, menu/page navigation tab, and CRUD functions by username Define and manage custom processing FK expansion Sort order Filter elements in select/lookup lists Omit fields from forms, tables or reports Include extra fields on forms, tables, or reports Compute and display statistics Specify initial/default values with constants or procedures Override SQL generator Validate data with simple min/max limits and/or two-phase custom validation functions Table pagination Display server response XML by adding a search string to the URL for SynApp2 pages - e.g. 'http:////.htm?show_response=1 read the SynApp2 Customization document Look at functions in _shared_/custom.php for clues about customizing behavior using a custom.inc.php file in your app directory Copyright (c) 2007 - 2010 Richard Howell. All rights reserved. http://www.synapp2.org $Id: synapp2.txt,v 1.8 2010/07/13 20:58:49 richard Exp $