How to get all rows/records from a sqlite query for posting phonegap/cordova

I need to get all instances/rows from sqlite to bind for posting to remote server. I have the implementation below, but it only shows/gets one row. Eventually once I can get all rows, I wish to post them.

    <script type="text/javascript"> 
         db.transaction(function(tx) {
            Squery = 'SELECT * FROM records';
                tx.executeSql(Squery,
                    null,
                    function(tx, results)
                    {
                            for(i=0; i<results.rows. length; i++){
                                row = results.rows.item(0);

                    //need all records/rows to show
                    var name = row['name'];
                    var age = row['age'];

                    var dataString = "name=" + name + "&age=" + age;

                      $.ajax({ //Ajax details here
                      });
    //test alert, only shows one row of 'name and age' records, I want a list of all records          
            alert(dataString);
                    return false;   
                            }});
                    });
        </script>