List datadype

List datadype

am 20.01.2007 23:26:38 von Simon

Hello!

Is there anything in MySQL taht allows user to store in one filed multiple
values?
I mean something like SET; but we cannot store in set nothing except for
values declared while TABLE creation, and I need some kind of equivalent for
list.

Szymon bobek

Re: List datadype

am 21.01.2007 01:42:33 von Rik

Simon wrote:
> Hello!
>
> Is there anything in MySQL taht allows user to store in one filed
> multiple values?
> I mean something like SET; but we cannot store in set nothing except
> for values declared while TABLE creation, and I need some kind of
> equivalent for list.

You can add / remove / alter the SET by the ALTER syntax.
If that's not what you want, I'd go for an extra table.

table_main
id
name

table_values
id
name

table_main_values
table_main_id
table_values_id
--
Rik Wasmus