Github user ScrapCodes commented on a diff in the pull request: https://github.com/apache/spark/pull/13839#discussion_r68487475 --- Diff: sql/core/src/main/scala/org/apache/spark/sql/Dataset.scala --- @@ -251,7 +253,11 @@ class Dataset[T] private[sql]( case seq: Seq[_] => seq.mkString("[", ", ", "]") case _ => cell.toString } - if (truncate && str.length > 20) str.substring(0, 17) + "..." else str + if (truncate > 0 && str.length > truncate) { + // do not show ellipses for strings shorter than 4 characters. + if (truncate < 4) str.substring(0, truncate) + else str.substring(0, truncate - 3) + "..." --- End diff -- Here I have subtracted 3 from truncate length to align with the existing logic.
--- 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