createIndex method

  1. @override
String createIndex(
  1. String indexName,
  2. QualifiedTablename onTable,
  3. List<String> columns
)
override

Create an index on a table.

Implementation

@override
String createIndex(
  String indexName,
  QualifiedTablename onTable,
  List<String> columns,
) {
  final namespace = onTable.namespace;
  final tablename = onTable.tablename;
  return 'CREATE INDEX IF NOT EXISTS $namespace.$indexName ON $tablename (${columns.join(', ')})';
}