Download the PHP package pinkcrab/table_builder without Composer

On this page you can find all versions of the php package pinkcrab/table_builder. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package table_builder

Table-Builder

A chainable table schema constructor with (WPDB) DB Delta builder built in.

Latest Stable Version Total Downloads Latest Unstable Version License PHP Version Require GitHub contributors GitHub issues

WordPress 5.9 Test Suite [PHP7.2-8.1] WordPress 6.0 Test Suite [PHP7.2-8.1] WordPress 6.1 Test Suite [PHP7.2-8.1]

codecov Scrutinizer Code Quality Maintainability

Related Pages
» Schema
» Column
» Index
» Foreign_Key

Why?

For those of you who have used dbDelta to create tables in WordPress, to say it's a bit fussy is an understatement.

The PinkCrab\Table_Builder module makes creating tables much easier by providing a more expressive fluent API to define the schema, which can be passed to the Builder to create the table.

Out of the box, this package comes with the DB_Delta builder engine only, but thanks to the SQL_Builder interface, engines for other table formats can be created easily.

Install

Defining a Table's Schema

You can define a table's schema in a few different ways.

See Schema Docs

Columns

The schema is defined from various columns, each column is defined as its own object with a collection of helper/shortcuts

Indexes and Foreign Keys

You can setup a variety of indexes and foreign keys for your table(s). These can be set as in the schema example above.

Index

You can create an index for any column of your table and denote the field as either unique, primary, full text, hash, or just a regular index.

The above would generate:

If you wish to use more than 1 column for an index, please add them as single indexes and the builder will combine. You must also set a custom keyname for all grouped indexes.

The above would generate the following for MySQL:

See INDEX docs

Foreign Key

Like regular indexes, foreign keys can be assigned to a table. When the table is built, it will assume the reference table exists, so ensure that you create them in the correct order if you are creating all tables at once.

The above would produce for MySQL (provided the user table exists with an ID column):

See Foreign Key docs

Creating & Dropping Tables

You can populate the builder with any engine. Included in this package is the DB_Delta_Engine engine, which internally uses the WordPress dbDelta function to create and drop tables.

Create

Drop

License

MIT License

http://www.opensource.org/licenses/mit-license.html

Change Log

Contributions

If you would like to contribute to this project, please feel to create an issue, then submit a PR.

Glynn Quelch
ZebulanStanphill


All versions of table_builder with dependencies

PHP Build Version
Package Version
Requires php Version >=7.2.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package pinkcrab/table_builder contains the following files

Loading the files please wait ....