Let's say I am storing start and stop points per user into a database table.
For example... let's say in a chat system, a user only needs to see lines 24-293, and 500-512. (Let's say he logged off for the night, and was not present between lines 294-499).
Saving each start and stop point as a discrete row would lead to a huge ballooning table, which isn't exactly ideal. I wouldn't be searching on these points, so indexing is not necessary.
How would I save this kind of information in the database?
I was thinking of saving it in JSON:
accountID | lines 1 | [24,293,500,512]
Where each odd value denotes a start, and each even value denotes an end. My only worry is that highly active users will be joining and leaving a chat, and would quickly fill up the row if
lines was of type VARCHAR.
TEXT, or even
Am I heading down a path of hurt, or is this a viable method?
Thanks in advance!