-
Type:
Sub-task
-
Status: Open
-
Priority:
Major
-
Resolution: Unresolved
-
Affects Version/s: 3.0.0
-
Fix Version/s: None
-
Component/s: SQL
-
Labels:None
The expression expr1 ^ expr2 has different meanings in Spark and Postgres:
- In Postgres and Redshift , this returns expr1 raised to the exponent expr2 (additionally, the Postgres docs explicitly state that this operation is left-associative).
- In Spark and Hive, this returns the bitwise exclusive OR of expr1 and expr2.
I'm reporting this under the Postgres compatibility umbrella. If we have SQL dialect support (e.g. a Postgres compatibility dialect), maybe this behavior could be flagged there? Alternatively, maybe we could document this in a compatibility / porting guide?
- relates to
-
SPARK-28027 Missing some mathematical operators
-
- Resolved
-