#DateForumTypeThreadPost
60304 Aug 2009 @ 04:13 PDTToolsReplyHow to COLLECT STATS in BTET Mode in Multi-Statement BTEQ Scripts!In BTEQ there's no need to use BT/ET for a multistatement, because it's already a transaction.COLLECT STATS is considered as a DDL statement, thus it's not allowed within a multistatement unless it...
60204 Aug 2009 @ 04:04 PDTToolsReplyHow to compile pp2c file using visual studioHi Shrihari,when you're running Teradata Express you should install the matching TTU 12 and check the matching manuals for TD12 (it's on the DVD).The name of the exe changed to ppcmain.exeDieter
60104 Aug 2009 @ 03:52 PDTDatabaseReplyMulti-row INSERTsHi Steve,you're correct, Teradata doesn't support that syntax.But you might submit a multistatement-request (MSR), BTEQ it's:Insert into CALL_DETAILS (id, start_time, comments)VALUES (123, 12:45, ...
60004 Aug 2009 @ 03:40 PDTDatabaseReplyIgnoring duplicated rows and keep inserting.Hi Anderson,which tool do you use?Does it stop after the dup row and doesn't finish? Most tools allow a setting to ignore errors.Or you just don't want that error message? AFAIK there's no way to a...
59904 Aug 2009 @ 03:33 PDTAnalyticsReplyRelease Lock from a TableRELEASE LOCK doesn't remove SQL locks but MLoad/ARC locks. There's no way to release a lock before the transaction is finished.Do you have access to PMon to check for locks?Are there concurrent qu...
59804 Aug 2009 @ 03:20 PDTUDAReplySQL - Combine Two rows in to OneIs the combination UserID/Status/ProductID unique?Then it's a Full Outer Join:SELECT COALESCE(t1.t_id,t2.t_id), COALESCE(t1.prod_id,t2.prod_id), t1.t_date AS start_date, t2.t_date AS end_dateF...
59704 Aug 2009 @ 02:56 PDTDatabaseReplyGrouping partially correlated dataHi Kevin, to me it seems a very strange report, are you shure its not confusing? It's easy to get using OLAP functions: SELECT COALESCE(t1.inpatient_data_id,t2.inpatient_data_id), t1.t...
59604 Aug 2009 @ 10:50 PDTToolsReplyFastload not handling VARCHAR field in Linux?The table definitions differ: ORG_STN_BA_CD ORG_CITY_BA_CD DEST_STN_BA_CD DEST_CITY_BA_CD are all defined as CHAR(1) but it's LATIN in the source table and UNICODE in the target. Dieter
59531 Jul 2009 @ 02:13 PDTDatabaseReplyPartitioning by a character columnPartitioning by chars is not possible, yet. Thus you can't use any character functions like POSITION for partitioning.There's a trick to bypass that restriction, but i doubt it's really usefull:e.g...
59431 Jul 2009 @ 02:01 PDTDatabaseReplyTab in columnThere's a CHAR2HEXINT function which return a hex-string, e.g.select char2hexint('bla'); *** Query completed. One row found. One column returned. *** Total elapsed time was 1 seconds.Char2HexInt('b...
59331 Jul 2009 @ 01:56 PDTDatabaseReplyKILL Teradata Database SessionIf your on TD12 you might use the syslib.AbortSessions UDF.Before TD12 there's no way to kill a session using SQL, you have to use the PMon-API or some command line tool.Dieter
59231 Jul 2009 @ 01:54 PDTDatabaseReplyImport Problem - Date fieldHow do you try to import it?BTEQ/FastLoad/MLoad/TPump/SQL Assistant?Instead of changing the format in your input file you might simply add a FORMAT in the INSERT.Dieter
59131 Jul 2009 @ 01:51 PDTDatabaseReplyHow to check if data is in upper case or notHi Venkatesh,why do you need to know about that?If you need it in uppercase just use the UPPER function or define the column as UPPERCASE.Dieter
59031 Jul 2009 @ 10:48 PDTDatabaseReplyLock InfoThe only way to see all locks is the Lock Display (lokdisp) command line utility. If you want to know if a query is blocked you might use PMon or (in TD12) write some queries using the Open API ...
58931 Jul 2009 @ 10:44 PDTDatabaseReplySQL Is the first or the second ins/sel faster? How do you measure it? Unless one ins/sel is into an empty table and the other into a populated table there will be no difference. Dieter
58831 Jul 2009 @ 10:41 PDTToolsReplyFastload not handling VARCHAR field in Linux?Where do you spot that field length in the above file dump? Could you post the actual table definition and the FastLoad output (especially the DEFINE)? And, as Steven already asked for, a sample ...
58730 Jul 2009 @ 08:02 PDTToolsReplyMLOAD with secondary indexBased on the indexname i guess MLoad complains about a USI. And yes, it is possible, you can do the drop within the laod script, too. Just have a look at the MLoad manual. Dieter
58630 Jul 2009 @ 12:10 PDTDatabaseReplySample duration in DBQLSummaryTbl It's for all DBQL tables, but the probability that the summary cache will overflow is much lower due to less data. Dieter
58529 Jul 2009 @ 12:03 PDTDatabaseReplyCPU usage of PE and RSG?You're looking for the VprType column in ResUsageSVpr: Type of vproc. In non-Summary Mode, the values can be “NODE,” “AMP,” “PE,” “GTW,” “RSG,” or “VSS”. In Summary Mod...
58429 Jul 2009 @ 11:56 PDTDatabaseReplyTeradata 12 and SubqueriesIn most cases a Scalar Subquery might be rewritten as a Left Outer Join. But your query is even easier (untested): SELECT component_location_id, component_type_code, AXLE, SIDE, TRUCK ...
58329 Jul 2009 @ 11:38 PDTGeneralReplyHandling Gaps in Date Ranges.Cursor in Teradata are really worst case, sequential processing in a parallel database, so it's a good ideas to avoid them :-) Out of curiosity, why do you use a BTEQ script instead of an SP? ...
58229 Jul 2009 @ 04:50 PDTToolsReplyDATA MOVER TOOLIf you search on the docu site www.info.teradata.com you'll find a manual: http://www.info.teradata.com/eDownload.cfm?itemid=090580001&type=TD Dieter
58129 Jul 2009 @ 04:26 PDTDatabaseReplyIOWAIT on Teradata systemsI just checked it, according to the recommendations CPUIoWait should be even less than 10% when the system is 100% busy. But this was some years ago before the new Linux system, i don't know if thi...
58029 Jul 2009 @ 03:32 PDTGeneralReplyHandling Gaps in Date Ranges.Uh oh, this is a hard one. If i hear "cursor", i usually think about OLAP-functions. But this is probably not possible using those (at least not without nesting several levels). Then i thought, "...
57929 Jul 2009 @ 03:25 PDTDatabaseReplyIOWAIT on Teradata systemsOf course a high IOWAIT is bad, but It mainly depends on the duration. Some peaks might be ok, e.g. if you run large loads. Do you know what kind of work is going on during that time? Dieter

Pages