All Forums

Topics related to the Teradata Database, excluding database connectivity (e.g. JDBC) and extensibility (e.g. UDFs) . Typical topics are about SQL syntax and usage (SELECT, GROUP BY etc), database performance, use of database functions, comparison with / migration from Oracle or DB2, and generally why the Teradata Database rocks. For articles, blogs and more, see the Database section of the site.

You must login to post to the forums.
Teradata Implicit Casting Topic by agnit.chatterjee1988 18 hours ago

Hi,
I was just curious to know what would happen when 2 columns with different data types integer and byteint is joined together?
According to me the byteint should be converted to integer. However I believe I read somewhere that they are both converted to FLOAT.
Please help.  

37 views
3 replies, 1 hour ago
ALTER TABLE on UNICODE character type issue Topic by anil_athalye 5 hours ago

Hi,
I am trying to EXTEND the length of datatype varchar of unicode character set from existing 18 to 40. However, it is giving me an error
3558 Cannot alter the specified attribute(s) for %VSTR.
It displays the same error on an empty table. 
I am using TD 15.00. 
Has anyone faced this issue? Does anyone know the solution on this?
 
Thanks,

11 views
1 reply, 2 hours ago
Can we pass object as parameter in a macro ? Topic by Deepakji 9 hours ago

For eg : 

replace macro database1.macro1(databasename char(50),tablename char(50))

as

