This sounds like you need to build a proper inventory management and product sales application.
To do this right is not a beginner level endeavor.
One possible script prototype for the transaction you describe could be:
Go to layout of table A.
Find just the record you want to transfer.
If ( found set = 1)
Copy the values you want to transfer into variables via the set variable script step
Go to a layout of table B.
Create a new record.
Set fields in table B with the values stored in variables.
//If more than one record is found then do nothing