Sequence
Less than 1 minute
Sequence
Trait providing sequence management methods for SQL-based DBI drivers.
trait SequenceIncludes default implementations for listing, checking, describing, creating, dropping, and manipulating sequences.
Methods
listSequences
public listSequences(): voidsequenceExists
Check if a sequence exists by name.
public sequenceExists(string $sequenceName): boolParameters
| Parameter | Type | Description |
|---|---|---|
$sequenceName | string | the name of the sequence to check |
describeSequence
public describeSequence(string $name, false $): voidParameters
| Parameter | Type | Description |
|---|---|---|
$name | string | |
$ | false |
createSequence
public createSequence(string $name, array $sequenceInfo, bool $ifNotExists): boolParameters
| Parameter | Type | Description |
|---|---|---|
$name | string | |
$sequenceInfo | array | |
$ifNotExists | bool |
dropSequence
Attempt to drop a sequence by name.
public dropSequence(string $name, bool $ifExists): boolParameters
| Parameter | Type | Description |
|---|---|---|
$name | string | the name of the sequence to drop |
$ifExists | bool | if true, do not error if the sequence does not exist |
nextSequenceValue
Get the next value from a sequence.
public nextSequenceValue(string $name): intParameters
| Parameter | Type | Description |
|---|---|---|
$name | string | the name of the sequence |
setSequenceValue
Set the current value of a sequence.
public setSequenceValue(string $name, int $value): boolParameters
| Parameter | Type | Description |
|---|---|---|
$name | string | the name of the sequence |
$value | int | the value to set the sequence to |
Generated by Hazaar API Doc Generator on Tue, 21 Apr 2026 04:00:24 +0000