/**
 * Update HostingServicePriceDBO in database
 *
 * @param HostingServicePriceDBO $dbo HostingServicePriceDBO to update
 * @return boolean True on success
 */
function update_HostingServicePriceDBO(HostingServicePriceDBO $dbo)
{
    $DB = DBConnection::getDBConnection();
    // Build SQL
    $sql = $DB->build_update_sql("hostingserviceprice", sprintf("serviceid=%d AND type='%s' AND termlength=%d", $dbo->getServiceID(), $dbo->getType(), $dbo->getTermLength()), array("price" => $dbo->getPrice(), "taxable" => $dbo->getTaxable()));
    // Run query
    if (!mysql_query($sql, $DB->handle())) {
        throw new DBException(mysql_error($DB->handle()));
    }
}