(

Select count(*) from :databasename.:tablename;

20 views
2 replies, 7 hours ago
Resource Monitoring While Running Sql querries Topic by bhushan.koli 4 days ago

How to mointor CPU,Memory,and KB/sec  while running querries in teradata 

28 views
3 replies, 7 hours ago
When to use Join Index Topic by agnit.chatterjee1988 9 hours ago

Hi ,
What are the indications from the explain plan of a query that might indicate we should use a JI [ aggregate,sparse,single table or multi table ]?
Thanks,
Agnit

7 views
0 replies
rows unbounded preceding Topic by TdMan 10 Jul 2007

Can anyone tell me what this statement is used for? I found this as a reply to one of the query in this forum.

47331 views
8 replies, 10 hours ago
Read Timezone Without ':' Character Topic by sumaps 21 hours ago

Hi,
 
I have a source data column that has a timestamp with timezone in the below format:
Mon, 5 Mar 2015 08:23:00 -0800 (PST)
I am trying to cast this as timestamp(0) with timezone FORMAT 'DD-MMM-YYYYBHH:MI:SSBB.S(F)Z'.

16 views
1 reply, 11 hours ago
Fetch multiple columns from cursor Topic by jwah 19 hours ago teradata, cursors

Hi,
I am try to use a cursor to loop through multiple values, which is fine if I only use one column.
It doesn't seem to work if I try to fetch more than one column.
e.g.

DECLARE var_a VARCHAR(10);

DECLARE var_b VARCHAR(10);

DECLARE var_c VARCHAR(10);

 

DECLARE crsr CURSOR FOR

SELECT col_a, col_b, col_c FROM schema.mytable;

6 views
0 replies
Need information about Topic by Jayant2306 1 day ago

Hi All,
I am trying to tune a query.
Basically I joinning two table A,B on columns Col1. both having different Indexes
Example: select * from Table1 A
inner join Table2 B
on A.Col1 = B.Col1
and A.Col2 = B.Col2
In table A Col1 is defined in Join Index and in Table B Col1 is defined as SI.
and Col2 is not defined as any Index types..

9 views
1 reply, 22 hours ago
43 views
7 replies, 23 hours ago
How to convert the varchar to time(6) In Teradata? Topic by urskumar 4 days ago

Hi Experts
 
I have time value in the source with the datatype varchar(100), Need to conver this to time(6).
 
values with the varchar 11:30, 12:30: 01.00 like this...Need to convert these values to Time(6)
 
 

29 views
2 replies, 1 day ago
Create NUPI and USI having the same Column Topic by hyma 1 month ago

Hi
Under which circumstances does it make sense to define NUPI and USI having the same column?
It sounds curious, isn't it?
Thanks.

91 views
6 replies, 1 day ago
Padding and timestamp Topic by krishna1985 4 days ago

Hi All,
 
I have a column with the format
column x and beow are the values. 
10/1/15
4/1/16
7/1/15
I want to convert the same into 2015-01-10 00:00:00 and same for others. I want to pad month  AND date to 0 if its single digit. I tried run the beow substring first

52 views
3 replies, 1 day ago
How to install Teradata Express on Windows 7 64 bit machine? Topic by adiideas1 28 Feb 2013 teradata express

Folks,
 
I am new to teradata and to this forum. I am looking to install Teradata Express on my laptop.
On the downloads.teradata.com, it says VMware is to be installed but link is not active for Windows 7 OS.
If anybody can provide some pointers, it would be great.
 
Thanks
Adi
 
 

4219 views
6 replies, 2 days ago
Set QueryBand as JDBC Connection Parameter Topic by dfranks44 4 days ago jdbc, query_band

Hi all,
I would like to perform query banding at the connection level.  We are trying to track down a blocking issue, across a couple hundred, that are all hitting a single metadata table.  A few are not playing nice and we would like to use query banding to narrow it down.
 
I am currently trying the following but it doesn't seem to be working:

58 views
4 replies, 3 days ago
SQL command for setting connection option to return generated keys Topic by sdc 1 week ago

Hello,
I am setting the following parameter in a connection string:

33 views
2 replies, 4 days ago
Resource Monitoring While Running Sql querries Topic by bhushan.koli 4 days ago

How to mointor CPU,Memory,and KB/sec  while running querries in teradata 

12 views
1 reply, 4 days ago
Updating second row value to new column first row Topic by ashokn1989 4 days ago

Hi
 
I have a table
Id        rn            col1          col2         new_col
aa         1            592           650  
aa         2             750           800    
bb         1              250          600  
bb         2            300            null
 
output is
Id        rn            col1          col2         new_col

16 views
0 replies
How to make substring with the second or third occurrence of a charater Topic by zorbax19 25 Oct 2013

Hi,
I would like to take part of the string below by specifying a delimiter and an  occurrence.
EQN = AAL53CCW_400-5-13-3
If I want to recover what is on the left of the first occurrence of  '-' I can write SUBSTRING (EQN FROM 1 FOR POSITION ('-' IN EQN) - 1) which gives me  'AAL53CCW_400'

12842 views
8 replies, 4 days ago
Use teradata with jmeter Topic by bhushan.koli 5 days ago

How to use jmeter with teradata to get performance stat?

29 views
3 replies, 5 days ago
81 views
4 replies, 5 days ago
How to use regex in Teradata or 'LIKE' operator in teradata Topic by netuser 15 Jan 2014 #teradata, #sql

I have a table tab1 with structure as-

    columnName | datatype
          col1 | VARCHAR  
          col2 | VARCHAR
          col3 | VARCHAR
          col4 | VARCHAR
          col5 | VARCHAR

 and sample data as

5428 views
5 replies, 5 days ago
Teradata Query-URGENT Topic by Kuldeepg92 5 days ago

There is table with coulmns:
INTL_EMP_ID
PRSCT_FILL_ID
ACTVTY_TS
EMPLYE_NBR
EMP_ID
 
Problem Statement: select INTL_EMP_ID from table for that PRSCT_FILL_ID.
order by ACTVTY_TS in ascending order and get the first EMPLYE_NBR and its corresponding EMP_ID.
 
Thank you.
 

36 views
2 replies, 5 days ago
SQL Error on 'Create Table' in Terdata SQL Assistant Topic by ap0167 5 days ago teradata

why I am getting a syntax error?
 
create TABLE  ddwp_v.sponsoredm, CHECK = DEFAULT
(account VARCHAR(12)
 Unique Primary INDEX(account);
insert into ddwp_v.sponsoredm
VALUES(?);

 

21 views
1 reply, 5 days ago
terdata query. Topic by Kuldeepg92 1 week ago

 The gender with the minimum number of students should only pair with opposite gender. The remaining students of the opposite gender can pair among themselves.
 
1.       One student can only be paired with another student.
Ie, if (stud1,stud2) pair exists, there cannot be another pair (Stud1,Stud3) or (Stud3,Stud1)
 

60 views
5 replies, 6 days ago

Pages