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 create a new forum topic.

How many sessions maximum can be assigned Topic by casper 10 hours ago Hi , Thanks for checking this qs We have a system of 8 nodes and 80 amps with 12 PE's. What is the max no of sessions that can be assigned at a given point of time is there any formula for this
30 views
1 reply, 8 hours ago
Alternative to count(*) in Teradata Topic by echoo 21 hours ago Hello All, Is there an alternative to count(*) in Teradata? Is the row count stored in any dbc tables? I have found there is alternatives in MS SQL Server : Select rows from sysindexes where Indid = 2 and Id = (Select object_id('')) I would like to know if there is the same ...
47 views
1 reply, 10 hours ago
Is the mapping of Account String to Performance Group name case sensitive? Topic by monisiqbal 1 day ago A Teradata user can be associated with multiple Account Ids and even on login account ids can be provided, resulting in a Account String to be associated with the running session. If TDWM is disabled, then PSA takes effect. In this case the account string is mapped with PSA's (Performance Schedu...
34 views
1 reply, 18 hours ago
Dynamic Cursor Topic by vinodpilley 08 Jul 2009 Hi i am trying to execute dynamic sql in stored procedure and returning as a cursor. Can somebody
help me to correct below stored procedure. My sql will be much complicated then this one , currently I am using simple one.


