Tag Link | [Database_CreateTable] | Category | Database |
---|---|---|---|
Type | Process | Source Available | Yes |
Support | Preferred | Version | 5.0 |
Change | Unchanged | Data Source | Lasso MySQL |
Output Type | None | Security | Tag |
Implementation | LDML | Sets | Lasso 8.5, Lasso 8.0, Lasso 7.0, Lasso 6.0, Lasso 5.0 |
[Database_CreateTable] creates a new table in an existing MySQL database. By calling the [Database_CreateTable] tag and a series of [Database_CreateField] tags a new table can be created entirely in LassoScript.
This tag is certified to work with Lasso MySQL and MySQL data sources. It may also work with third party data sources that support the
This tag requires a
The
The table is automatically created with a single field named ID. The field is set to be a primary key field and to auto
The optional
[Database_CreateTable:
[Database_CreateTable:
Required Parameters | |
---|---|
-Database | The name of the database to which the table should be added. |
-Table | The name of the table which should be added to the specified database. |
Optional Parameters | |
-Temporary | If specified, the created table will be temporary. |
To create a new Lasso MySQL Table:
Use the [Database_CreateTable] tag. The following code creates a new table in the Site database named MyPreferences.
[Database_CreateTable: