index method

ColumnDefinition index([
  1. String? indexName,
  2. ColumnIndex type = ColumnIndex.indexKey
])

Add index to column - NOW PROPERLY USED!

Implementation

ColumnDefinition index([
  String? indexName,
  ColumnIndex type = ColumnIndex.indexKey,
]) {
  _indexName = indexName ?? 'idx_${_schema.tableName}_$_name';
  _indexType = type;

  _schema.addCompositeIndex(_indexName!, _name, _indexType);
  return this;
}