2 Replies Latest reply: Dec 8, 2013 9:24 PM by jagan mohan rao appala RSS

    Extract latitude and Longitude using QV Script

    Agnivesh Kumar

      I am trying to extract lat and lon from google map using following script.

       

      address:

      LOAD A as Address

      FROM

      [C:\Users\agnivesh\Desktop\new address.xlsx]

      (ooxml, no labels, table is Sheet1);

       

      let noRows = NoOfRows('address')-1;

      for i=0 to $(noRows)

      let a=peek('Address',$(i),'address');

       

      Data:

      LOAD

      '$(a)' as Address,

      [result/geometry/location/lng] AS longitude,

      [result/geometry/location/lat] AS latitude

      FROM [http://maps.googleapis.com/maps/api/geocode/xml?address=$(a)&sensor=false];

       

      drop Table address;

       

       

      but when i load this script then an error comes [result/geometry/location/lng] not found .

      but when i check http://maps.googleapis.com/maps/api/geocode/xml?address=Delhi&sensor=false

      this link in internet file it will show same path as i used .

       

      Please help.