#DateForumTypeThreadPost
402814 Oct 2015 @ 05:30 PDTDatabaseReplyObject names length for tablename col. in dbc.tables is still 30 char in TD 15You do what is recommended since TD12, utilize the V-Views instead of the old legacy version: select * from dbc.TablesV
402714 Oct 2015 @ 12:10 PDTDatabaseReplyAll amp duplication issueIt seems like you unpivot a denormalized table with one column per weekday into seven rows, is this correct? This would result in 133,184,000 * 7 rows.   The small table is duplicated, ...
402613 Oct 2015 @ 11:00 PDTConnectivityReplyProblems using SET QUERY_BAND from ODBCYou can also set the session mode in your ODBC connection string. Which tool are you using for submitting the queries?
402513 Oct 2015 @ 10:58 PDTDatabaseReplyTeradata password expiry extention-what went wrong here ?Hi Samir, MODIFY PROFILE doesn't require a restart, otherwise profiles would be useless. Strange...
402413 Oct 2015 @ 10:55 PDTDatabaseReplyLeft join with no columns selected from right table Hi Samir, both the same result set only when the inner table's join column is unique. This factt is unknown to the optimizer unless it's defined with a USI/PK. But when you add DISTINCT i...
402313 Oct 2015 @ 10:44 PDTDatabaseReplyTeradata password expiry extention-what went wrong here ?Are you sure you modified the correct, i.e. the user's profile?
402213 Oct 2015 @ 09:52 PDTDatabaseReplyCount Consecutive Days that we did not receive a file for a SKUUsing OLAP functions this might be something like this: select t.*, max(case when file_rcv_flag = 1 then cal_dt end) over (partition by sku_id order by cal_dt row...
402113 Oct 2015 @ 07:46 PDTConnectivityReplyProblems using SET QUERY_BAND from ODBCCan you check if your ODBC session is connected using ANSI transaction mode?
402013 Oct 2015 @ 07:45 PDTToolsReplyIssue with muting column names in bteq export fileAdd (TITLE '') to each column, e.g. select metric (TITLE ''),count(*) (TITLE '') from tab2;  
401913 Oct 2015 @ 07:44 PDTDatabaseReplyREcursive processIf the number of levels is known, small & fixed you can utilize one left join per level. Otherwise eecursion can be replaced by a WHILE loop in a Stored Procedure, but why would you want that?
401813 Oct 2015 @ 07:40 PDTDatabaseReplybteq output taking lot of timeHi Amit, is this exported over a slow network?
401713 Oct 2015 @ 07:32 PDTDatabaseReplyCount Consecutive Days that we did not receive a file for a SKUSimply change the logic to: having Days_missed > 0 or Days_missed is null Do you actually need the LEFT JOIN, this will return all rows? In that case you might better rewrite it using OLAP...
401612 Oct 2015 @ 03:54 PDTDatabaseReplyWithin transaction, how to find keys from one table and use those to delete from other tables in a single request?Either repeat the subquery multiple times and run all the DELETEs as a Multistatement Request using BEGIN/END REQUEST (the optimizer should create the result only once) or use a Global Temporary Ta...
401512 Oct 2015 @ 03:52 PDTDatabaseReplyCreating derived query from 2 different tables / 3707 Syntax errorThere's no qualified names in the column list: with drvd_qry (operating_unit, grp_brn_id, stn_id, glt_seq) as
401411 Oct 2015 @ 08:08 PDTDatabaseReplyIssu With Decimal DatatypeThe cast fails due to too many digits in your input string.  TO_NUMBER('0.299999999999999988897769753748434595763683319091796875') doesn't fail in cases like that.
401311 Oct 2015 @ 02:13 PDTDatabaseReplyNo spool spaceAre you sure that YR_KEY and WK_KEY are unique within your calendar, i.e. one row per year/week? Can you show both Explains?
401211 Oct 2015 @ 02:09 PDTDatabaseReplydrop/create table stored procedureHi Joe, it's impossible, each DDL must be submitted individually (and there's no REPLACE TABLE).   Assuming the definition changes (otherwise simply DELETE it) you might use followi...
401106 Oct 2015 @ 02:13 PDTDatabaseReplyextracting valuesIf it's not working with Teradata Studio it might be related to the session mode, JDBC defaults to ANSI while OLDC/.NET/CLI uses the system's default. Try changing the JDBC Connection Prop...
401006 Oct 2015 @ 01:06 PDTDatabaseReplyHow to calculate last seven days Total You need to add a WHERE-condition: WHERE datecol BETWEEN CURRENT_DATE - 6 AND CURRENT_DATE  
400906 Oct 2015 @ 01:04 PDTDatabaseReplyCount Consecutive Days that we did not receive a file for a SKUYou need conditional aggregates: select sku_id, max(case when file_rcv_flag = 0 then cal_dt end) as Last_Date, Last_Date - max(case when file_rcv_flag = 1 then cal_dt end) as Days_Missed...
400806 Oct 2015 @ 10:59 PDTDatabaseReplyextracting valuesHi Siva, please post new questions as a new topic. Q1 is a simple aggregate: select emp, min(phone), max(phone) from tab group by emp   Q2 needs LAG, which is not implemented in Ter...
400706 Oct 2015 @ 10:49 PDTDatabaseReplyextracting valuesIt doesn't matter if INSTR is highlighted in Studio, if you're on TD14.10 it's supported. You simply got a syntax error, there's a missing comma: substring (col_name from INSTR(...
400606 Oct 2015 @ 03:41 PDTDatabaseReplyextracting valuesWhat's your TD release? INSTR is supported since TD14.
400505 Oct 2015 @ 03:28 PDTDatabaseReplyextracting valuesIf it's always delimited by spaces you can utilize INSTR to find the last space and SUBSTRING to return the following characters:  SUBSTRING(col FROM INSTR(col, ' ', -1, 1) +1 F...
400401 Oct 2015 @ 11:13 PDTToolsReplyTTU for Mac OS Hi Sean, TDWallet for OSX is only available as part of the TTU-install. Afaik it can't be downloaded from DevEx, if you're a customer ask your DBA to get it from T@YS.

Pages