Solved

published parameter values gets cutoff

  • 21 July 2016
  • 1 reply
  • 2 views

Badge

I have a workspace that opens an excel file and reads two columns as attributes. One of those is meant to be used as a querystring. On several places in each attribute value there are commas. For instance:

[timeout:900];(node["leisure"~"[[Ww]ildlife_hide|[Bb]ird.hide"](50.662,1.902,53.665,7.465);node["tourism"~"[Bb]irdwatchpoint\\\\[Bb]ird.hide"](50.662,1.902,53.665,7.465););out; The attributes are then fed to a workspacerunner which uses yet another workspace. This last one has a HTTPcaller transformer, which loads the querystring and gets the results back. The Excel querystring gets to the HTTPcaller by means of published parameter. The weird thing is that the querystring gets cutoff before it reaches the HTTPCaller, and ... its delimiter seems to be the comma. What's fed to the HTTPCaller is:

[timeout:900];(node["leisure"~"[[Ww]ildlife_hide|[Bb]ird.hide"](50.662

which forms a bad request and is subsequently blocked. Other strings are also cutoff at their first comma occurence. If I fill in the querystring manually in the HTTPCaller, it is executed in the right way. But the published parameter value is allready cutoff when I check the value by means of a Logger right before the HTTPCaller. I have found a workable solution: replace the comma with a special code (StringReplacer) at the start and reverse back right before the HTTPCall. But I still like to know why the comma works as a delimiter. Kind regards, Pim Verver
icon

Best answer by redgeographics 21 July 2016, 11:45

View original

1 reply

Userlevel 5
Badge +26

Apparently comma's in url's are allowed but not always a good idea, so the solution you've found with the StringReplacer is probably the best one.

Reply