All Forums Teradata Studio
samsterling 10 posts Joined 06/09
06 Mar 2013
Liberties with SQL - minor issue

I have a script that generates SQL to COLLECT STATISTICS.
When I highlight the result set and copy it to a scrapbook, it puts " around my commas and makes it unrunnable.  This does NOT happen if I export the result set to a text file, copy it, and then paste it in a scrapbook.
Here's an example:
collect statistics on DEV_P2P_T.P2P_FACT_JU index ( "PO Num "
",""PO Version Num """
...
",""LA Inv Line Nbr """
",""MRC Name """
);
 
The behavior I get using SQL Assistant and using the export result set is like this:
collect statistics on DEV_P2P_T.P2P_FACT_JU index ( "PO Num "
,"PO Version Num "
...
,"LA Inv Line Nbr "
,"MRC Name "
);
 
 
 

Sam
fgrimmer 553 posts Joined 04/09
06 Mar 2013

How are you doing the copy from the Teradata Result Set Viewer? The Copy Cells menu option will copy the contents of the cells to the clipboard and you can paste into the SQL Editor. It puts (as default) a comma to separate the cells, but no quotes? You can change the default copy delimiter in the Result Set Viewer preferences

samsterling 10 posts Joined 06/09
13 Mar 2013

Got it.  Thanks.

Sam

You must sign in to leave a comment.