KrleDano
KrleDano
CCConvex Community
Created by KrleDano on 12/7/2023 in #support-community
How to create unique field in Convex
How do I restrict the name to be unique meaning, two document can't have same name?
export default defineSchema({
transactionCategory: defineTable({
name: v.string(), // has to be unique
icon: v.optional(v.string()),
}),
});
export default defineSchema({
transactionCategory: defineTable({
name: v.string(), // has to be unique
icon: v.optional(v.string()),
}),
});
12 replies