Hi, I have few questions on Teradata Studio that I installed just couple of days ago.
1) How do I copy the answer set in excel by using 'copy and paste' ? If I do that, it puts the whole row in 1 cell. I do not have this problem with SQL assistant.
2) Is there any way so by default it only executes the 'selected' query and not all the queries written in that editor >
3) Is there any way I can just right click on the SP name and get the defnition of it rather than doing 'Generate SQL' and follow different steps to get the defintion.
I am very much used to SQL assitant and do this kind of things really easily but having hard time with studio. Help me out if that is possible.
1) There is a Result Set Viewer toolbar button where you can export an answer set to Excel. Select the result set tab and click on the Export icon.
2) Currently you have to select the SQL statement and then Execute Selected Statement or use the sequence Alt+X.
3) Yes, double click on the stored procedure to see its definition in a SQL Editor window. You can also right click and choose Edit option, which will also show the SQL in the SQL Editor window. You can run the stored procedure by right click then Run. You can also open the stored procedure in the Teradata View and click the SQL tab.
I hope that helps.
Also, what about shortcut keys? As in SQLA, F5 and F6 for run query and explain query. F11 for last error, things of that nature.
Formatting a query when pasted in the query window....
Unless these type of things are available in Studio, I would rather stick with SQLA ...
Yes, you can import SQL Assistant history. In the Teradata SQL History view window, click on the Import History toolbar option. This will launch the Import History dialog. Choose the SQL Assistant History option in the Source Type.
There are shortcut keys in Studio.Within the SQL Editory window, F6 will perform an Explain. We are adding F5 for execution in the next release. You can manually add key bindings as well in the Key Bindings Preferences page. Go to Window>Preferences and open General>Keys. Page down in the Command list to Execute and change the binding to F5. We do not have F11, but we parse the SQL statements in the SQL Editor and flag errors in red. You can also open an Outline view window that will show an outline of the SQL Statements to help find nested statements.
There is a SQL Format command in the Tools menu, Ctrl+SHIFT+F. You can set the formatting options in the SQL Formatter Preferences page.
having difficulty with using multiple SQL Editor windows with multiple connections. In SQL Assistant, i could have different queries in each window. When I open new windows in Studio, it puts whatever query in the current windows in all the other windows!! Do I have something configured incorrectly or is it operator error?
Thanks and Regards,
The "New Editor" menu item is confusing and is being renamed in future versions. What it does is duplicate the current editor. This gives you the ability to have a large file open in two editors that are displaying different parts of the file. Changes in one editor will be reflected in the other. (The menu item will be renamed "Duplicate Editor" in the future.)
What you want to use is the "New SQL Scrapbook" in the File menu. That will be a separate editor. (This menu item is being renamed "New SQL Editor" in the future.)
Having problems with multiple Result Set windows. Even from single query it shows new window from each successful run! There are a lot af them already! =)
If there is a way to connect SQL Window and Result Set window One-to-One (not One-to-Many) or even give results in single window?
Andrey, Yes. In our 15.00 version of Studio and Studio Express, you can link (or associate) a SQL Editor window with a Result Set Window. On the toolbar of the Teradata SQL Editor there is an 'link' icon. By default, it will associate the first SQL Editor with the first Result Set Window. Then when you focus on a SQL Editor, click the 'associate' icon and it will bring focus to the Result Set Window. If there is not a one-to-one association, press the associate icon and it will allow you to choose the Result Set to associate with the SQL Editor.
Thanks! That is rather good!
But is there a way not to open many result windows - to put results only in one window? When Studio is opened for a long time it is very uncomfortable to search for results - there is SO MUCH opened tabs that it's easier to close the whole Result Viewer.
And this "link" button, you know, it is rather small and link operation has no shortkey in preferences... it is unsuitable. It takes long time to click on it and then try to remember which associated result you need from list if there are many... imho of course, but smth shoud be done with it.
What for was multiple result sets for one query made in general? It was for some reason i suppose?