# Serializing Symbols in Table?

**URL:** <https://www.ruby-forum.com/t/serializing-symbols-in-table/105973>\
**Category:** Rails\
**Created:** [June 5, 2007, 5:11am UTC](https://www.ruby-forum.com/t/serializing-symbols-in-table/105973 "2007-06-05T05:11:17Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![matt\_jacobs](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/d2c977/32.png) [@matt\_jacobs](https://www.ruby-forum.com/u/matt_jacobs)\
**Post date:** [June 5, 2007, 5:11am UTC](https://www.ruby-forum.com/t/serializing-symbols-in-table/105973/1 "2007-06-05T05:11:17Z")

</div>

Hi everyone,

I’m planning an application that I’m going to be working on where I’ll  
have a number of Users and I’ll need to store the user’s current  
position on a governing board (if he/she has a position) and also all  
past positions that the user has held. There are only a handful of  
positions so I was thinking of making the positions symbols and storing  
the current position as either a nil value or the symbol if the user  
holds the position (and there is only one person per position at a time)  
and a serialized list of the positions that each user has held in the  
past. Does this make sense or is there a better way to do this? Also,  
would I make my column types as binary types or INTS? I’m not sure what  
a symbol should be represented by.

Also, on a related note, each user might/might not want all of his/her  
information public, is it a good idea to have a seperate column for  
every possible hidden value which represents a boolean indicating if  
that value should be shown? (E.g. for columns email\_address, phone, etc  
there would be email\_address\_public phone\_public, etc.)

Thanks everyone!  
Matt

---

<div class="post-metadata">

**Author:** ![matt\_jacobs](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/d2c977/32.png) [@matt\_jacobs](https://www.ruby-forum.com/u/matt_jacobs)\
**Post date:** [June 6, 2007, 2:58am UTC](https://www.ruby-forum.com/t/serializing-symbols-in-table/105973/2 "2007-06-06T02:58:07Z")

</div>

Anyone have any ideas?

Thanks!

matt jacobs wrote:

> Hi everyone,
> 
> I’m planning an application that I’m going to be working on where I’ll  
> have a number of Users and I’ll need to store the user’s current  
> position on a governing board (if he/she has a position) and also all  
> past positions that the user has held. There are only a handful of  
> positions so I was thinking of making the positions symbols and storing  
> the current position as either a nil value or the symbol if the user  
> holds the position (and there is only one person per position at a time)  
> and a serialized list of the positions that each user has held in the  
> past. Does this make sense or is there a better way to do this? Also,  
> would I make my column types as binary types or INTS? I’m not sure what  
> a symbol should be represented by.
> 
> Also, on a related note, each user might/might not want all of his/her  
> information public, is it a good idea to have a seperate column for  
> every possible hidden value which represents a boolean indicating if  
> that value should be shown? (E.g. for columns email\_address, phone, etc  
> there would be email\_address\_public phone\_public, etc.)
> 
> Thanks everyone!  
> Matt

---

<div class="post-metadata">

**Author:** ![matt\_jacobs](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/d2c977/32.png) [@matt\_jacobs](https://www.ruby-forum.com/u/matt_jacobs)\
**Post date:** [June 6, 2007, 3:17am UTC](https://www.ruby-forum.com/t/serializing-symbols-in-table/105973/3 "2007-06-06T03:17:38Z")

</div>

store them as strings and enjoy all the headaches you won’t be having.  
🙂
