vendors was created without a key. Make vendor_id its primary key without recreating the table.
vendors
vendor_id
Run your code to see the output here.