I have got two tables.
assets table
| AID | NAME | | 1234 | item1|
item table
| BID | ITEM | | | |
Question: How do I insert a data into item table only when the same data I want to insert is present in assets table? or is it even possible? Say I can only insert into item table BID value(1234) only when assets table AID value(1234) is present. I tried doing this:
INSERT INTO 'item'('BID') VALUES (1234) WHERE 'item'.BID='assets'.AID
ITEMvalue then?'item1'string? Also, do you want this 'WHERE' check applied for a single operation only, or you want to copy thatassetstable as whole?