jimmie,
your code is.... well.... u know...

there is no need for this var $products_discounts_query->fields[whatever] in this code. that is just taking the last record used.

what you need is the var $quantityDiscounts, which you only use once, and in fact you end up replacing it with the above var.

u need a loop as $quantityDiscounts is an array that contains all of your data.

i'm just not sure why you are not using:

includes/templates/template_default/templates/tpl_modules_products_quantity_discounts.php

which will output all of the discounts.

if you want to do it in your above code, you need to do something like:

PHP Code:
         foreach ($quantityDiscounts as $discount) {
                                  
                   
// do stuff with $discount, ie all of your calculations and then echoing to the screen.
                   // the next line will help you see....  hopefully
                 
print_r($discount);
         } 
hope that helps.

best.