Rhys
Rhys•5d ago

Storing entity settings in Convex

👋 Moving over to Convex from MySQL and was wondering on schema design At the moment, per entity I store settings in a bitfield int - so for example for a server it is: Server { name: string bitfield: number } In that bitfield, if a setting is enabled a bit gets flipped so if it has the all messages as public & the anonymize messages bits it'd be 011 Is this worth to keep doing or should I just have settings be stored as individual fields on the entity? Thinking of in convex having this be: Server{ name: string enableAllMessagesAsPublic: date | null enableAnonymizeMessages: date | null }
1 Reply
Convex Bot
Convex Bot•5d ago
Thanks for posting in <#1088161997662724167>. Reminder: If you have a Convex Pro account, use the Convex Dashboard to file support tickets. - Provide context: What are you trying to achieve, what is the end-user interaction, what are you seeing? (full error message, command output, etc.) - Use search.convex.dev to search Docs, Stack, and Discord all at once. - Additionally, you can post your questions in the Convex Community's <#1228095053885476985> channel to receive a response from AI. - Avoid tagging staff unless specifically instructed. Thank you!

Did you find this page helpful?