#DateForumTypeThreadPost
10604 Jan 2011 @ 12:49 PSTExtensibilityReplyUDF - Error 7504This is a UDF generated error. See message manual for explanation. Here is what it says: 7504 in UDF/XSP/UDM %DBID.%TVMID: SQLSTATE %VSTR Explanation: This is a UDF/XSP/UDM generated error. The...
10522 May 2009 @ 09:14 PDTDatabaseReplyThreshold limit exceededYour site has TDWM (Teradata Dynamic Workload Management) enabled. You need to talk to your DBA to find out what the limits are for you or SQL general. Your query is using more resources than your ...
10419 May 2009 @ 10:10 PDTUDAReplyTable Access ControlLet’s assume you have database ‘Michael’ and you are the owner of that database. Assuming that other staff logon to the database as separate users they don’t have access to Michael database...
10319 May 2009 @ 09:08 PDTUDAReplyTable Access ControlI’m not sure of your set up but when you create a table in a database no one has access to the table unless you grant a blanked access to everything in the database to everyone. So normally restr...
10208 May 2009 @ 04:14 PDTDatabaseReplyFor loop problemI assume you created the volatile table outside the stored procedure, because you said you were not getting an error. According to documentation:“If the cursor SELECT statement references a missi...
10130 Apr 2009 @ 06:57 PDTDatabaseReplyRecursion in a stored procedureIs not the where condition of your select supposed to be:where parent_id >= 2;
10027 Apr 2009 @ 05:39 PDTDatabaseReplyFile and indices in TeradataI would suggest you read the Teradata documentation: Database Design, Release 12.0, B035-1094-67A, September 2007. I suggest looking at Section 3: Physical Database Design. That section explains ev...
9924 Apr 2009 @ 09:37 PDTDatabaseReplyWill there be any space overhead for every column in a Teradata Table row based on its datatype?Look at the Teradata documentation: Database Design ( Document: Release 12.0 B035-1094-067A), Chapter 15: Database-Level Capacity Planning Considerations - Base Table Row Format. All the gory deta...
9823 Apr 2009 @ 09:40 PDTDatabaseReplyRecursion in a stored procedureRE: * Teradata procs do not support the "With Recursive" clause of SelectsYou can write a JAVA external stored procedure and submit a recursive select that way (TD12). It’s called just like any s...
9717 Apr 2009 @ 06:53 PDTAnalyticsReplyNeed to cast an invalid date to a validWhat you want to do is to detect the bad date string and convert it to a good one. If the problem is truly just the missing leading zero on the DD or MM field then it is pretty easy. Of course it ...
9616 Apr 2009 @ 05:27 PDTUDAReplyNo Rows foundHmm, simple question, so I wonder whether you really mean that. It's simply:select count(*) from mytable where .... ;If there are no rows that match the where condition it will return zero otherwi...
9514 Apr 2009 @ 11:04 PDTDatabaseReplyHow do we find the typical/average space occupied by column on disk?Using TRIM will truncate trailing and leading spaces in the VARCHAR string. If you want the average length it takes up on disk you don't want to trim the spaces since they take up space also. If yo...
9403 Apr 2009 @ 06:15 PDTDatabaseReplyCHECKTABLE UTILITY -- ERRORYou told it not to place any locks. It checks the dictionary for consistency first. It found a table {0, A2D} hex that had an entry in TVM but there were no table headers for it on any of the AMPs....
9302 Apr 2009 @ 10:05 PDTDatabaseReplyProcedure/ Cursor in TDYou use: FETCH NEXT CUR1 into emp_val, emp_prior;You can just specify your local procedure variables in SQL statements. However if you have a column name that is the same as your local variable n...
9230 Mar 2009 @ 07:28 PDTToolsReplyError for two intersecting queriesI think you want to use the EXCEPT operator not the INTERSECT.
9118 Feb 2009 @ 09:48 PSTUDAReplyEmail ValidationIf you are allowed to write C language UDFs on your system here is one solution. I hate that this forum does not retain the proper indentation, so you will have to just read it the hard way. /*REPL...
9030 Jan 2009 @ 08:48 PSTDatabaseReplyRevoking All Access Rights For UsersHmm, is it not just this statement?:REVOKE ALL PRIVILEGES ON object FROM user_name;for exampe if user name is "sam":REVOKE ALL PRIVILEGES ON sam FROM sam;The only privileges it does not remove are ...
8923 Jan 2009 @ 04:58 PSTDatabaseReplyVertical PivotingOr have a look at this one in this forum.http://www.teradata.com/teradataforum/Topic8112-5-1.aspx?
8815 Jan 2009 @ 05:33 PSTDatabaseReplyOracle RefCursor concept in Teradata stored procedureIn TD 12 you can define DYNAMIC RESULT sets. See the following thread on the subject in this same topic.http://www.teradata.com/teradataforum/Topic13703-9-1.aspx
8709 Jan 2009 @ 05:50 PSTDatabaseReplyCount on number of cursors openedThe operative term is “open cursors”. When you finish the outer FOR cursor loop you will have no open cursors. So you have 15 to use again. The 16 th one is used for the stored procedure respon...
8608 Jan 2009 @ 09:45 PSTDatabaseReplyTeradata equivalent of Oracle RAISE_APPLICATION_ERROR or MS SQL RAISERROR?In addition to what Joe posted, TD_GENERAL parameter passing style does not have an “error_message” return argument. Look at the documentation again. Your C prototype must match what the docume...
8523 Dec 2008 @ 05:10 PSTDatabaseReplySUM QuestionTry a the HAVING clause SELECT gr, SUM(chrg_amt) GROUP BY gr HAVING SUM(chrg_amt) <> 0 ORDER BY gr;
8419 Dec 2008 @ 08:32 PSTDatabaseReplyany Acer for Stored Procs ? How to escape quotes in SP parameter. PL HELPI don’t understand your difficulty or maybe your question. Suppose the stored procedure has two parameters such as (IN p1 VARCHAR(100), IN p2 VARCHAR(100))You just supply the strings to the two p...
8318 Dec 2008 @ 09:24 PSTDatabaseReplyany Acer for Stored Procs ? How to escape quotes in SP parameter. PL HELP' blah blah , account=(''$d$metc'') ;' That is two single quotes to escape a quote. You don't need an escape for a comma.
8211 Dec 2008 @ 08:34 PSTToolsReplyusing OREPLACE functionTry:SELECT ID, OREPLACE(ColA, ‘1A’XCV,’’) FROM test_tbl;

Pages