locked
Add data item from a table to another table RRS feed

  • Question

  • I have two tables,  "Model" and "Colour". Fields of Model are "Id", "ModelId" and "ModelName" and fields of Colour are "Id", "ColourId" and "ColourName". These two tables have one to many relationship. A model must have a colour. One Colour can have many Models.

    Say "A" is ColourId with a ColourName "black". An example of ModelId would be "101A", 101 is just model code and A refer to ColourId. ModelId cannot be computed property because that's the value user gonna enter.

    What I'm asking is how do I split the ColourId from ModelId and query the related colour item and add it to a record of Model.
    Monday, March 2, 2015 5:17 PM

All replies