#DateForumTypeThreadPost
21607 Mar 2012 @ 11:33 PSTDatabaseReplyCalculate business days hours between two Timestamp(6) fields this should give you some hints Select sum(hhmmss) from ( select period(cast(c.calendar_date as timestamp(6)),cast(calendar_date+1 as timestamp(6)) - INTERVAL '0000 00:00:00.000001'...
21507 Mar 2012 @ 04:08 PSTAnalyticsReplyCombining 4 tables and prioritize the data in them? I don't know if I understand all of your requirements and as you don't share concrete DDLs and SQL it remains a lot of guessing... It would save a lot of time if you share ddls etc.....
21407 Mar 2012 @ 03:08 PSTDatabaseReplyOrder of joins in the SQL @Stefans: similar is not the same...   But it is the same! Check below sample code. Both SQLs will show you the same explain and the same results. create table join_order_t...
21307 Mar 2012 @ 12:33 PSTDatabaseReplyCalculate business days hours between two Timestamp(6) fields This can become a very complicated thing. You need a client specific calendar which contains the business day information. Are you only dealing with a local - one city - data...
21206 Mar 2012 @ 11:20 PSTDatabaseReplyOrder of joins in the SQL In generall should the join order not change the result (as long as you do not change logic by changing the order and using different join conditions). The optimizer trys to find the most effici...
21106 Mar 2012 @ 11:16 PSTDatabaseReplyUrgent please --> If then Else condition in BTEQ it's not working like this. check http://forums.teradata.com/forum/database/compare-strings-in-bteq-statement-not-in-sql#comment-19550 might give you a hint how you can achive wh...
21006 Mar 2012 @ 01:02 PSTAnalyticsReplyCombining 4 tables and prioritize the data in them? a possible way to do it 1. check if fourth table is not empty - which means something is to do.     if not exit 4 2. have a tmp table - permanent or volatile - to stor...
20905 Mar 2012 @ 10:17 PSTAnalyticsReplyCombining 4 tables and prioritize the data in them? Hi, from which info do you derive that LL RCL has highest priority? relational ables are not ordered.... Do you know from the values in table 4 in which table these are stored? for e...
20805 Mar 2012 @ 05:19 PSTToolsReplyBTEQ : Missing columns and special characters in flat file export You need to share the table DDL and the bteq script. Otherwise it is just guessing from our side.
20705 Mar 2012 @ 05:15 PSTDatabaseReplySkew Factor Yes, you need to create a new table with a different PI which has a better skew value. You can check the impact of a different PI by using the  hashamp(hashbucket(hashrow(PI COL list)))...
20605 Mar 2012 @ 05:09 PSTDatabaseReplyIdentifying when the last update or insert was done on a particular table... from the manual   LastAlterTimeStamp Returns the time the Data Dictionary row was last updated.     This will be done if the table itself will be changed for e...
20504 Mar 2012 @ 11:44 PSTDatabaseReplyIdentifying when the last update or insert was done on a particular table... In general - no. Usually it is good habit to maintain this info in some meta data columns / tables during the ETL process. LastAccessTimestamp from dbc.tables will not help you as it cov...
20403 Mar 2012 @ 05:16 PSTAnalyticsReplyQuery_Discussion_HELP It is really not clear (at least to me) from your explanation what you are doing and want to achive. You need to share with us the DDL & SQL - if you have privacy concerns change the col...
20302 Mar 2012 @ 10:26 PSTDatabaseReplyFUNCTION versus SPECIFIC FUNCTION check http://forums.teradata.com/forum/database/user-defined-functions
20202 Mar 2012 @ 06:20 PSTDatabaseReplyTO change the century in the MLOAD (i.e 1900 to 2000) Can you share your full line of code? Then we know what you are doing...
20102 Mar 2012 @ 05:10 PSTDatabaseReplyTO change the century in the MLOAD (i.e 1900 to 2000) easiest might be to concate '20' to your date string and use 'YYYY/MM/DD' for the conversion. It is also not advisable to define 'yy/mm/dd' as it has the pontential t...
20002 Mar 2012 @ 01:49 PSTToolsReplyHadoop to Teradata Would be good to have a bit more background info on this. Is it a one time task? Or a regular one? Does this run durring the normal workload or do you have an exclusive batch window for ...
19902 Mar 2012 @ 01:36 PSTDatabaseReplyperformance issue with update query You need to share more info if you want support from other people. Would be good to see The DDL of the table Row counts - whole table, where conditions explain of the statement ...
19802 Mar 2012 @ 12:01 PSTDatabaseReplyperformance issue with update query can you also share the explain? from the plain SQL it should be something like this     1) First, we lock a distinct xxx"pseudo table" for write on  &nbs...
19701 Mar 2012 @ 07:48 PSTDatabaseReplystring contains an untranslatable Which tool do you use? Can you share the table definition? Are the target columns defined with unicode or latin char set? Can you share the load script?
19601 Mar 2012 @ 03:52 PSTDatabaseReplyUNION Vs MSR   again check your explain. I added one row to the target table and checked the explains afterwards.   They didn't change in this test case. So also here the MSR wo...
19501 Mar 2012 @ 12:15 PSTGeneralReplyHow to calculate query cost and compare 2 queries which gives the same result set? As you have SLA on ellapsed time you need to sit together with the workload management people as this is the main area where you have influance on ellapsed time - assuming that you developed the...
19401 Mar 2012 @ 12:08 PSTDatabaseReplyconvert varchar to date check the documentation - snapshot attached. You can not specify M/D/YYYY. You need to specify MM/DD/YYYY and in this case day and month need to be at least 2 digest.
19329 Feb 2012 @ 07:29 PSTGeneralReplyWhich is better GROUP BY, DISTINCT or SET table also check 13.0 release summary (see attachement). Optimzer is getting smarter and sometimes distinct and group by result in the same plan.
19229 Feb 2012 @ 05:29 PSTDatabaseReplyUNION Vs MSR I assume we are talking about an empty target table A. Correct? You should check and compare the explains of both queries. I would expect that the multi statement request is faster. ...

Pages