<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: CSV Field extractions with one field has extra commas with in single quotes in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/CSV-Field-extractions-with-one-field-has-extra-commas-with-in/m-p/351603#M64472</link>
    <description>&lt;P&gt;I was able to ingest your data successfully using the Add Data Wizard, using the following changes... &lt;/P&gt;

&lt;OL&gt;
&lt;LI&gt;In the "Set source type" stage, you should choose CSV from the "Source type" dropdown &lt;/LI&gt;
&lt;LI&gt;Under "Delimited settings", which appears after you choose CSV, you should choose single quote as your quote character.&lt;/LI&gt;
&lt;LI&gt;At the end of the process, you should pick a different source type name, so you don't confuse future, more general CSV users.&lt;/LI&gt;
&lt;/OL&gt;

&lt;P&gt;Accepting all the other defaults worked for me! &lt;/P&gt;</description>
    <pubDate>Sat, 11 Mar 2017 21:30:47 GMT</pubDate>
    <dc:creator>acruise_splunk</dc:creator>
    <dc:date>2017-03-11T21:30:47Z</dc:date>
    <item>
      <title>CSV Field extractions with one field has extra commas with in single quotes</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/CSV-Field-extractions-with-one-field-has-extra-commas-with-in/m-p/351601#M64470</link>
      <description>&lt;P&gt;Here is an example of one log:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;20170309 10:41:16,hostname.vagrantup.com,username,localhost,155,9823,QUERY,database_name,'select min(t.nextcheck) from httptest t,hosts h where t.hostid=h.hostid and mod(t.httptestid,5)=4 and t.status=0 and h.proxy_hostid is null and h.status=0 and (h.maintenance_status=0 or h.maintenance_type=0)',0
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Here is an example of another log:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;20170309 10:40:44,hostname,username,localhost,222,0,CONNECT,database,,0
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Here is the format:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[timestamp],[serverhost],[username],[host],[connectionid],[queryid],[operation],[database],[object],[retcode]
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;So I am stuck trying to get this correctly setup to have each field configured correctly. As you can see the logs differ based on what type of operation is taking place.&lt;BR /&gt;
When the operation is a query they will likely have several commas inside of single quotes. Any help will be much appreciated.&lt;/P&gt;

&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Sat, 11 Mar 2017 03:36:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/CSV-Field-extractions-with-one-field-has-extra-commas-with-in/m-p/351601#M64470</guid>
      <dc:creator>som3guy</dc:creator>
      <dc:date>2017-03-11T03:36:03Z</dc:date>
    </item>
    <item>
      <title>Re: CSV Field extractions with one field has extra commas with in single quotes</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/CSV-Field-extractions-with-one-field-has-extra-commas-with-in/m-p/351602#M64471</link>
      <description>&lt;P&gt;I've done this a while ago using a REGEX statement in my props.conf file.  This regex string should get you started if you want to try that approach.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;(?&amp;lt;ts&amp;gt;[^,]+),(?&amp;lt;serverhost&amp;gt;[^,]+),(?&amp;lt;username&amp;gt;[^,]+),(?&amp;lt;host&amp;gt;[^,]+),(?&amp;lt;connectionid&amp;gt;[^,]+),(?&amp;lt;queryid&amp;gt;[^,]+),(?&amp;lt;operation&amp;gt;[^,]+),(?&amp;lt;database&amp;gt;[^,]+),(?&amp;lt;object&amp;gt;'?.*'?),(?&amp;lt;retcode&amp;gt;\d+)
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sat, 11 Mar 2017 18:44:22 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/CSV-Field-extractions-with-one-field-has-extra-commas-with-in/m-p/351602#M64471</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2017-03-11T18:44:22Z</dc:date>
    </item>
    <item>
      <title>Re: CSV Field extractions with one field has extra commas with in single quotes</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/CSV-Field-extractions-with-one-field-has-extra-commas-with-in/m-p/351603#M64472</link>
      <description>&lt;P&gt;I was able to ingest your data successfully using the Add Data Wizard, using the following changes... &lt;/P&gt;

&lt;OL&gt;
&lt;LI&gt;In the "Set source type" stage, you should choose CSV from the "Source type" dropdown &lt;/LI&gt;
&lt;LI&gt;Under "Delimited settings", which appears after you choose CSV, you should choose single quote as your quote character.&lt;/LI&gt;
&lt;LI&gt;At the end of the process, you should pick a different source type name, so you don't confuse future, more general CSV users.&lt;/LI&gt;
&lt;/OL&gt;

&lt;P&gt;Accepting all the other defaults worked for me! &lt;/P&gt;</description>
      <pubDate>Sat, 11 Mar 2017 21:30:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/CSV-Field-extractions-with-one-field-has-extra-commas-with-in/m-p/351603#M64472</guid>
      <dc:creator>acruise_splunk</dc:creator>
      <dc:date>2017-03-11T21:30:47Z</dc:date>
    </item>
    <item>
      <title>Re: CSV Field extractions with one field has extra commas with in single quotes</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/CSV-Field-extractions-with-one-field-has-extra-commas-with-in/m-p/351604#M64473</link>
      <description>&lt;P&gt;Thanks this worked out great.&lt;/P&gt;</description>
      <pubDate>Sat, 11 Mar 2017 22:29:08 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/CSV-Field-extractions-with-one-field-has-extra-commas-with-in/m-p/351604#M64473</guid>
      <dc:creator>som3guy</dc:creator>
      <dc:date>2017-03-11T22:29:08Z</dc:date>
    </item>
  </channel>
</rss>

