Uploaded image for project: 'Spark'
  1. Spark
  2. SPARK-41780

`regexp_replace('', '[a\\\\d]{0, 2}', 'x')` causes an internal error

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 3.3.0
    • 3.4.0
    • SQL
    • None
    • Spark3.3.0 local mode

    Description

      scala> spark.sql("select regexp_replace('', '[a\\\\d]{0,2}', 'x')").show
      +----------------------------------+
      |regexp_replace(, [a\d]\{0,2}, x, 1)|
      +----------------------------------+
      |                                 x|
      +----------------------------------+
       
       
      scala> spark.sql("select regexp_replace('', '[a\\\\d]{0, 2}', 'x')").show
      org.apache.spark.SparkException: The Spark SQL phase optimization failed with an internal error. Please, fill a bug report in, and provide the full stack trace.
      

       

      Attachments

        Activity

          People

            panbingkun BingKun Pan
            remziy Remzi Yang
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: