Category Archives: Programming

Location – Latitude/Longitude (Lat/Lon) to Degrees Minutes Seconds (DMS) Conversion – JavaScript

Location - Latitude Longitude (LatLon) to Degrees Minutes Seconds (DMS) Conversion - JavaScript

Location – Latitude/Longitude (Lat/Lon) to Degrees Minutes Seconds (DMS) Conversion – JavaScript

Location - Latitude Longitude (LatLon) to Degrees Minutes Seconds (DMS) Conversion - JavaScript

Sample JavaScript Program: function truncate(n) { return n > 0 ? Math.floor(n) : Math.ceil(n); } let getDMS = function (dd, longOrLat) { let hemisphere = /^[WE]|(?:lon)/i.test(longOrLat) ? dd < 0 ? “W” : “E” : dd < 0 ? “S” : “N”; const absDD = Math.abs(dd); const degrees = truncate(absDD); const minutes = truncate((absDD -… Read More »

cannot change DocValues type from SORTED to SORTED_SET – DataStax Graph – Titan – Solr

cannot change DocValues type from SORTED to SORTED_SET – DataStax Graph – Titan – Solr

Are you facing these errors??? cannot change docvalues type from sorted_set to sorted for field field_name cannot change docvalues type from sorted to sorted_set for field field_name No worries. We have the solution. First of all we need to know what DocValues means in Solr. You will find a lot of information in the internet. Now… Read More »

Writing REST APIs – CREATE/POST – Best Practices – Part II

Writing REST APIs – CREATE/POST – Best Practices – Part II

This is my second post on Writing REST APIs. Today the focus is on POST HTTP method. Basically POST method is used for create a resource. Sample Request : POST /users { “users” : [{ “firstName” : “Tom”, “lastName” : “Cruise” },{ “firstName” : “Tom”, “lastName” : “Hardy” }] } Sample Response : { “statusCode” :… Read More »