vad
vad

Reputation: 1276

Django models: how to manage field flags

I need to create a User Profile. To ensure privacy many fields in this profile will be "hidable": every User will be able to hide these information.

I can use https://github.com/disqus/django-bitfield, but i would like to know if it's possibile to better tie each field to its own flag.

Upvotes: 0

Views: 1147

Answers (1)

Ignacio Vazquez-Abrams
Ignacio Vazquez-Abrams

Reputation: 799110

Packing bits into a single field makes it more difficult to index and query the field. It's more effort than it's worth.

Upvotes: 1

Related Questions