huaxingao commented on a change in pull request #29837:
URL: https://github.com/apache/spark/pull/29837#discussion_r493965798



##########
File path: docs/sql-ref-datatypes.md
##########
@@ -314,3 +314,33 @@ SELECT COUNT(*), c2 FROM test GROUP BY c2;
 |        3| Infinity|
 +---------+---------+
 ```
+
+#### Data type compatibility
+
+The following is the hierarchy of data type compatibility. In an operation 
involving different and compatible data types, these will be promoted to the 
lowest common top type to perform the operation.
+
+For example, if you have an add operation between an integer and a float, the 
integer will be treated as a float, the least common compatible type, resulting 
the operation in a float.
+
+The most common operations where this hierarchy is applied are:

Review comment:
       @gatorsmile WDYT? Do you want to have a table to list the most common 
rules like the one in 
https://www.ibm.com/support/knowledgecenter/SSEPGG_10.1.0/com.ibm.db2.luw.sql.ref.doc/doc/r0008477.html?




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to