Index Cocepts in Teradata - response (4) by Qaisar Aftab Kiani
Its the same reason as explained in the thread above. Which part you don't understand?
View ArticleNeed to calculate using LEAD, LAG function - response (4) by mohan.mscss
Here it is.. sel a.empid as a1, min(b.effdate) as leave_start_date, a.effdate as leave_end_date from (sel empid,effdate, coalesce( min(effdate)over(partition by empid order...
View Articlehow to implement scd type2 in BTEQ. (from TEMPORAL TO TARGET) - topic by Rahul88
HI ALL, can anybody tell me how to implement scd type 2 while loading data from temporal table target table in bteq.. Thanks Rahul
View ArticleNeed to calculate using LEAD, LAG function - response (5) by Mathuram
Sel emplid,effdt,empl_status, coalesce(mdiff(est,1,rno),-1) cnn from (sel emplid,effdt,empl_status, case empl_status when 'active' then 2 else 1 end est, rank(effdt asc,empl_status) rno from tab1)t...
View ArticleIndex Cocepts in Teradata - response (5) by sachin.sebastian
Vinay, in a scenario where the hash value of PI and USI are the same, the SI subatble row as well as the base table row will be on the same amp. But still it is a 2 step/ "2 Amp" operation (hit same...
View Articlecasting 6 digit integer to date - response (3) by m_v_anita
Thanks Rajeev and Deiter it works. We changed the script in production.
View ArticleIs it possible to invoke the Utilities inside a SP? - topic by barani_sachin
Inside a Stored Procedure i need to read the values from a flat file and load that into a table and do some operations in that. Likewise i also need to do some transformations in some tables and write...
View ArticleNeed Suggestions - topic by MBR
first of all thanks to seeing my post i am working on EDW we have lookups for to maintaining the keys now i am getting the issue here when i am trying to load the data from staging to target ,here in...
View ArticleNeed to calculate using LEAD, LAG function - response (6) by arbiswas
Yes Dnoeth, It is possible ho have multiple rows for same effdate . In that case latest row will be picked based on SEQUNCE column which has sequnce values.
View ArticleHow to store a field value of a table column into variables in Stored...
Hi Dieter, thanks a lot. I tried it - a part of the stored procedure is following string: SELECT COUNT(*) INTO TotalCount FROM CZ_PRD_STG._V2C_CRM_ACCOUNT_R3; I obtained an error message (LVC_EXP...
View ArticleNeed to calculate using LEAD, LAG function - response (7) by arbiswas
Hi Mohan, your o/p is below. Not matching though a1 leave_start_date leave_end_date 1 000031750 01/01/2009 2 000031750 06/01/2009 3 000031750 23/01/2009 4 000031750 01/02/2009 01/02/2009 5...
View ArticleCalculating the actual query run time - response (1) by rajeev saravanan
Hi , Can any one help me with the above question ? Regards R.Rajeev
View ArticleNeed Suggestions - topic by MBR
first of all thanks to seeing my post i am new to Teradata my Issue is : we have lookups for to maintaining the unique keys in staging we have duplicates values which is loaded into lookups too as a...
View ArticleNeed to calculate using LEAD, LAG function - response (8) by mohan.mscss
Hi Arbiswas, Yes this won't match with your result set which given in the initial post because of the same date is having multiple status(2/1/2009). However executing the query from my end which gives...
View ArticleCalculating the actual query run time - response (2) by CarlosAL
Rajeev: FirstRespTime - StartTime = Total SQL Execution Time. FirstStepTime - StartTime = Parsing & DD Access Time (locks in DD can be shown here). HTH. Cheers. Carlos.
View ArticleCalculating the actual query run time - response (3) by sachin.sebastian
Rajeev, Also refer this thread: http://forums.teradata.com/forum/database/measuring- query-reponse-time
View ArticleHow to store a field value of a table column into variables in Stored...
Hi Dan, i don't know why it's failing. Are you shure it's this statement? This should work: replace procedure cnttest(out cnt int) begin declare x int; select count(*) into x from dbc.tablesV; set cnt...
View ArticleNeed to calculate using LEAD, LAG function - response (9) by dnoeth
Your expected output is probably wrong, the 3rd leave start on 7/1/2010 according to your date not on 7/1/2011. This combines the rows from the first "leave" up to the next "active" row: SELECT emplid,...
View ArticleIs it possible to invoke the Utilities inside a SP? - response (1) by dnoeth
I don't think you can do that in a SQL SP. But an External SP written in C should be able to achieve that. Dieter
View ArticleHow to store a field value of a table column into variables in Stored...
By any chance, are you using SELECT...INTO in a dynamic stored procedure ? If yes, then it would not work.
View Article