#DateForumTypeThreadPost
2604 Feb 2015 @ 08:07 PSTDatabaseTopicJava Function in Teradata is taking too long to executeI've created a Java Function and imported it in TeraData But after few thousand executions, the function becomes too slow. You can find below output from TOP command. USER   &...
2530 Dec 2014 @ 10:36 PSTDatabaseReplyusing update with WITH clauseHi, I have 2 tables having same number of rows(UNIQUE). 1 table is having identity column and 2nd doesn't have. I want to update column in 2nd table with 1st table(any row from 1st table) &...
2430 Dec 2014 @ 10:32 PSTDatabaseReplyGET DIAGNOSTICS v_Variable_Name = ROW_COUNT giving wrong outputThanks for your response. PFB procedure that i tested for this.   REPLACE procedure test() dynamic result sets 1 begin     DECLARE dg_rowcnt integer;    &nb...
2328 Dec 2014 @ 11:07 PSTDatabaseTopicusing update with WITH clauseHi,   I'm trying to do something like below, but its giving me syntax error, can anyone please tell me what is the issue and how to fix this.   with cte0(ID,int_col1) as(  ...
2224 Dec 2014 @ 01:35 PSTDatabaseTopicGET DIAGNOSTICS v_Variable_Name = ROW_COUNT giving wrong outputHi, ROW_COUNT is returning wrong number. i have a table having around 100K rows. In a procedure i'm updating all the rows and returning number of rows affected. I'm using following query...
2128 Oct 2014 @ 10:25 PDTDatabaseReplywrite SQL UDF in Teradatathanks all
2027 Oct 2014 @ 03:33 PDTDatabaseReplywrite SQL UDF in Teradatabut i want to read data from database tables. is this possible. if yes, will it hurt the performance?  
1926 Oct 2014 @ 10:48 PDTDatabaseTopicwrite SQL UDF in TeradataHi, I want to write SQL UDF with Multiple Lines: 1. Declare variables. 2. Set those variables with select into statement. 3. some if conditions on Variables 4. return some value.   What...
1807 Oct 2014 @ 09:08 PDTDatabaseReplyAn owner referenced by user does not have REFERENCES accessUSER DBC has created that Procedure and even that Table. do i need to explicitly grant reference permission to user dbc for every table.
1707 Oct 2014 @ 12:24 PDTDatabaseTopicAn owner referenced by user does not have REFERENCES accessHi,   I'm logged in with dbc user. I'm ALTERing a table to add Foreign Key Constraint with Following statement ALTER TABLE testdb.Master2 ADD CONSTRAINT fk_Master1 FOREIGN KEY (Mas...
1625 Sep 2014 @ 12:33 PDTDatabaseReplyTemporary Disable\enable Constraints (Foreign Key, Check Constriant, Unique Key)that was myTableNameToMask || '_0' in above comment. Spell Mistake Parth
1525 Sep 2014 @ 12:32 PDTDatabaseReplyTemporary Disable\enable Constraints (Foreign Key, Check Constriant, Unique Key)Thanks I Have Created a Seapare Procedure which will Drop All Tables having myTableNameToMask || ' 0' before Adding Constraint.   Thanks all.   Parth
1424 Sep 2014 @ 04:54 PDTDatabaseReplyTemporary Disable\enable Constraints (Foreign Key, Check Constriant, Unique Key)Thanks for this valuable info.   Should i Check for this table every time when i'm altering table, And delete it if exists? Or is there any setting that will delete this automatically i...
1324 Sep 2014 @ 03:50 PDTDatabaseReplyTemporary Disable\enable Constraints (Foreign Key, Check Constriant, Unique Key)i verified all the statements. penultimate ALTER Statement is working fine. it dropped only Constraint from compositeForeignKey, But it did not drop table "compositeForeignKey_0". When ...
1224 Sep 2014 @ 02:53 PDTDatabaseReplyTemporary Disable\enable Constraints (Foreign Key, Check Constriant, Unique Key)Hi,   Now some other problem with same issue. There are some composite keys in my DB. When i drop and Recreate them, i get error.   Following is the simple sample script which will ...
1124 Sep 2014 @ 02:51 PDTDatabaseReplyTemporary Disable\enable Constraints (Foreign Key, Check Constriant, Unique Key)I again ran the same command after restarting my Studio and it works. I don't know why. thanks.   Parth
1023 Sep 2014 @ 10:51 PDTDatabaseReplyTemporary Disable\enable Constraints (Foreign Key, Check Constriant, Unique Key)Thanks for information. Actually i'm doing this in a loop. So i need to drop them dynamically.   The problem is the following statement, which is not working.But even its not giving an...
923 Sep 2014 @ 04:48 PDTDatabaseTopicTemporary Disable\enable Constraints (Foreign Key, Check Constriant, Unique Key)Hi,   I want to Update a table. But before that i want disable foreign key\check Constraint\Unique Key on some tables. After update, i want to enable those disables constraint again.  ...
823 Sep 2014 @ 04:43 PDTDatabaseReplyNo room available in Database testdb.thanks for help. I downloaded 40GB VM. And it worked. Thanks all.
719 Sep 2014 @ 01:21 PDTDatabaseReplyNo room available in Database testdb.Following are the results of Both Views: DBC.TableSize : 1 SQLJ DBC ALTER_JAVA_PATH 3072 3072 1 transportation DBC Frequent_Flyers 1536 1536 0 SQLJ DBC REPLACE_JAR 3072 3072 0 transportation...
618 Sep 2014 @ 04:14 PDTDatabaseTopicNo room available in Database testdb.Hi, i'm getting error of "no room available in Database testdb". Even in dbc, there's no space left. Now i want to add space in dbc. so that i can move that space to my testdb ...
517 Sep 2014 @ 01:07 PDTDatabaseReplyUse While loop in Stored Procedure in TeradataHi Vijay, I found solution for Affected Rows Count. Paste this right after your update Query. GET DIAGNOSTICS t_dups = ROW_COUNT;   Here t_dups is the variable name which you can replace ...
417 Sep 2014 @ 12:28 PDTDatabaseReplyUse While loop in Stored Procedure in Teradatahi vijay, I tried ACTIVITY_COUNT in Procedure, but got error "Cannot resolve column 'ACTIVITY_COUNT'". I am running this in TeraData Studio (Query Manager) not in BTEQ. Parth
317 Sep 2014 @ 12:25 PDTDatabaseReplyUse While loop in Stored Procedure in Teradatai just got one more issue; Problem #3: Can we call dbc.SysExecSQL outside of Stored Procedure.(as a single statement). i'm getting error "Stored Procedure dbc.SysExecSQL does not exist&...
216 Sep 2014 @ 11:48 PDTDatabaseReplyUse While loop in Stored Procedure in Teradatathanks for quick reply. Can you please help me in one more issue. I want to get no of rows affected from last Query. How can i do that. for instance : DECLARE v_RowsAffected integer; update ta...

Pages