[GitHub] spark pull request: [SQL] Make date/time functions more consistent...
Github user asfgit closed the pull request at: https://github.com/apache/spark/pull/7506 --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] spark pull request: [SQL] Make date/time functions more consistent...
Github user rxin commented on the pull request: https://github.com/apache/spark/pull/7506#issuecomment-122638167 I've merged this. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] spark pull request: [SQL] Make date/time functions more consistent...
Github user AmplabJenkins commented on the pull request: https://github.com/apache/spark/pull/7506#issuecomment-122637538 Merged build finished. Test PASSed. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] spark pull request: [SQL] Make date/time functions more consistent...
Github user SparkQA commented on the pull request: https://github.com/apache/spark/pull/7506#issuecomment-122637521 [Test build #37759 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/37759/console) for PR 7506 at commit [`e44a4a0`](https://github.com/apache/spark/commit/e44a4a0579ea65093fdb7ca39749855be3a50fcd). * This patch **passes all tests**. * This patch merges cleanly. * This patch adds the following public classes _(experimental)_: * `case class Hour(child: Expression) extends UnaryExpression with ImplicitCastInputTypes ` * `case class Minute(child: Expression) extends UnaryExpression with ImplicitCastInputTypes ` * `case class Second(child: Expression) extends UnaryExpression with ImplicitCastInputTypes ` * `case class DayOfYear(child: Expression) extends UnaryExpression with ImplicitCastInputTypes ` * `case class Year(child: Expression) extends UnaryExpression with ImplicitCastInputTypes ` * `case class Quarter(child: Expression) extends UnaryExpression with ImplicitCastInputTypes ` * `case class Month(child: Expression) extends UnaryExpression with ImplicitCastInputTypes ` * `case class DayOfMonth(child: Expression) extends UnaryExpression with ImplicitCastInputTypes ` * `case class WeekOfYear(child: Expression) extends UnaryExpression with ImplicitCastInputTypes ` * `case class DateFormatClass(left: Expression, right: Expression) extends BinaryExpression` --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] spark pull request: [SQL] Make date/time functions more consistent...
Github user rxin commented on the pull request: https://github.com/apache/spark/pull/7506#issuecomment-122633558 Both MySQL and HANA use dayofmonth, without the underscore? --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] spark pull request: [SQL] Make date/time functions more consistent...
Github user tarekauel commented on the pull request: https://github.com/apache/spark/pull/7506#issuecomment-122633436 @rxin Could you do this little fix as well? https://github.com/apache/spark/pull/7505/files Why do we switch from day_of_month to dayofmonth? Most SQL implementations use underscores: [MySQL](https://dev.mysql.com/doc/refman/5.0/en/func-op-summary-ref.html) [SAP HANA](http://help.sap.com/saphelp_hanaplatform/helpdata/en/20/9f228975191014baed94f1b69693ae/content.htm?frameset=/en/20/9ddefe75191014ac249bf78ba2a1e9/frameset.htm¤t_toc=/en/2e/1ef8b4f4554739959886e55d4c127b/plain.htm&node_id=91&show_children=false) [Oracle](http://docs.oracle.com/cd/B19306_01/server.102/b14200/functions001.htm#i88891) I would prefer underscores, because they improve the readability, if you write all SQL stuff in caps, like: `SELECT name, age, DAY_OF_MONTH(birthday) AS birthday FROM people WHERE age > 15` compared to `SELECT name, age, DAYOFMONTH(birthday) AS birthday FROM people WHERE age > 15` I'm not a Python pro, but I thought that underscores are 'pythonic', aren't they? --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] spark pull request: [SQL] Make date/time functions more consistent...
Github user davies commented on the pull request: https://github.com/apache/spark/pull/7506#issuecomment-122633426 LGTM --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] spark pull request: [SQL] Make date/time functions more consistent...
Github user AmplabJenkins commented on the pull request: https://github.com/apache/spark/pull/7506#issuecomment-122633378 Merged build finished. Test FAILed. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] spark pull request: [SQL] Make date/time functions more consistent...
Github user AmplabJenkins commented on the pull request: https://github.com/apache/spark/pull/7506#issuecomment-122633291 Merged build finished. Test FAILed. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] spark pull request: [SQL] Make date/time functions more consistent...
Github user AmplabJenkins commented on the pull request: https://github.com/apache/spark/pull/7506#issuecomment-122633260 Merged build triggered. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] spark pull request: [SQL] Make date/time functions more consistent...
Github user AmplabJenkins commented on the pull request: https://github.com/apache/spark/pull/7506#issuecomment-122633264 Merged build started. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] spark pull request: [SQL] Make date/time functions more consistent...
Github user SparkQA commented on the pull request: https://github.com/apache/spark/pull/7506#issuecomment-122633237 [Test build #37759 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/37759/consoleFull) for PR 7506 at commit [`e44a4a0`](https://github.com/apache/spark/commit/e44a4a0579ea65093fdb7ca39749855be3a50fcd). --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] spark pull request: [SQL] Make date/time functions more consistent...
Github user AmplabJenkins commented on the pull request: https://github.com/apache/spark/pull/7506#issuecomment-122633099 Merged build triggered. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] spark pull request: [SQL] Make date/time functions more consistent...
Github user AmplabJenkins commented on the pull request: https://github.com/apache/spark/pull/7506#issuecomment-122633104 Merged build started. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] spark pull request: [SQL] Make date/time functions more consistent...
Github user rxin commented on the pull request: https://github.com/apache/spark/pull/7506#issuecomment-122633048 cc @tarekauel and @davies --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] spark pull request: [SQL] Make date/time functions more consistent...
Github user AmplabJenkins commented on the pull request: https://github.com/apache/spark/pull/7506#issuecomment-122633012 Merged build started. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] spark pull request: [SQL] Make date/time functions more consistent...
Github user AmplabJenkins commented on the pull request: https://github.com/apache/spark/pull/7506#issuecomment-122633011 Merged build triggered. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] spark pull request: [SQL] Make date/time functions more consistent...
Github user rxin commented on a diff in the pull request: https://github.com/apache/spark/pull/7506#discussion_r34955144 --- Diff: sql/core/src/main/scala/org/apache/spark/sql/functions.scala --- @@ -1748,182 +1748,6 @@ object functions { */ def length(columnName: String): Column = length(Column(columnName)) - // --- End diff -- note that this previously cut right into the middle of string functions so I moved them --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] spark pull request: [SQL] Make date/time functions more consistent...
GitHub user rxin opened a pull request: https://github.com/apache/spark/pull/7506 [SQL] Make date/time functions more consistent with other database systems. This renames some of the functions that are just merged in order to be more consistent with other databases. Also did some small cleanups. You can merge this pull request into a Git repository by running: $ git pull https://github.com/rxin/spark datetime Alternatively you can review and apply these changes as the patch at: https://github.com/apache/spark/pull/7506.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #7506 commit 9c08fdc73d601bb856a16fca4c8c700dc29f3717 Author: Reynold Xin Date: 2015-07-19T06:12:08Z [SQL] Make date/time functions more consistent with other database systems. This renames some of the functions that are just merged in order to be more consistent with other databases. Also did some small cleanups. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org