Methods |
public
|
after(string $column): $this
Place the column "after" another column (MySQL)
Place the column "after" another column (MySQL)
|
#
|
public
|
always(): $this
Used as a modifier for generatedAs() (PostgreSQL)
Used as a modifier for generatedAs() (PostgreSQL)
|
#
|
public
|
autoIncrement(): $this
Set INTEGER columns as auto-increment (primary key)
Set INTEGER columns as auto-increment (primary key)
|
#
|
public
|
change(): $this
Change the column
|
#
|
public
|
charset(string $charset): $this
Specify a character set for the column (MySQL)
Specify a character set for the column (MySQL)
|
#
|
public
|
collation(string $collation): $this
Specify a collation for the column (MySQL/PostgreSQL/SQL Server)
Specify a collation for the column (MySQL/PostgreSQL/SQL Server)
|
#
|
public
|
comment(string $comment): $this
Add a comment to the column (MySQL/PostgreSQL)
Add a comment to the column (MySQL/PostgreSQL)
|
#
|
public
|
default(mixed $value): $this
Specify a "default" value for the column
Specify a "default" value for the column
|
#
|
public
|
first(): $this
Place the column "first" in the table (MySQL)
Place the column "first" in the table (MySQL)
|
#
|
public
|
from(int $startingValue): $this
Set the starting value of an auto-incrementing field (MySQL / PostgreSQL)
Set the starting value of an auto-incrementing field (MySQL / PostgreSQL)
|
#
|
public
|
generatedAs(string|Expression $expression = null): $this
Create a SQL compliant identity column (PostgreSQL)
Create a SQL compliant identity column (PostgreSQL)
|
#
|
public
|
index(string $indexName = null): $this
Add an index
|
#
|
public
|
invisible(): $this
Specify that the column should be invisible to "SELECT *" (MySQL)
Specify that the column should be invisible to "SELECT *" (MySQL)
|
#
|
public
|
nullable(bool $value = true): $this
Allow NULL values to be inserted into the column
Allow NULL values to be inserted into the column
|
#
|
public
|
persisted(): $this
Mark the computed generated column as persistent (SQL Server)
Mark the computed generated column as persistent (SQL Server)
|
#
|
public
|
primary(): $this
Add a primary index
|
#
|
public
|
fulltext(string $indexName = null): $this
Add a fulltext index
|
#
|
public
|
spatialIndex(string $indexName = null): $this
Add a spatial index
|
#
|
public
|
startingValue(int $startingValue): $this
Set the starting value of an auto-incrementing field (MySQL/PostgreSQL)
Set the starting value of an auto-incrementing field (MySQL/PostgreSQL)
|
#
|
public
|
storedAs(string $expression): $this
Create a stored generated column (MySQL/PostgreSQL/SQLite)
Create a stored generated column (MySQL/PostgreSQL/SQLite)
|
#
|
public
|
type(string $type): $this
Specify a type for the column
Specify a type for the column
|
#
|
public
|
unique(string $indexName = null): $this
Add a unique index
|
#
|
public
|
unsigned(): $this
Set the INTEGER column as UNSIGNED (MySQL)
Set the INTEGER column as UNSIGNED (MySQL)
|
#
|
public
|
useCurrent(): $this
Set the TIMESTAMP column to use CURRENT_TIMESTAMP as default value
Set the TIMESTAMP column to use CURRENT_TIMESTAMP as default value
|
#
|
public
|
useCurrentOnUpdate(): $this
Set the TIMESTAMP column to use CURRENT_TIMESTAMP when updating (MySQL)
Set the TIMESTAMP column to use CURRENT_TIMESTAMP when updating (MySQL)
|
#
|
public
|
virtualAs(string $expression): $this
Create a virtual generated column (MySQL/PostgreSQL/SQLite)
Create a virtual generated column (MySQL/PostgreSQL/SQLite)
|
#
|