teradata

Teradata-jdbc: What's the point of using Fastload if java has memory limitations?

邮差的信 提交于 2020-01-05 19:36:33
问题 Here is the link to a sample jdbc Fastload program from the teradata website : http://developer.teradata.com/doc/connectivity/jdbc/reference/current/samp/T20205JD.java.txt It inserts only one row so I modified it to insert 500K rows by replacing the following code : pstmt.setInt(1, 1); pstmt.setString(2, strBuf); pstmt.addBatch(); batchCount++; with : for (int i = 0; i < 500000 ; i ++ ) { pstmt.setInt(1, i); pstmt.setString(2, strBuf); pstmt.addBatch(); batchCount++; } It of course failed

Teradata Database 3130 Response limit exceeded?

隐身守侯 提交于 2020-01-04 09:21:49
问题 [Teradata Database] [3130] Response limit exceeded I have no idea what is causing this random error message. It happens when I am making a call to the database for a SELECT or to execute a stored procedure. I wish I had more information on how to reproduce this, but it appears to be intermittent. What does this error actually mean? What types of conditions could cause this? Edit: I've discovered that the issue goes away when I build my ASP.NET app (vs2012). It's like something related to

Teradata Database 3130 Response limit exceeded?

試著忘記壹切 提交于 2020-01-04 09:21:26
问题 [Teradata Database] [3130] Response limit exceeded I have no idea what is causing this random error message. It happens when I am making a call to the database for a SELECT or to execute a stored procedure. I wish I had more information on how to reproduce this, but it appears to be intermittent. What does this error actually mean? What types of conditions could cause this? Edit: I've discovered that the issue goes away when I build my ASP.NET app (vs2012). It's like something related to

Error after upgrading from Teradata 12 to Teradata 13…terasso.dll

六眼飞鱼酱① 提交于 2020-01-04 03:02:45
问题 We are currently upgrading our Teradata clients from v12 to v13. For that, the old installations of Teradata 12 were uninstalled from the system and TTU13 was installed. After installation when I try to add a ODBC connection using the new Teradata driver, it gives me the following error. Unknown error occurred in terasso library Any help would be highly appreciated. 回答1: You will need to uninstall the Teradata GSS and the Shared ICU Libraries for Teradata 12 and the Teradata 13.x ODBC driver.

Avoid Parameter Binding When Executing Query with SQLAlchemy

时光怂恿深爱的人放手 提交于 2020-01-03 16:23:15
问题 I am using SQLALchemy to execute queries on Teradata. One of the queries I execute is a DDL statement to replace a stored procedure: REPLACE PROCEDURE DEV_MIGRATION_TOOL.UNIT_TEST_NEW_STORED_PROCEDURE() UNIT_TEST_NEW_STORED_PROCEDURE: BEGIN DECLARE V_VAR VARCHAR(50); SELECT 'Hello World!' INTO :V_VAR; END; This SQL statement is assigned to a variable query and is executed by SQLALchemy with the session execute method: def execute_sql_statement(self, query): """Generic method to execute a SQL

Significance of --connection-manager in Sqoop

我怕爱的太早我们不能终老 提交于 2020-01-03 03:21:05
问题 I have written sqoop script to import data from Teradata to Hive. `sqoop import \ --connect $JDBC_URL \ --driver com.teradata.jdbc.TeraDriver \ --username $Username \ --password $Password \ --table $TD_Table \ --hive-import \ --hive-overwrite \ --hive-drop-import-delims \ --hive-table $Hive_Database.$Hive_Staging_Table \ --split-by $Split_Col \ -m $Mapper_Number` Above script gives warning as --connection-manager). Sqoop is going to fall back to org.apache.sqoop.manager.GenericJdbcManager.

SQL Concatenate multiple rows

青春壹個敷衍的年華 提交于 2020-01-02 02:43:13
问题 I'm using Teradata, I have a table like this ID String 123 Jim 123 John 123 Jane 321 Jill 321 Janine 321 Johan I want to query the table so I get ID String 123 Jim, John, Jane 321 Jill, Janine, Johan I tried partition but there can be many names. How do I get this result. Even, to point me in the right direction would be great. 回答1: Unfortunately there's no PIVOT in Teradata (only a TD_UNPIVOT in 14.10). If you got luck there's an aggregate UDF at your site to do a group concat (probably low

How get information from multiple tables using cursor?

允我心安 提交于 2020-01-01 19:49:07
问题 I have a query, that returns multiple tables, something like that: SELECT TableName, DatabaseName +'.'+ TableName, ColumnName FROM DBC.Columns WHERE ColumnName = 'id' And I need to loop through these tables by looking to the information stored in these tables, in order to get only specific tables. I tried something like code below, using 'LOOP' and cursor, but it says that Query is invalid (code have been taken from here): DECLARE cursor_Tables CURSOR FOR SELECT DatabaseName || '.' ||

Read Teradata query into Pandas

元气小坏坏 提交于 2020-01-01 18:19:24
问题 Has anyone found a way to read a Teradata query into a Pandas dataframe? It looks like SQLAlchemy does not have a Teradata dialect. http://docs.sqlalchemy.org/en/latest/dialects/ http://pandas.pydata.org/pandas-docs/stable/generated/pandas.read_sql.html 回答1: I did it using read_sql . Below id the code snip : def dqm() : conn_rw = create_connection() dataframes = [] srcfile = open('srcqueries.sql', 'rU').read() querylist = srcfile.split(';') querylist.pop() for query in querylist : dataframes

Difference between “TOP” and “SAMPLE” in TeraData SQL

谁都会走 提交于 2020-01-01 09:56:10
问题 What is the difference between "TOP" and "SAMPLE" in TeraData SQL? Are they the same? 回答1: From TOP vs SAMPLE: TOP 10 means "first 10 rows in sorted order". If you don't have an ORDER BY, then by extension it will be interpreted as asking for "ANY 10 rows" in any order. The optimizer is free to select the cheapest plan it can find and stop processing as soon as it has found enough rows to return. If this query is the only thing running on your system, TOP may appear to always give you exactly