Solved

Reading data from excel using shell script

Posted on 2015-01-16
9
971 Views
Last Modified: 2015-03-29
I have an excel sheet which has 5 columns like name, age, sex, address,phone number. can any one please help me out in reading the excel sheet only using shell script instead of using Perl and python.

TIA
0
Comment
Question by:gaurav sharma
  • 3
  • 2
  • 2
  • +1
9 Comments
 
LVL 28

Assisted Solution

by:Jan Springer
Jan Springer earned 167 total points
ID: 40555207
You don't.  You use a tool like perl and modules.

You can use bash (or other shell) if you export that file to a csv/txt and remove the formatting.
0
 
LVL 18

Assisted Solution

by:SimonAdept
SimonAdept earned 166 total points
ID: 40555241
Slight update: It depends if you're referring to a true 'Excel file' ie. one of Excel's proprietary file formats. If you store it as csv or other delimited text format you can read it from bash.
0
 
LVL 28

Expert Comment

by:Jan Springer
ID: 40555243
Hint: It's not an excel file if it's in csv or txt format.
0
 
LVL 18

Expert Comment

by:SimonAdept
ID: 40555275
@Jan, Yes, I know, but I've had a few people recently refer to "Excel sheets" (as opposed to Workbooks) when they are actually CSV files that show with an Excel icon on their desktop and open in Excel by default.
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 21

Expert Comment

by:Mazdajai
ID: 40555277
Other expert already responded "you don't" ... And in fact - you can't.

There is no bash API to read excel natively. In fact, other languages don't by default - they rely on pre-build modules.
0
 
LVL 28

Expert Comment

by:Jan Springer
ID: 40555291
Understood.  I just don't think it's correct to perpetuate an inaccuracy.  A nit perhaps but felt that clarity was needed.
0
 

Author Comment

by:gaurav sharma
ID: 40681621
I've requested that this question be deleted for the following reason:

incorrect
0
 
LVL 21

Accepted Solution

by:
Mazdajai earned 167 total points
ID: 40681622
What is incorrect?
0
 

Author Comment

by:gaurav sharma
ID: 40685892
Incorrect question
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Join & Write a Comment

Introduction We as admins face situation where we need to redirect websites to another. This may be required as a part of an upgrade keeping the old URL but website should be served from new URL. This document would brief you on different ways ca…
Background Still having to process all these year-end "csv" files received from all these sources (including Government entities), sometimes we have the need to examine the contents due to data error, etc... As a "Unix" shop, our only readily …
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now