anchor.diff:          Log.WriteLn('HandleDataEvent: unknown type/method: '+_type+', method: '+_method,llWarning);
         end;
       end;
  +    FreeAndNil(jsonResponse);
     except
       on e: exception
       do log.WriteLn('exception in TEcodistrictModule.HandleDataEvent: '+e.Message, llError);
  
positive.code:                     jsonKpi:=jsonIterator.Current;
                      _kpi_type:=jsonKpi.GetValue<string>('type', 'None');
                      _gml_id:=jsonKpi.GetValue<string>('gml_id', 'None');
                      _kpi_value:=jsonKpi.GetValue<double>('kpiValue', 'None');
                      (fDBConnection as TFDConnection).ExecSQL('SET SCHEMA ''' + EcoDistrictSchemaId(_caseId, _variantId) + '''');
                      try
  // SQL delete from kpi_results where kpi_type=... and gml_id= and kpi_id =
                        (fDBConnection as TFDConnection).ExecSQL('DELETE FROM kpi_results WHERE kpi_type='''+_kpi_type+''' AND gml_id='''+_gml_id+''' AND kpi_id='''+_kpiId+''';');
  // SQL insert into kpi_results (kpi_type, kpi_id, gml_id, kpi_value) values ()
                        (fDBConnection as TFDConnection).ExecSQL('INSERT INTO kpi_results (kpi_type, kpi_id, gml_id, kpi_value) VALUES ('''+_kpi_type+''', '''+_kpiId+''', '''+_gml_id+''','+_kpi_value+');');
                      finally
                        (fDBConnection as TFDConnection).ExecSQL('SET SCHEMA ''public''');
                        _status := 'Success - data added to the database';
  
negative.code: //  dataresponse: string;
    jsonDataResponse: TJSONObject;
    jsonList: TJSONObject;
    jsonArray: TJSONArray;
    jsonIterator: TJSONArrayEnumerator;
    jsonKpi: TJSONValue;
    //attr_value: string;
  