Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7685537
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T19:16:23+00:00 2026-05-31T19:16:23+00:00

I have a CSV file in the format shown below, and I’m using the

  • 0

I have a CSV file in the format shown below, and I’m using the Perl split command as shown, based on comma as delimiter. The problem is I have a quoted string "HTTP Large, GMS, ZMS: Large Files" with embedded commas and it fails. The array values will have only less elements. How can I modify the split command.

  my @values = split('\,', $line);

CSV File

 10852,800 Mob to Int'l,235341739,573047,84475.40,0.0003,Inbound,Ber unit
 10880,"HTTP Large, GMS, ZMS: Large Files",52852810,128,13712.68,0.0002,,Rer unit
 13506,Presence National,2716766818,2447643,309116.40,0.0001,Presence,per Cnit
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T19:16:24+00:00Added an answer on May 31, 2026 at 7:16 pm

    Issues like embedded commas are precisely why modules such as Text::CSV were created. If, but only if, the data does not have embedded commas, then you can make regular expressions work. When the data has embedded commas, it is time to move to a tool designed to handle CSV with embedded commas, and that would be Text::CSV in Perl (and its relatives Text::CSV_PP and Text::CSV_XS).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a csv file of the format: 270291014011 ED HARDY - TRUE TO
I have a CSV file which has the following format: id,case1,case2,case3 Here is a
I have a basic C# console application that reads a text file (CSV format)
I have a transaction log file in CSV format that I want use to
I have a csv file in a format resembling the following. There are no
I have a CSV file in the following format: id,code,date,address,complete_url Example data from the
I have a CSV file with the following format: ID | STUFF | Custom
I have a csv format file, which I want to import to sql server
I have a 250MB+ huge csv file to upload file format is group_id, application_id,
I have an Excel/CSV file with relatively simple format. 1|2|3|4|10|20|30 | | | |40|50|60

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.