I hope its useful to you, try with this code.
1) create one attribute of type "dropdown" as discount_percentage
.
2) assign attribute to the product attribute set
3) now for calculation of the product discount you can try using observer called catalog_product_save_before
with following code in observer.php
public function catalog_product_save_before($observer)
{
$product = $observer->getProduct();
$product_price = $product->getPrice();
$product_sp_price = $product->getSpecialPrice();
$discount_percentage = ($product_sp_price/$product_price)*100;
$product->setDiscountPercentage($discount_percentage);
$product->save();
}
Note :- before discount is assiging to product the that option should be created previously.for example if the discount is 30% the discount option 30% should be their before or else you have to look how to create this options to dropdown attributes programmatically