You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2021/09/25 10:28:29 UTC

[GitHub] [arrow] rok commented on a change in pull request #11229: ARROW-14111: [C++] Add extraction function support for time32/time64

rok commented on a change in pull request #11229:
URL: https://github.com/apache/arrow/pull/11229#discussion_r716023404



##########
File path: cpp/src/arrow/compute/kernels/scalar_temporal.cc
##########
@@ -528,13 +576,18 @@ struct Strftime {
   static Result<Strftime> Make(KernelContext* ctx, const DataType& type) {
     const StrftimeOptions& options = StrftimeState::Get(ctx);
 
-    auto timezone = GetInputTimezone(type);
     // This check is due to surprising %c behavior.
     // See https://github.com/HowardHinnant/date/issues/704
     if ((options.format.find("%c") != std::string::npos) && (options.locale != "C")) {
       return Status::Invalid("%c flag is not supported in non-C locales.");
     }
-    if (timezone.empty()) {
+    std::string timezone;
+    bool is_timestamp = type.id() == Type::TIMESTAMP;
+    if (is_timestamp) {

Review comment:
       Good point! Changed, please check if it makes sense.




-- 
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: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org