Quantcast
Channel: Teradata Forums - Database
Browsing all 14773 articles
Browse latest View live

Adhoc SQL Request - forum topic by bikky6

Hi I have a scenario like the below. CREATE TABLE DT(PATH VARCHAR(20)); INSERT INTO DT VALUES('A'); INSERT INTO DT VALUES('A--->B'); INSERT INTO DT VALUES('A--->B--->C'); INSERT INTO DT...

View Article


Adhoc SQL request - response (3) by bikky6

Thanks Muthm.It helped a lot.

View Article


System Views DBC.COLUMNSTATS & DBC.MULTICOLUMNSTATS not existig in TD 14 -...

Thanks Fred. Yes it seems I will have to change my application code in order to use these views.

View Article

Loading Fixed Width File using Teradata SQL Import - response (3) by...

Hi Vikas.... Thanks for the reply... Are you sure that this can not be achieved using SQL IMPORT? Because my TL told me to do that using SQL Import.

View Article

I want to separate the full name in two parts - response (6) by 2aravinth

select name,firstname,lastname from ( select position('' in name)-1 pos, name, length(name)-pos rem, case when pos>0 then substring(name,1,pos) else name end as firstname, case when pos>0 then...

View Article


How to define ARRAY of varying length? - forum topic by avishekp.iem

Hi All, I need to create a ARRAY of VARCHAR(100) of varying length whose length would be defined at runtime. The requirement is to have this UDT as INPUT of a stored procedure which will be invoked by...

View Article

Performance consideration in Enabling LockLogger - forum topic by synpey

Hi,  Is there any way to measure performance impact on existing queries with enabling LockLogger?  I'm planning to enable LockLogger in continuous mode to debug deadlock queries. But I'm not sure the...

View Article

Performance consideration in Enabling LockLogger - response (2) by synpey

I mean "estimate", not measure.

View Article


SQL for last year starting and ending dates - response (2) by 2aravinth

select min(calendar_date) starting, max(calendar_date) ending from sys_calendar.calendar where year_of_calendar=2013This will display the Start & End date of the year 2013

View Article


SQL for last year starting and ending dates - response (3) by VandeBergB

The starting dates and end dates for a year are constant, why would you waste cpu cycles trying find max/min.  The year always starts with January 1 and ends with December 31.  If its a leap year you...

View Article

Relation between Statistics and Indexes on a table - forum topic by...

Hi, I have created a table "product" with defination as below, CREATE SET TABLE product ,NO FALLBACK ,     NO BEFORE JOURNAL,     NO AFTER JOURNAL,     CHECKSUM = DEFAULT     (      product_id INTEGER,...

View Article

BTEQ in ANSI mode - response (1) by mayya@teradataforum

Hi, Please anyone reply to my query.

View Article

3707 Syntax error,expected something like a '"||"'or a 'FROM' keyword between...

Hi, I am getting the following syntax error when I am trying to run my Query: 3707 Syntax error,expected something like a '"||"'or a 'FROM' keyword between a string or a Unicode character literal and...

View Article


Data between two tables. - forum topic by samcompda

Hi, I have to use only SQL (Not-Plsql) to input to my tool and I am not sure what function to use. I have two table T1 and T2, need data from T1 for the corresponding T2 key value.    Table T1  Key...

View Article

Data between two tables. - response (1) by samcompda

Tables and requried results again,  Table T1 Key        Description A1          Desc1 A2          Desc2 A3          Desc3 B1          Desc4 C1          Desc5   Table T2 Key          Col1 q1...

View Article


Implementing SCD type 2 using ANSI Merge in teradata - forum topic by terdatau1

Hi, I am trying to implement SCD type 2 using ANSI MERGE. Could anyone please provide a example on how to implement this. I was searching on the web and came across a article which explains SCD type 2...

View Article

REFERENCES PRIVILEGE - forum topic by zigzagdna

  I am running Teradata 14.x on SUSE UNIX, From DBC I had created a user PREMTEST3 and created some tables in PREMTEST3. Now when I add foreign key to table, it gives me error that there are no...

View Article


Get all the counts of the tables in the particular database into a table -...

Hi I have a requirement like I need to get the tablename and their counts of a particular database into a table. I am able to count each table count individually.Can we do it in using SQL only? Regards...

View Article

Implementing SCD type 2 using ANSI Merge in teradata - response (1) by dnoeth

Hi John, you can't do that using a single TD MERGE, you would need an INSERT plus an UPDATE for WHEN MATCHED, which is not supported. But this is exactly why TD added Temporal tables :-)  Dieter

View Article

Get all the counts of the tables in the particular database into a table -...

Hi KVB, this topic has been covered several times, you might use: a cursor plus Dynamic SQL in a Stored Procedure to get the exact count simply extract it from the stats if the count doesn't have to be...

View Article
Browsing all 14773 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>