Hi Riccardo,
I was also using jquery to use the raw fusion table api. And when i
looked at your code and tried the same thing, i noticed two things:
1) when i have dataType:'json' , it does not work
2) when i use jsonp instead, dataType : 'jsonp' , it is fetching data
but in Firebug i see an error message 'script too large'. Not sure
what's going on.
Here is the code snippet i am using.
function queryFusionTable()
{
$.ajax(
{
url: '
https://www.google.com/fusiontables/api/query?sql='
+
encodeURIComponent('SELECT geometry FROM
1182169'),
dataType:'jsonp',
jsonp :
'jsonCallback',
success : function(json)
{
var rows = json.table.rows;
var cols = json.table.cols;
........
.........
}
}
);
}
Do you know what could be wrong here?
On Jul 26, 12:38 pm, Riccardo Govoni ☢ <
battleho...@gmail.com> wrote:
> Note that there is indeed a limitation in the number of rows that you can
> get from a Fusion Table via the Google Chart Tools API and that is set to
> 500 rows. Seehttp://
code.google.com/apis/fusiontables/docs/sample_code.html
> :
>
> "Using the Google Chart
> Tools<
http://code.google.com/apis/charttools/index.html>,
> you can request data from Fusion Tables to use in visualizations or to
> display directly in an HTML page. Note: responses are limited to 500 rows of
> data"
>
> I don't know the reason for such limitation, but you can work around it by
> using the raw fusion tables SQL API (
http://code.google.com/apis/fusiontables/docs/developers_guide.html) and
> query your datasource asking for a response in JSONP format. This doesn't
> seem to have the same row limitation. Once you have the response in JSONP
> format, you can easily transform it into a DataTable on the client and then
> pass it to the visualization.
>
> You can use this
> file<
http://code.google.com/p/google-visualization-io2011/source/browse/js...>,
> starting from line 105 as an example of the process (using the jQuery
> library).
>
> /R.
>
> > Could you please post this in the Fusion Table Users Group<
https://groups.google.com/forum/#!forum/fusion-tables-users-group> so