v15.10.3 - commit processing - response (5) by dnoeth
Teradata Studio 14.10 vs Studio Express 15.10 - forum topic by ruyeh00
Can someone tell me the pros and cons to upgrading or downgrading from Teradata Studio 14.10 to Teradata Studio Express 15.10? I'm generally dealing with multiple Teradata DBs and on a daily basis routinely running queries that are > 1 Billion records. I also have all of the Enclipse plug-ins installed for my Studio 14.10 version.
Teradata Studio 14.10 vs Studio Express 15.10 - response (1) by fgrimmer
Ryan, There is a DevX article on the differences between Studio and Studio Express, called Teradata Studio Products - Choosing the Right Client Tool (http://developer.teradata.com/tools/articles/teradata-studio-products-choosing-the-right-client-tool) that might help with your choice. Basically, Studio Express is a subset of the functionality as provided by Studio. Studio is an administrative tool, so it includes dialogs and wizards to help create and administer database objects. Studio also includes the UDA data transfer wizards.
Teradata Studio 14.10 vs Studio Express 15.10 - response (2) by ruyeh00
Thanks Francine!
v15.10.3 - commit processing - response (6) by tomnolan
To answer Dieter's question about how the Teradata JDBC Driver behaves in TERA mode with autocommit turned off...
First, some background: As part of the wire protocol between the Teradata Database and client interface software (such as CLI, ODBC Driver, JDBC Driver) each message transmitted from the Teradata Database to the client has a bit designated to indicate whether the session has an open transaction or not.
Thus, the client interface software "knows" at all times whether the session has an open transaction or not.
With TMODE=TERA and autocommit off, when the application asks the Teradata JDBC Driver to execute a SQL request, if the session does not have an open transaction yet, then the Teradata JDBC Driver automatically executes a "BT" command before executing the application's SQL request.
Subsequently, with TMODE=TERA and autocommit off, when the application asks the Teradata JDBC Driver to execute another SQL request, and the session already has an open transaction, then the Teradata JDBC Driver won't execute a "BT" command before executing the application's SQL request.
More background: In TERA mode, BT and ET pairs can be nested, and the Teradata Database keeps track of the nesting level. To commit the transaction, ET commands must be repeatedly executed until the nesting level reaches zero. The Teradata wire protocol bit that I mentioned earlier indicates when the nesting level reaches zero.
When the application calls the Connection.commit method in TERA mode, then the Teradata JDBC Driver spins around in a loop, repeatedly executing ET commands until the nesting level reaches zero.
v15.10.3 - commit processing - response (7) by DaveWellman
Hi Tom,
Many thanks for that explanation, at least I now understand what is happening.
Obvious question, is there any way to turn off the 'always execute a BT if no transaction is running' option for the JDBC driver?
This is for a couple of situations:
1) So that I can use Studio (or any JDBC based tool) to correctly test transactions in Teradata mode. At the moment I can't test some scenario's - particularly error ones involving DDL requests. I can test these using Bteq, but it would be nice to test all scenarios in one tool.
2) I teach a number of education courses (for Teradata) and if we cannot turn this feature off then there are a couple of exercises that run which cannot be completed using Studio - and we're trying to move all sql based exercises to Studio.
I can't find a description of the various connection properties anywhere.
- The 'HELP' button on the 'connection properties' dialog screen doesn't appear to do anything,
- the 'help' button on the 'add jdbc property' gives access to the standard studio help information ( which doesn't seem to include this info)
- the Teradata manuals page doesn't seem to have a 'jdbc driver manual'
- a download of the jdbc driver doesn't include anything.
Many thanks,
Dave
Displaying text data on a single line in result viewer - forum topic by DaveWellman
Hi,
Is there a preference available that will display text data on a single line instead of with any embedded line breaks?
This is particularly useful when the column in the result set is SQL text. These are often sent to the dbms with included line breaks. Those line breaks are recorded in DBQL and hence returned to an application which selects that data.
Cheers,
Dave
v15.10.3 - commit processing - response (8) by tomnolan
>>> the Teradata manuals page doesn't seem to have a 'jdbc driver manual'
The Teradata JDBC Driver User Guide, and the other available documentation, is published here on Developer Exchange:
http://developer.teradata.com/doc/connectivity/jdbc/reference/current/frameset.html
>>> I can't find a description of the various connection properties anywhere
Here is a direct link to the section of the Teradata JDBC Driver User Guide that describes the connection properties:
http://developer.teradata.com/doc/connectivity/jdbc/reference/current/jdbcug_chapter_2.html#BABJIHBJ
v15.10.3 - commit processing - response (9) by DaveWellman
Hi Tom,
Ah! That'll be why I couldn't find it with the other TD manuals, thanks for the links.
Cheers,
Dave
Studio 15.10 Data Transfer Wizard does not trigger a transfer job - response (3) by duonglenguyenvu@gmail.com
Dear fgrimmer,
I get the same problem.
Please give me solution to fix it.
Thanks,
Dennis.
Studio 15.10 Data Transfer Wizard does not trigger a transfer job - response (4) by fgrimmer
Dennis, As posted on the Studio article: If you are using 15.10.00.03, there is a bug when copying from Teradata to Teradata. This has been fixed. To workaround this issue, you would need to select your table in the source Teradata system and copy to External File. Then in your Destination Teradata system, use the Data Transfer wizard to launch Smart Loader and create the new table and load the data. If the destination table already exists, then use the Data Transfer wizard to load data from the external file.
v15.10.3 - commit processing - response (10) by tomnolan
>>> correctly test transactions in Teradata mode. At the moment I can't test some scenarios - particularly error ones involving DDL requests.
>>> a couple of exercises that run which cannot be completed
Please provide these scenarios and exercises, so we can recommend a solution for you. Thanks.
Studio Mac OSX Export hangs for a long time - response (2) by jni
I am having the same issue. I am using the "Export the result set to external file" option to try to save the results, but nothing pops up, I was expecting a dialogue box for me to choose file format just as in Windows.
Studio Mac OSX Export hangs for a long time - response (3) by hl186018
Hi jni,
Can you tell me the detail of your issue ? what did you try to do? when it happened, did you see any error in the log?
I have tried Studio 15.10.00.02 on Mac OSX . I run a simple SELECT query and export the data in 2 ways (Teradata Export Wizard and Teradata Result Set Viewer) and both are working fine.
Thank you.
How to load data from a csv file into a table using Teradata Studio - forum topic by zioli
Hi everybody,
someone here may help me on that? I have to load data from a csv file into a table but I have no idea how.
There are about 12 million records into the csv file.
thanks
How to load data from a csv file into a table using Teradata Studio - response (1) by fgrimmer
Fabio, Please refer to the Teradata Studio article (http://developer.teradata.com/tools/articles/teradata-studio) and the section on Data Transfer Wizard and Load and Extract Data.
v15.10.3 - commit processing - response (12) by DaveWellman
Hi Tom,
Sorry, only just saw your last post.
Here is one exercise that we run as part of one of the Teradata Education courses. This works fine with a CLI application (such as BTEQ) but doesn't have the desired outcome when run through TDStudio (because it is using the jdbc driver which inserts additional comands).
The commands that the students are asked to enter are;
EXPLAIN DEL Employee;
BT;
EXPLAIN DEL Employee;
EXPLAIN ET;
ET;
EXPLAIN BT; ET;
CREATE TABLE t01 (x int, y int);
BT;
INS t01 (1, 2);
DATABASE Customer_Service;
SELECT * FROM Employee;
ET;
This breaks down into four parts as shown below. I have also shown th eoutomce of my testing with/without autocommit.
Exercise - part#1
EXPLAIN DEL Employee; <== must have autocommit=on to see 'send the end transaction'
Exercise - part#2
- with autocommit=on (exercise fails)
BT;
EXPLAIN DEL Employee; <== this shows a 'send end transaction'
EXPLAIN ET;
ET; <== fails with TD3510
- with autocommit=off (exercise works)
BT;
EXPLAIN DEL Employee; <== this shows a 'send end transaction'
EXPLAIN ET;
ET;
Exercise - part#3
EXPLAIN BT; ET; <=== this fails with autocommit=on if run as indivdual statements
- with autocommit=on this works if you 'send as single statement'
Exercise - part#4
CREATE TABLE t01 (x int, y int);
BT;
INS t01 (1, 2);
DATABASE Customer_Service;
SELECT * FROM Employee;
ET;
- with autocommit=on the ET command fails with TD3510 error
- with autocommit=off
BT fails with TD3932
INS fails with TD3807 (because the CREATE TABLE was rolled back)
DATABASE command works
SELECT fails with TD3932
ET works
From my testing it looks like the student would have to switch autocommit on/off throughout the exercise. (Maybe that is what now needs to be done).
Cheers,
Dave
Studio Mac OSX Export hangs for a long time - response (4) by rpausch
I'm having a similar problem with 15.10.0.0.3, Windows 7 and Java 1.8. When I click on the export results button in the results window. The button stays pressed and the application hangs for more than a minute. Eventually the application responds, although the export dialog window doesn't open.
When I try a simple query of 2000 results I don't have this issue. When I have results greater than 20,000 it does happen. These are fairly complex queries.
Thank you
Studio Mac OSX Export hangs for a long time - response (5) by fgrimmer
Richard, What database is your result set from, Aster, Teradata, or Hadoop?
v15.10.3 - commit processing - response (13) by tomnolan
>>> the student would have to switch autocommit on/off throughout the exercise.
Yes, that makes sense. Using Studio with the Teradata JDBC Driver is different from using BTEQ. Consider the goal of what your exercise is trying to teach, and determine how best to teach that concept using Studio, which behaves differently from BTEQ.
Here are my suggested modifications to your execrcise:
(Turn on auto-commit)
EXPLAIN DEL Employee;
(Turn off auto-commit)
(With auto-commit turned off, executing a SQL comment will cause the Teradata JDBC Driver to automatically execute a BT command before executing the SQL comment.)
/*begin*/;
EXPLAIN DEL Employee;
EXPLAIN ET;
ET;
(Turn on auto-commit)
EXPLAIN BT; ET;
CREATE TABLE t01 (x int, y int);
(Turn off auto-commit)
(With auto-commit turned off, executing a SQL comment will cause the Teradata JDBC Driver to automatically execute a BT command before executing the SQL comment.)
/*begin*/;
INS t01 (1, 2);
DATABASE Customer_Service;
SELECT * FROM Employee;
ET;
I second Dave, Studio (or JDBC) is definitely not working as expected.
After switching on DBQL one can easily prove what's actually sent to TD, both "autocommit" and "no autocommit" do unexpected things.
I logged on with a new session both times, this is the sequence from DBQL sent for "no autocommit" and the info from Studio:
BT
-- this was not in my code
set query_band = 'test=tdstudio no autocommit;' for session;
STATEMENT 1: SET completed. 0 rows processed. Elapsed time = 00:00:00.330
bt;
STATEMENT 2: BEGIN TRANSACTION failed. Failed [3932 : 25000] Only an ET or null statement is legal after a DDL Statement.
-- wrong, this rolls back the queryband to NULL
BT
-- this was not in my code
database teradata_education;
STATEMENT 2: DATABASE completed. 0 rows processed. Elapsed time = 00:00:00.336
select * from dbc.dbcinfov;
STATEMENT 3: Select Statement failed. Failed [3932 : 25000] Only an ET or null statement is legal after a DDL Statement.
BT
-- this was not in my code
et;
STATEMENT 3: ET completed. 0 rows processed. Elapsed time = 00:00:00.117
As I understand "no autocommit" should simply send the SQL as-is without any additions.
And this for "autocommit":
set query_band = 'test=tdstudio autocommit;' for session;
STATEMENT 1: SET completed. 0 rows processed. Elapsed time = 00:00:00.305
Unavailable
STATEMENT 2: BEGIN TRANSACTION completed. 0 rows processed. Elapsed time = 00:00:00.241
The QueryText is unavailable, but StatementType shows Begin Transaction
ET
-- this was not in my code
database teradata_education;
STATEMENT 3: DATABASE completed. 0 rows processed. Elapsed time = 00:00:00.048
select * from dbc.dbcinfov;
STATEMENT 4: Select Statement completed. 3 rows returned. Elapsed time = 00:00:00.119
et;
STATEMENT 5: ET failed. Failed [3510 : 25000] Too many END TRANSACTION statements.
And how is "autocommit" in Teradata mode supposed to work?