Hi,
I have a requirement to save the value in the columns format into the field locationName(ri!location.locationName).Example: lat:56.98786, longitude:8.09933,In the given below format i used the anytype i got the as i required but when i am unable to do with the CDT , Can u please suggest me any way or is it possible to do in that format
Discussion posts and replies are publicly visible
You can do two things: Create one column for latitude and one for longitude, or, you can save the data as JSON.
If you have a field 'locationName' that is text, you can save a dictionary to that field by doing a!toJSON(). When you read from that table, you just need to use a!fromJSON() to manipulate those values in SAIL
thank you Danny Verb, i am getting an error when i am doing as you suggested, here i am saving the latitude and longitude in ri!locationlistTable.locationName and using the a!toJSON
Why are you trying to call a!toJson on just the location name? It's intended to be called on dictionaries or arrays, as the error message notes.
thank you Mike, but upon choosing the location on the map the latitude and longitudes are getting save into my (ri!location.locationName) directly, I don't have any other variable to apply a!toJSON or a!fromJson functions,if I am wrong please elaborate it
If you've stored the JSON value into ri!selectYourLocation.locationName, you would want to convert it back FROM json when passing into the "MapsPlaceSearchAndPin" rule using a!fromJson instead. Though if you have the chance to modify that interface instead, I'd suggest it might be easier doing the JSON conversion all there (and changing the "selectedLocation" parameter to use Text instead of a CDT).
thank you Mike