Delete rows from a table

hi, i trying to delete row from a table but i get an error,

i have a dropdown list and a button with this script:

delete = event.source.parent.getComponent('Dropdown').selectedStringValue
system.db.runUpdateQuery("DELETE FROM inventory where name = ?",[delete])

i get this error

java.lang.Exception: java.lang.Exception: Error executing system.db.runUpdateQuery(DELETE FROM inventory where name = ?, [u'Product4'], , false)


	caused by Exception: Error executing system.db.runUpdateQuery(DELETE FROM inventory where name = ?, [u'Product4'], , false)
	caused by GatewayException: Connection Error: Datasource "[u'Product4']" does not exist in this Gateway.
	caused by SQLException: Datasource "[u'Product4']" does not exist in this Gateway.

You are calling the wrong database function.

Try this one: system.db.runPrepUpdate

Thanks! that worked