You would need to create a couple of separate tables; 'Colours' with your colours in, and 'ProductColour' with the joining information of both product and colour.
The 'Colours' table would have colour_id and colour columns.
The 'ProductColour' table would have to consist of an id, colour_id and product_id.
At that point you take your product_id and join it with the colour_id by using the joining table which basically allows you to have one single instance of 'red' in your database that applies to many products.
Basically, you need to create an inner join between the product_id and the colour_id and it's at this point my knowledge gets shaky I'm afraid.
When a user browses a product with multiple colours, you ask the page to take the product_id e.g. 99, look in the ProductColours table (not the colours table) for any instance of product_id 99 and then print to a dropdown menu (or similar) the colour_id's where the records product_id matches 99...
Colours table: colour_id; colour
ProductColours table: ProductColour_id; colour_id; product_id
so the SQL will look like this (I think):
SELECT FROM ProductColours.colour_id, ProductColour.product_id, Colours.colour FROM ProductColours INNER JOIN Colours ON ProductColours.colour_id = Colours.colour_id
WHERE product_id = VALUE
ORDER BY colour ASC
The parameter 'VALUE' then needs the following info:
You then do the same for sizes, and I guess you could also apply the same for stock levels. This is only a sample, and I don't expect it to work... it might do, and that will be nice for you, wont it? If it doesn't, then there is a good ground for somebody else to offer up a bit of advice on how it might be able to work. I am sure that this is fairly rudimentary SQL, but I struggled with it a bit, lost my rag, struggled some more, really spat the dummy, struggled on further, and hey presto, it worked. How, I don't know, but it did :D
The above needs to be applied in the advanced recordset panel in dreamweaver.