× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



On Sun, Jan 16, 2022 at 1:01 AM Jack Woehr via MIDRANGE-L
<midrange-l@xxxxxxxxxxxxxxxxxx> wrote:

IBM isn't kidding when it tells you open source is the path forward.

https://openpyxl.readthedocs.io/en/stable/

That package is what I consider to be in a sweet spot, balancing
between level of abstraction (and thus ease of use) and fine-grained
control.

But if you want to tilt as far to abstract and easy as possible (which
I think is appropriate if CPYFRMIMPF has been your workhorse), then
you want to look at pandas.

You'll need to install Python and pandas if you haven't already. These
you would do with yum, either at a PASE shell or via the ACS GUI.

Once you have those, the code you have to write is close to minimal:

import pandas
pandas.read_excel('myworkbook.xlsx').to_csv('mytabfile.csv', sep='\t')

(That isn't tested, and I don't personally use pandas.)

If the "chained method" style is too uncomfortable for you, or if you
have very long stream file names, you may want to break it up into
simpler, shorter lines. For example, you could do

import pandas
excelfile = 'my_long_excel_workbook_path_here.xlsx'
tabfile = 'my_long_tab_delimited_path_here.csv'
mydata = pandas.read_excel(excelfile)
mydata.to_csv(tabfile, sep='\t')

John Y.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.