Hello All,
I currently have a DStage job that simply reads a flat file and inserts the data into an SQLServer database, via an ODBC Stage. The problem that I am having is that SQLSever expects all string datatype values to be enclosed with single quotes (').....while DStage, by default, encloses all string values with double quotes (") when inserting into a table.
The question is how, if at all possible, can I specify in DStage to use single quotes instead of double quotes?
Your response will be greatly appreciated.
HAPPY HOLIDAYS!!!!!
String Conversion - SqlServer Target ODBC
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 2
- Joined: Fri Dec 22, 2006 9:14 am
Welcome Aboard
By specifying (') in the quote character box in seqential file stage properties.
By specifying (') in the quote character box in seqential file stage properties.
Last edited by DSguru2B on Fri Dec 22, 2006 9:38 am, edited 1 time in total.
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.
Welcome Aboard, matey! :D
Did you try clicking on the 'Get SQLInfo' button on the General tab of the ODBC stage? That should query the database and set that option automatically for you based on what it finds the target needs.
Failing that, you should be able to manually change the Quote character there to a single quote, I would think.
Did you try clicking on the 'Get SQLInfo' button on the General tab of the ODBC stage? That should query the database and set that option automatically for you based on what it finds the target needs.
Failing that, you should be able to manually change the Quote character there to a single quote, I would think.
Last edited by chulett on Fri Dec 22, 2006 9:39 am, edited 1 time in total.
-craig
"You can never have too many knives" -- Logan Nine Fingers
"You can never have too many knives" -- Logan Nine Fingers
Re: String Conversion - SqlServer Target ODBC
Either way, now he has both the answers. Can work/play with both the options
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Is it really a single quote, or a back tick ( ` )? Anyway clicking the GetSQLInfo button in the ODBC stage will load the correct character and, as a useful side effect, prove connectivity to the data source. Error-free (silent) execution equals good connection.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.