Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SPARK-9154][SQL] codegen StringFormat #7571

Closed
wants to merge 7 commits into from

Conversation

tarekbecker
Copy link
Contributor

Jira: https://issues.apache.org/jira/browse/SPARK-9154

fixes bug of #7546

@marmbrus I can't reopen the other PR, because I didn't closed it. Can you trigger Jenkins?

@@ -486,6 +486,10 @@ case class StringFormat(children: Expression*) extends Expression with CodegenFa
private def format: Expression = children(0)
private def args: Seq[Expression] = children.tail

override def inputTypes: Seq[AbstractDataType] =
StringType :: List.fill(children.size - 1)(AnyDataType)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I updated this as well.

@marmbrus
Copy link
Contributor

ok to test

@rxin
Copy link
Contributor

rxin commented Jul 21, 2015

It was my mistake -- I shouldn't have taken out the formatString with Columns, except the 1st argument should be a String.

@tarekbecker
Copy link
Contributor Author

Should I add it again?

@rxin
Copy link
Contributor

rxin commented Jul 21, 2015

Yes please.

@tarekbecker
Copy link
Contributor Author

@rxin Could you trigger Jenkins

@marmbrus
Copy link
Contributor

ok to test

@SparkQA
Copy link

SparkQA commented Jul 21, 2015

Test build #37983 has finished for PR 7571 at commit dcae272.

  • This patch fails Spark unit tests.
  • This patch merges cleanly.
  • This patch adds the following public classes (experimental):
    • case class StringFormat(children: Expression*) extends Expression with ImplicitCastInputTypes

@rxin
Copy link
Contributor

rxin commented Jul 21, 2015

Jenkins, retest this please.

* @since 1.5.0
*/
@scala.annotation.varargs
def formatString(format: Column, arguments: Column*): Column = {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i was thinking about a a version in which format is a string, but rest of the arguments are columns.

@SparkQA
Copy link

SparkQA commented Jul 21, 2015

Test build #1150 has finished for PR 7571 at commit dcae272.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@asfgit asfgit closed this in d4c7a7a Jul 21, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants