2

I'm doing an UPDATE query to Google Fusion Tables like this:

    function updateRow(columnName, veryLongValue, rowId, tableId) {
        return new Promise(function(resolve, reject){
            var query = "UPDATE " + tableId + " SET " + columnName + "='" + veryLongValue + "' WHERE ROWID = '" + rowId + "'";
            gapi.client.load('fusiontables', 'v1', function() {
            gapi.client.fusiontables.query.sql({sql:query}).execute(
                function(response){
                    // Do my success and reject checks.
                });
            });
        });
    }

The function works properly when veryLongValue is not that long, but when I use long strings for it, that make the whole query length ~6000, sometimes ~20000 characters long, I get an error with a message:

"A network error occurred, and the request could not be completed."

As per this answer to a previous question, it seems that the query limit is around 2048 characters.

Is there a way to go around this limit?

As an extra, Fusion Tables can handle cells with way longer strings in them than this. One can upload very long values directly on their GUI and everything gets uploaded properly and is accessible for download with the API and normal queries.

marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
buzoherbert
  • 1,537
  • 1
  • 12
  • 34

0 Answers0