REPLACE PROCEDURE pp_get_myCustomers(
u...
997 views
2 replies, 1 day ago
DBQL showing null Operating Environment and System Condition with TASM enabled Topic by monisiqbal 1 week ago TDWM is working and TASM is enabled on the system. I can see WDID in the DBQLogTbl however the OpeEnvId and SysConId are null. How can this be possible? I think that when appropriate SysCon and OpEnv aren't selected then the 'Base' state is selected, which is comprised of 'Normal' SysCon and 'Al...
45 views
1 reply, 1 day ago
What is method or strategy to calculate the CPU utilized in running a Query? Topic by chakdom 8 weeks ago Hi All,

Suppose, i am running a query on teradata database. I want to know how the various components interact in calculating CPU requested/utilized .

Could someone explain in detail?

Thanks in Advance!

Chakri
455 views
4 replies, 1 day ago
difference of values with datatype Time Topic by TD.Aspirant 5 days ago Hi All, I have a table with 3 columns: Start_t time(0), end_t time(0), and duration time(0) I have start_t value as '17:31:10' , end_t as '17:39:07' I want to calculate duration as end_t-start_t => 17:39:07-17:31:10 I am getting the value as '00:07:97' but 97 is invalid seconds...can...
90 views
4 replies, 2 days ago
Sample Function Topic by samit_9999 08 Jan 2007 Hi,

I have an order table which has order details alongwith Product Code as "AS" , "BU" ,"CM","DQ","ER","FN"

I was to select a random of 10 records for each of the product codes "AS" , "CM" and "DQ"

Can i use a "sample" teradata feature to acheive the above ...
14435 views
3 replies, 2 days ago
UDF - 7504 Topic by indrajit_td 6 days ago Hi, I am creating a UDF and it throws the above error message. Bteq: ---- REPLACE FUNCTION ORDERED_CONCAT( value_txt VARCHAR(2048) , delimiter_txt VARCHAR(31) , ordering_key INTEGER ) RETURNS VARCHAR(60000) CLASS AGGREGATE ( 60000 ) LANGUAGE C NO SQL SPECIFIC ORDERED_CONCAT_CCI D...
40 views
0 replies
Monitoring Daily Spool space usage. Topic by Random_Thought 1 week ago Hi, I need to monitor the spool space used throughout the day (every 10 minutes or so). So I can trend the actual usage over the month. I need to verify that we are using 30% or less or else we may hit problems as our data grows up to the 70% usilised mark. Do any of you have any stra...
91 views
2 replies, 6 days ago
Aggregation is so slow..can anyone help me what i have to do? Topic by kumar 1 week ago Hi, Please help me to optimze the below query... Query: SELECT IECMD.MONTH_END_DATE_KEY AS DATE_KEY, AWSP.STORE_KEY AS STORE_KEY, AWSP.PRODUCT_KEY AS PRODUCT_KEY, AWSP.STORE_CODE AS STORE_CODE, AWSP.PRO...
62 views
0 replies
DELETE query is taking too long time in the production.... Topic by kumar 1 week ago Hi, I need your help to identify the issue in the below query to optimize... query : DELETE ADSP FROM ARCPROD.AGG_DLY_STR_PROD ADSP, ARCPROD.INC_ETL_CUR_DAYS INC_ETL WHERE ADSP.DATE_KEY = INC_ETL.DATE_KEY; Here date_key for both ag...
51 views
0 replies
Stored procedures and macros - Perm space Topic by amit.s 1 week ago Macros dont use perm space Stored procedure requires perm space Why?
108 views
2 replies, 1 week ago
Using the FLEX application to pass variables to Teradata SQL Topic by pcavanaugh 1 week ago I am attempting to use the FLEX application as a front end user interface to pass variables to Teradata SQL so only the desired records are returned. I am getting an error that I have been able to duplicate in SQL Assistant that indicates the variables are being passed without single quotes arou...
62 views
1 reply, 1 week ago
varchar concatenation Topic by pierrehenri 1 week ago Hi everyone, I've got some issues with concatenation, here is the code sample : ... ELSE e.pla_rw_place_number_ || 'A' || m.pla_rw_place_number and here is the error 2620 : The format or data contains a bad character If I'm tying to concatenate with 'e' or ',' it works. I presum...
218 views
7 replies, 1 week ago
Calculate AMPs used by a query Topic by rahulraj 1 week ago Hi Gurus, I'm trying to figure out how many AMPs are being used by queries on daily basis. My ultimate goal is to create a report of ALL queries that used all the AMPs available. Is there any way we can do it using pmcpinfo or dbc? - Rahul
83 views
1 reply, 1 week ago
Pros and cons Topic by svs1986 1 week ago Hi Could u please let me know the pros and cons of below mentioned ones for exporting data 1. Using FastExport 2. Using Informatica 3. Using Data extract 4. Using parameter file
36 views
0 replies
Problems with SP compilation Topic by jvycpalek@csob.cz 10 Nov 2009 I have problems to compile any sp with Teradata 13 Express and VS Express 2008 sp1. Compilation of a trivial procedure Replace procedure RETAIL.sp_T() begin declare job char(12); end; fails with *** Failure 5547 Internal Error: Can not find mt.exe The routine exists in Windows S...
808 views
8 replies, 1 week ago
What is used for SYS Calender in sql sever Topic by sanvalys 2 weeks ago There is a syscalender function in teradata from where we can populate the time dimension. Is there any function in Sql server which is same like syscalender in teradata.
92 views
1 reply, 1 week ago
Export resultset to file Topic by praveenjanagam 1 week ago Hi all, I want to write a procedure which will export the resultset to a text file. for example SELECT * FROM table1 The resultset of the above query needs to be written to text file at c:\myfolder\mytextfile.txt . how can i achieve this, pls provide a sample procedure which is synta...
74 views
1 reply, 1 week ago
URGENT : Using SELECT statement in dynamic SQL Topic by balakrishna 1 week ago Hi , I am new to teradata 1) In my procedure i am passing table name (str_sourcetable ) as in parameter 2) Then i need to take the record count from that table (str_sourcetable ) 3) This record count should be the field value for another table (Cfstagedev.Table_Test_automation) whic...
139 views
1 reply, 1 week ago
Error while executing procedure Topic by praveenjanagam 1 week ago Hi all, I am getting the following error while exectuing the procedure . Procedure: ---------------- Replace Procedure CFSysSPDev.AutomatedPassthruValidation(In str_targettable varchar(2000),Out int_recorddiff integer) BEGIN Declare v_strsql varchar(6000); Set v_strsql = 'SELECT * FRO...
52 views
0 replies
'Date' BETWEEN 'select Date' Topic by DaZzL3R 2 weeks ago I want to get month end date of 2 months prior. For instance, if i run the SQL today, i should get 2010-01-31 where the question marks are in the SQL below. Mind you, I cannot use volatile table. "sel (current_date - extract(day from current_date)) - extract(day from (current_date - ext...
194 views
2 replies, 1 week ago
error while exporting resultset to a file in procedure Topic by praveenjanagam 2 weeks ago Hi all, While executing the below procedure iam getting the following error. procedure: ------------------------ Replace Procedure CFSysSPDev.AutomatedPassthruValidation(In str_sourcetable varchar(2000), In str_targett...
44 views
0 replies
Teradata Manager - No Profiles Topic by nithyanandam 15 Jan 2008 Hi

I installed Teradata Manager, accepting all the defaults during installation. I was able to login to the Teradata Manager right after the installation without any issues. But, When I try to access Teradata Manager, I receive the following error:

Fatal error: No profi...
18192 views
10 replies, 2 weeks ago
You must login to create a new forum topic.