function updateTable(qty, id, total) {
    total = total.toFixed(2);
    console.log("Updating, one moment please!...\n");
    var query = connection.query(
        "UPDATE products SET ? WHERE ?", [{
                stock_quantity: qty
            },
            {
                item_id: id
            }
        ],
        //prints out total sale then after 5 seconds starts back Bamazon.
        function (err, res) {
            console.log("***$", total, "Total Sale***");
            setTimeout(start, 5000);
        }
    );
}
//updateTable takes in the values from qtyMath and updates table
updateTable takes in the values from qtyMath and updates table
updateTable takes in the values from qtyMath and updates table
function updateTable(qty, id, total) {
    total = total.toFixed(2);
    console.log("Updating, one moment please!...\n");
    var query = connection.query(
        "UPDATE products SET ? WHERE ?", [{
                stock_quantity: qty
            },
            {
                item_id: id
            }
        ],
        function (err, res) {
            console.log("***$", total, "Total Sale***");
            setTimeout(start, 5000);
        }
    );
}
function updateTable ( qty , id , total ) { total = total . toFixed ( 2 ) ; console . log ( "Updating, one moment please!...\n" ) ; var query = connection . query ( "UPDATE products SET ? WHERE ?" , [ { stock_quantity : qty } , { item_id : id } ] , function ( err , res ) { console . log ( "***$" , total , "Total Sale***" ) ; setTimeout ( start , 5000 ) ; } ) ; }
updateTable takes in the values from qtyMath and updates table
updateTable takes in the values from qtyMath and updates table
//prints out total sale then after 5 seconds starts back Bamazon.