Multiple values for a single column I've got a small database with 5 tables: 3 of them are resources (material, skill and tool) and the other 2 are tasks (corrective maintenance and preventive maintenance).
Every table has a primary key with a code, and the task tables has a column for every resource code. My problem is that in some tasks, there is the possibility of having many resources of one type (2 materials, 3 skills or 6 tools). What is a good way of implementing this into an SQLite database? Creating many columns is not a good idea because there is not fixed number of resources that are needed.
Thank you in advance!
Lots of columns that column similar or repeated things is usually a Bad Idea.
Proper Data Normalisation is your Friend.
select * from resource ; 
+----+--------+
| id | name   | 
+----+--------+
|  1 | res #1 | 
|  2 | res #2 |
+----+--------+

select * from task ; 
+----+---------+
| id | name    |
+----+---------+
| 33 | task #1 | 
| 44 | task #2 | 
+----+---------+

select * from task_resource ; 
+---------+-------------+
| task_id | resource_id | 
+---------+-------------+
|      33 |           1 | 
|      44 |           1 | 
|      44 |           2 | 
+---------+-------------+