I hope someone can help me with this problem. I have a query that selects shipping details from a customer account. The i have a second query to count the weight of all the products in the shipping query. How do i count all the weights of products and display the result??
Shipping query:
Code: Select all
$query = "SELECT * FROM Shipping, Customers, Orders, Delivery_Zones
WHERE Delivery_Zones.zone_id = Orders.delivery_zone AND Shipping.order_id = Orders.order_id AND Customers.customer_id = Orders.customer_id AND dispatch_date = '$dispatchdate'";Product weight query:
$order_id = $rows['order_id'];
Code: Select all
$query2 = "SELECT * FROM Product_Description, Order_Details
WHERE Product_Description.product_id = Order_Details.product_id AND Order_Details.order_id = '$order_id'";Code: Select all
$weight = $rows2['product_weight'];
$totalweight =+ $weight;
echo $totalweight;Regards,
Steven