ML
    • Recent
    • Categories
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login

    Restructuring Text file to CSV

    Scheduled Pinned Locked Moved IT Discussion
    text editorcsvexcel
    26 Posts 5 Posters 5.6k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • scottalanmillerS
      scottalanmiller @gjacobse
      last edited by

      Would this be good?

      2015-09-23,12:18:46.000
      
      1 Reply Last reply Reply Quote 0
      • gjacobseG
        gjacobse
        last edited by

        More along the lines of this:

        2015-09-23	11:48:25.000
        2015-09-23[tabbed space here]11:48:25.000
        
        1 Reply Last reply Reply Quote 0
        • gjacobseG
          gjacobse
          last edited by gjacobse

          I should add, that this will be a Crystal Reports Export to be done by another party.

          not that that should make any difference.

          1 Reply Last reply Reply Quote 0
          • scottalanmillerS
            scottalanmiller
            last edited by

            So you are wanting a TSV, not a CSV?

            gjacobseG 1 Reply Last reply Reply Quote 0
            • scottalanmillerS
              scottalanmiller
              last edited by

              This is super easy. So assuming that your file is myfile.csv and you are on Linux, just do this...

              unexpand myfile.csv > myfile.tsv
              

              Like magic, Linux saves the day.

              1 Reply Last reply Reply Quote 0
              • gjacobseG
                gjacobse @scottalanmiller
                last edited by

                @scottalanmiller said:

                So you are wanting a TSV, not a CSV?

                While I suppose technically speaking, yes it would be a TSV - Tab Space Value.

                However, TSV is not a Text file option in Excel - Only CSV

                csv.png

                JaredBuschJ 1 Reply Last reply Reply Quote 0
                • scottalanmillerS
                  scottalanmiller
                  last edited by

                  Excel doesn't know formats, it just knows extensions 😉 Windows apps are not very smart.

                  gjacobseG 1 Reply Last reply Reply Quote 0
                  • gjacobseG
                    gjacobse
                    last edited by

                    Also, all the data is [TAB] not [,]

                    1 Reply Last reply Reply Quote 0
                    • gjacobseG
                      gjacobse @scottalanmiller
                      last edited by

                      @scottalanmiller said:

                      Excel doesn't know formats, it just knows extensions 😉 Windows apps are not very smart.

                      I won't argue you there...

                      1 Reply Last reply Reply Quote 0
                      • JaredBuschJ
                        JaredBusch @gjacobse
                        last edited by

                        @gjacobse said:

                        While I suppose technically speaking, yes it would be a TSV - Tab Space Value.

                        This would be Tab Separated Value

                        gjacobseG 1 Reply Last reply Reply Quote 1
                        • JaredBuschJ
                          JaredBusch
                          last edited by

                          How are you planning to resatructure this prior to importing?

                          You say a user is doing this? Then teach them how to handle it in Excel. You will be hard pressed to get a user to do much outside of an office application.

                          Please be more specific about what you are doing with these files.

                          1. who is exporting it and from where.
                          2. who is restructuring it
                          3. who is opening it in Excel
                          4. where is it going after that
                          1 Reply Last reply Reply Quote 0
                          • scottalanmillerS
                            scottalanmiller
                            last edited by

                            LOL, right. It's Tab instead of space! The original file is an SSB, Space Separate Values.

                            1 Reply Last reply Reply Quote 0
                            • gjacobseG
                              gjacobse @JaredBusch
                              last edited by

                              @JaredBusch said:

                              @gjacobse said:

                              While I suppose technically speaking, yes it would be a TSV - Tab Space Value.

                              This would be Tab Separated Value

                              Yea,.. there is that...

                              1 Reply Last reply Reply Quote 0
                              • scottalanmillerS
                                scottalanmiller
                                last edited by

                                So anyway, that one command solves the problem nice and easy.

                                1 Reply Last reply Reply Quote 0
                                • gjacobseG
                                  gjacobse
                                  last edited by

                                  I expect that the 'best course of action' is to have the User rerun the export and adjust accordingly.

                                  However I was hoping to perform a trial run of the import with the data I have, about 100 lines or so. But each row has seven (x)DATE items...

                                  scottalanmillerS 1 Reply Last reply Reply Quote 0
                                  • scottalanmillerS
                                    scottalanmiller @gjacobse
                                    last edited by

                                    @gjacobse said:

                                    I expect that the 'best course of action' is to have the User rerun the export and adjust accordingly.

                                    However I was hoping to perform a trial run of the import with the data I have, about 100 lines or so. But each row has seven (x)DATE items...

                                    So does the command that I provided work? Can you provide full sample data so that we can test?

                                    gjacobseG 1 Reply Last reply Reply Quote 0
                                    • gjacobseG
                                      gjacobse @scottalanmiller
                                      last edited by

                                      @scottalanmiller said:

                                      @gjacobse said:

                                      I expect that the 'best course of action' is to have the User rerun the export and adjust accordingly.

                                      However I was hoping to perform a trial run of the import with the data I have, about 100 lines or so. But each row has seven (x)DATE items...

                                      So does the command that I provided work? Can you provide full sample data so that we can test?

                                      My apologies Scott, I missed your Linux command in a page refresh.

                                      Sadly I don't have this file on a Linux system.. Windows only...

                                      scottalanmillerS 1 Reply Last reply Reply Quote 0
                                      • scottalanmillerS
                                        scottalanmiller @gjacobse
                                        last edited by

                                        @gjacobse said:

                                        Sadly I don't have this file on a Linux system.. Windows only...

                                        So copy it, only takes a second.

                                        JaredBuschJ 1 Reply Last reply Reply Quote 1
                                        • JaredBuschJ
                                          JaredBusch @scottalanmiller
                                          last edited by

                                          @scottalanmiller said:

                                          @gjacobse said:

                                          Sadly I don't have this file on a Linux system.. Windows only...

                                          So copy it, only takes a second.

                                          Maybe true, but my earlier questions remains unanswered. Those are more important than a simple "just copy it" answer.

                                          He clearly stated this will be something repeated later with at least one more file. Thus I asked what the true purpose here is supposed to be.

                                          gjacobseG 1 Reply Last reply Reply Quote 0
                                          • gjacobseG
                                            gjacobse @JaredBusch
                                            last edited by

                                            @JaredBusch said:

                                            Maybe true, but my earlier questions remains unanswered. Those are more important than a simple "just copy it" answer.

                                            He clearly stated this will be something repeated later with at least one more file. Thus I asked what the true purpose here is supposed to be.

                                            Exporting IT Tickets from TrackIT to be imported into SpiceWorks

                                            JaredBuschJ 1 Reply Last reply Reply Quote 0
                                            • 1
                                            • 2
                                            • 1 / 2
                                            • First post
                                              Last post