I have NO IDEA what is in your tables or how to achieve the requested result. Unless you can provide the necessary information, I can't help. Given what you have told us, my response is to just fix the value of ID_Color since it isn't what you want. I have no idea how that field gets populated. It appears to be a deep, dark secret. But if the data is coming from a table or value list, FIX the source.