gengliangwang commented on code in PR #50631:
URL: https://github.com/apache/spark/pull/50631#discussion_r2057784973


##########
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/constraints.scala:
##########
@@ -198,3 +268,30 @@ case class ForeignKeyConstraint(
     copy(userProvidedCharacteristic = c)
   }
 }
+
+
+/** This class is used to represent a collection of constraints in a table.
+ * It is used for analysis purposes only.
+ *
+ * @param children The list of constraint expressions
+ */
+case class Constraints(children: Seq[Expression]) extends Expression with 
Unevaluable {

Review Comment:
   > BTW why do we need this container? can't we directly put 
Seq[TableConstraint] into TableSpec?
   
   The implementation of `UnresolvedTableSpec.withNewChildrenInternal` would be 
a bit ugly...but you are right, having the container seems more complicated



-- 
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.

To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org

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