Uploaded image for project: 'Spark'
  1. Spark
  2. SPARK-20746 Built-in SQL Function Improvement
  3. SPARK-20754

Add Function Alias For MOD/TRUNCT/POSITION

    XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 2.2.0
    • 2.3.0
    • SQL

    Description

      We already have the impl of the following functions. We can add the function alias to be consistent with ANSI.

       
      MOD(<m>,<n>)
      

      Returns the remainder of m divided by n. Returns m if n is 0.

       
      TRUNC
      

      Returns the number x, truncated to D decimals. If D is 0, the result will have no decimal point or fractional part. If D is negative, the number is zeroed out.

       
      POSITION
      

      Returns the position of the char IN <string>) in the source string.

      Attachments

        Activity

          People

            yumwang Yuming Wang
            smilegator Xiao Li
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: