Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Sheenu
Contributor II
Contributor II

Latitude Longitude values getting truncated when loaded through rest connection from JSON format data.

Hi All,

I have this issue as I am loading  geo data from a rest connection to Qlik enterprise edition May2023.

Latitude,Longitude values in JSON :

[
-9828193.8604000006,
5123014.2217999995
],
[
-9827441.3716000002,
5123029.3680000007
]

Values getting loaded in Qlik:

[
-9828193.8604,
5123014.2217
],
[
-9827441.3716,
5123029.3680
]

The values are truncated to 4 decimal places in Qlik.Need help to preserve the coordinates as it is in JSON .

Thanks!

Labels (3)
1 Solution

Accepted Solutions
Alan_Slaughter
Support
Support

Hi Sheenu, this may be helpful to you:


The issue you are facing is that the latitude and longitude values in the JSON data are being truncated to 4 decimal places when loaded into Qlik. This truncation is likely due to the default precision settings in Qlik.

To resolve this issue and preserve the full precision of the latitude and longitude values, you can adjust the number formatting settings in Qlik. Specifically, you need to increase the number of decimal places allowed for the fields containing the latitude and longitude values.

Here are the steps to adjust the number formatting:

1. Open the Qlik Sense app and go to the Data Load Editor.
2. Locate the fields containing the latitude and longitude values.
3. Right-click on each field and select "Number Formatting..."
4. In the Number Formatting dialog, increase the "Decimals" value to a higher number, such as 10 or 15, to accommodate the desired precision.
5. Click "OK" to apply the changes.

After adjusting the number formatting settings, the latitude and longitude values should be loaded into Qlik with their full precision, without any truncation.

View solution in original post

2 Replies
Alan_Slaughter
Support
Support

Hi Sheenu, this may be helpful to you:


The issue you are facing is that the latitude and longitude values in the JSON data are being truncated to 4 decimal places when loaded into Qlik. This truncation is likely due to the default precision settings in Qlik.

To resolve this issue and preserve the full precision of the latitude and longitude values, you can adjust the number formatting settings in Qlik. Specifically, you need to increase the number of decimal places allowed for the fields containing the latitude and longitude values.

Here are the steps to adjust the number formatting:

1. Open the Qlik Sense app and go to the Data Load Editor.
2. Locate the fields containing the latitude and longitude values.
3. Right-click on each field and select "Number Formatting..."
4. In the Number Formatting dialog, increase the "Decimals" value to a higher number, such as 10 or 15, to accommodate the desired precision.
5. Click "OK" to apply the changes.

After adjusting the number formatting settings, the latitude and longitude values should be loaded into Qlik with their full precision, without any truncation.

Sheenu
Contributor II
Contributor II
Author

Hi Alan,

Thank you! Appreciate your response.

I had to change the data format to GeoJson instead of JSON as I was bringing in the data from the rest connection and that solved the problem.