Skip to content

andykant/active-database

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 

Repository files navigation

About

ADb is a relational database system implemented in JavaScript. ADb's implementation is based on the ActiveRecord design pattern.

Information

Credits

Notes

  • ADb is not a transactional database system. This is primarily because there isn't a reasonable way to clone objects while maintaining their original context. Due to this, assume that changes made to a row have the potential be applied to the database immediately. However, always call the $save method on the row to ensure that the database is updated.
  • ADb is a relational database system, but the relations are not enforced.
  • It is not recommended to export tables with functions, textnodes, or elements because those objects cannot be exported. Likewise, any objects containing any of these datatypes will probably not export properly either. These datatypes will be exported as 'null' instead with the exception of functions used as default value generators.
  • Primary keys are limited to a single column with one of the following datatypes: number, string, auto (auto-incremented number).
  • Foreign key references in a table declaration should create a ADb.$ref object if the foreign key's table has not been initialized yet. ADb.$ref will ensure that the table has been initialized, and will then return the first matching entry.
  • Columns of the datatype 'auto' should be passed 'null' when creating new rows.
  • Any method or property marked as DESTRUCTIVE might cause unintentional results. Destructive methods might change the structure or data of a database or table. Changing the value for a destructive property might prevent the database from working correctly.
  • Error messages are only enabled when ADb.$debug is set to 'true'. Error messages will be passed to Firebug if it is available.

About

Active Database (ADb) is a relational database system implemented in JavaScript. ADb's implementation is based on the ActiveRecord design pattern.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published