DELETE `qs_SettingsOptions` 
FROM  `qs_SettingsOptions` 
JOIN  `qs_Settings`  ON  `qs_Settings`.`name` = `qs_SettingsOptions`.`name` 
WHERE  
 `qs_SettingsOptions`.`variable` =  'toolbar'
AND  `qs_SettingsOptions`.`value` =  'Basic';