import { index, integer, sqliteTable, text } from "drizzle-orm/sqlite-core";

/**
 * Core `groups` table.
 *
 * Source: AmqGroupSchema
 */
export const groups = sqliteTable(
	"groups",
	{
		/** AMQ songGroupId */
		songGroupId: integer("song_group_id").notNull().primaryKey(),
		name: text("name").notNull(),
	},
	(t) => ({
		nameIndex: index("groups_name_idx").on(t.name),
	}),
);
