nliebke
Posts: 2
|
Posted: 01/28/2010, 3:28 PM |
|
Hi,
I've noticed a problem with CodeCharge that is causing me issues. I've created a link in SQL for an external URL that I use as a source for a link. This works fine in the Visual Query Builder and if I run the query I can see the result fine. Viewing the SQL also works fine.
However, when this gets converted into code, CodeCharge is introducing spaces into the URL which makes it unusable.
For example, if I add a field to the Visual Query Builder as follows:
http://forums.codecharge.com/search.php?s_keyword=codecharge+bug&s_using=2&s_author=&s_forum[]=2&s_forum[]=4&s_forum[]=5&s_forum[]=6&s_forum[]=7&s_forum[]=8&s_forum[]=9&s_forum[]=12&s_forum[]=22&s_forum[]=25&s_forum[]=29&s_forum[]=30&s_forum[]=34&s_forum[]=13&s_forum[]=14&s_forum[]=15&s_forum[]=26&s_forum[]=11&s_forum[]=23&s_forum[]=24&s_forum[]=16&s_forum[]=17&s_forum[]=18&s_forum[]=19&s_forum[]=20&s_forum[]=21&s_forum[]=31&s_forum[]=35&s_period=
This will display fine in the Visual Query builder. But, if I then look at the code I see:
SQL = "SELECT [Other Fields], " & vbLf & _
"'http://forums.codecharge.com/search.php?s_keyword=codecharge+ " & vbLf & _
"bug&s_using=2&s_author=&s_forum[]=2&s_forum[]=4&s_forum[]=5&s_forum[]=6&s_forum[]=7&s_forum[]=8&s_for " & vbLf & _
"um[]=9&s_forum[]=12&s_forum[]=22&s_forum[]=25&s_forum[]=29&s_forum[]=30&s_forum[]=34&s_forum[]=13&s_f " & vbLf & _
"orum[]=14&s_forum[]=15&s_forum[]=26&s_forum[]=11&s_forum[]=23&s_forum[]=24&s_forum[]=16&s_forum[]=17&s_forum[]=18&s_forum[]=19&s_forum[]=20&s_forum[]=21&s_forum[]=31&s_forum[]=35&s_period=' AS TestURL " & vbLf & _
"FROM [TableName] {SQL_Where} {SQL_OrderBy}"
This obviously makes the URL unusable as the spaces that are introduced at the end of each line lead to an invalid address. It looks as though it's introducing a line feed and a space every 100 characters. I can only assume this is to make the code more readable.
Has anybody else experienced this problem and if so, is there a resolution? I realize that I could modify the code directly but I'm loathe to do that as it will cause maintenance issues whenever I want to add/remove other fields to the form as the code will not auto-generate once the code is modified.
Thanks in advance,
Nathan.
|