“Data may still be loading”… but it's already there?

▼魔方 西西 提交于 2019-12-13 04:40:47

问题


So I'm running this code and all the points show up fine. But I still get the "Data may still be loading" tiles. I've double checked the table IDs, geocoding, column names etc... so now I'm at a loss. Anybody experience this before?

function changeByZip(formResults) {
    geocoder.geocode( { 'address': formResults }, function(results, status) {
        if (status == google.maps.GeocoderStatus.OK) {
            map.setCenter(results[0].geometry.location);
            map.setZoom(13);
            layer.setQuery("SELECT 'Address' FROM " + tableid + " WHERE 'Zip' = '" + formResults + "'");
            layer2.setQuery("SELECT 'Address' FROM " + tableid2 + " WHERE 'Zip' = '" + formResults + "'");
        } 
    });
}

I have two layers because I have about 14,000 points. When I comment out either one of those layers, the data loading tiles go away and it displays as expected. For some reason, the two layers don't like each other?

Thanks in advance.

Edit: I discovered the column name was different from what the query was looking for.


回答1:


Please take a look at this link:

https://developers.google.com/fusiontables/docs/troubleshooting

According to the troubleshooting guide:

Map tiles "Data may still be loading" message does not resolve

Cause: Fusion Tables is unable to understand the query in the FusionTableLayer. A few things to try:

  • Check the query object syntax. Any syntax error can trigger this error message. To resolve it, fix your Fusion Tables Layers syntax. See FusionTableLayer documentation at Google Maps Javascript API V3 Reference and Google Maps Javascript API Layers
  • Check the Table ID. Doublecheck that you are using the correct table ID.
  • Check column names. Column names are case-sensitive , so "Zipcode" and "zipcode" are not the same. Multi-word column names need to be enclosed in single quotes. See Fusion Tables SQL API: Reference.
  • Check your geocoding. Fusion Tables must understand the locations in your table before it can map them. Location descriptions in your table, such as addresses, must be geocoded. See "Geocoding Location Descriptions" in the Fusion Tables Developer's Guide.


来源:https://stackoverflow.com/questions/10609186/data-may-still-be-loading-but-its-already-there

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!