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/06/05 09:40:36 UTC

[GitHub] [arrow-rs] alippai commented on a change in pull request #406: Add Decimal to CsvWriter and improve debug display

alippai commented on a change in pull request #406:
URL: https://github.com/apache/arrow-rs/pull/406#discussion_r645969016



##########
File path: arrow/src/array/array_binary.rs
##########
@@ -728,8 +730,11 @@ impl From<ArrayData> for DecimalArray {
 impl fmt::Debug for DecimalArray {
     fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
         write!(f, "DecimalArray<{}, {}>\n[\n", self.precision, self.scale)?;
+        let point_index = 10_i128.pow(self.scale as u32);

Review comment:
       I didn't find display.rs, thanks! Your question is really good. While Decimal has custom logic, this doesn't seem to be Decimal specific, e.g. There is a great overlap between display.rs, csv_writer and even the specific array debug formats. I think it should be refactored in a separate issue.




-- 
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.

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