"Thanks a lot for your reply anyway
🙂 and I'm sorry it
wasn't of use
to me."
Actually Dan was guiding you down the correct database
normalization
path. What you have is a classic many-to-many join. You have
many
character records and many skill records and you want to join
them such
that a character can have 0-N skills (zero to infinity) and a
skill can
be used by 0-N players.
This is done with three tables. A character table with the
basic
details of a character and a skills table with the details of
the skills
and a joining table that connects the two. At a minimum the
join tables
simple consists of two fields, a foreign key field to the
characters
table and a foreign key field to the skills table. Thus for
each skill
a character has there will be one record connecting the two
id's
together. This joining table can easily be expanded to have
other data
about the character-skill join such as when it started, what
level the
character has reached in the skill, whatever else your system
needs.
An simple Example:
Character Table
ID Name
1 Joe
2 Sam
3 George
Skill Table
ID Name
1 Hunting
2 Cooking
3 Archery
Character_Skill Join Table
CharID SkillID
1 1
1 3
2 2
3 1
3 2
3 3
Thus with basic SQL join syntax we can synthesize the data
that Joe can
hunt and shoot arrows, Sam can cook and George can do it all.
HTH
Ian