Solved

Teradata ^ operator

Posted on 2011-02-11
2
1,775 Views
Last Modified: 2013-11-11
Hi Guys,
I've inherited a program which has some teradata access in it and one part of the query has me stumped as I dont know what it does or how its meant to operate.  

This particular example is on a group by clause  like this with the '^' operator.

...
GROUP BY 1 , 2 , 3 , 4 , 5 ) chk 
WHERE ( ^ ( CAST( one_id AS INT ) = 9772 
 AND two_id = 12192 ) ) ;

Open in new window

...

Anyone can unveil what this '^' operator is and does?  It looks like 'NOT'  but I cant confirm it anywhere
Thanks
B
0
Comment
Question by:BarryMcGillin
2 Comments
 
LVL 59

Expert Comment

by:Kevin Cross
ID: 34873666
My understanding was that is a bitwise operator.  Additionally, every reference I have seen for the Teradata logical operators has the keyword NOT; therefore, 2 sanity checks:

+ Is the results the same if you swap ^ with NOT
+ What do you get with: SELECT 1^1
0
 
LVL 13

Accepted Solution

by:
ispaleny earned 500 total points
ID: 34989553
The following comparison operators are Teradata extensions to the ANSI SQL:2008 standard.
Their use is deprecated.

EQ
^=
NE
NOT=
LT
LE
GT
GE

You should use <> instead of ^=.

It looks like ^ is a deprecated Teradata version of NOT operator.

But it is not documented at least since V2R6.0.0(oldest docs available online).
0

Featured Post

3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
TypeError: Users.save is not a function 3 56
Extract Currency data from a string and put them in a new field 3 38
PL SQL Developer 7 37
SQL SELECT query help 7 41
In our personal lives, we have well-designed consumer apps to delight us and make even the most complex transactions simple. Many enterprise applications, however, are a bit behind the times. For an enterprise app to be successful in today's tech wo…
Messaging apps are amazing tools with the power to do a lot of good, but the truth is the process of collaborating with coworkers requires relationships established through meaningful communication - the kind of communication that only happens face-…
This video shows how to copy a database user from one database to another user DBMS_METADATA.  It also shows how to copy a user's permissions and discusses password hash differences between Oracle 10g and 11g.
Via a live example, show how to take different types of Oracle backups using RMAN.

832 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question