Page 1 of 1

Stings parameters w spaces passed in quotes when scheduled

Posted: Tue Jun 24, 2008 10:20 am
by RodBarnes
On Windows Server, the AT command is used to schedule jobs on the server. In the process of creating the command, any string parameter containing spaces gets passed with quotes (") around it. This does not happen when running a job manually.

For example, if the value of the parameter is

Code: Select all

CLIENT SYSTEM
when run manually, it gets passed as

Code: Select all

CLIENT SYSTEM
When run as a scheduled job the value is passed as

Code: Select all

"CLIENT SYSTEM"
Then, if the value is used in a SQL statement, those quotes get treated as part of the value.

Has anyone else run into this and come up with a way to resolve the parameter or strip off the quotes? Obviously some routine that would grab the parameter, check for and strip off the quotes before it gets to the database stage but I haven't come up with a way to intercept the parameter yet.

Posted: Tue Jun 24, 2008 4:12 pm
by ray.wurlod
Microsoft knows far better than you do what your requirements are, and therefore you clearly need these quote characters. :wink:

(No, I don't know any way to strip them.) :(

Posted: Tue Jun 24, 2008 4:33 pm
by RodBarnes
:lol: Yeah, they do know best. :wink:
I actually understand the need for the quotes since AT is a command line program and so the quotes are required for it to treat it as a single value rather than breaking at the space. However, knowing that and that the quotes are put there by Director when the job is scheduled, then DataStage should filter them out when it runs the job. Based on that, I opened a case with IBM so we'll see what comes of it.
ray.wurlod wrote:Microsoft knows far better than you do what your requirements are, and therefore you clearly need these quote characters. :wink:

(No, I don't know any way to strip them.) :(

Posted: Tue Jun 24, 2008 5:11 pm
by chulett
Pretty sure someone has already posted on this issue, but I don't recall if there was anything in the way of a resolution. Curious what IBM Support comes up with.

Posted: Fri Jul 11, 2008 1:36 pm
by RodBarnes
Finally reached a resolution with IBM. It seems this only occurs in 7.5 and prior. It is apparently fixed in 7.5.1 and beyond.

Now, as to why we are still running 7.5, that is a different story. :(

Posted: Fri Jul 11, 2008 1:38 pm
by RodBarnes
Finally reached a resolution with IBM. It seems this only occurs in 7.5 and prior. It is apparently fixed in 7.5.1 and beyond.

Now, as to why we are still running 7.5, that is a different story. :(