IBM Support

IBM InfoSphere DataStage reports error when using parameter with single quote in a SQL statement in any Database Stage.

Troubleshooting


Problem

Problem with using parameter with single quote in a SQL statement in any Database Stage. Single quotes are stripped off instead of being escaped. Error reported in job log states: "The provided query statement did not prepare correctly; please verify that your statement is correct."

Symptom

Invalid SQL because single quotes are stripped off.

[{"Product":{"code":"SSVSEF","label":"IBM InfoSphere DataStage"},"Business Unit":{"code":"BU048","label":"IBM Software"},"Component":"Not Applicable","Platform":[{"code":"PF002","label":"AIX"},{"code":"PF010","label":"HP-UX"},{"code":"PF016","label":"Linux"},{"code":"PF027","label":"Solaris"},{"code":"PF033","label":"Windows"}],"Version":"8.5;8.1;8.0.1","Edition":"All Editions","Line of Business":{"code":"LOB76","label":"Data Platform"}}]

Log InLog in to view more of this document

This document has the abstract of a technical article that is available to authorized users once you have logged on. Please use Log in button above to access the full document. After log in, if you do not have the right authorization for this document, there will be instructions on what to do next.

Document Information

Modified date:
25 April 2025

UID

swg21386517