Quantcast

Producing a csv file with a header in Simple Data Writer

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Producing a csv file with a header in Simple Data Writer

thanh nguyen
Hi all,

Can anyone help me to enable header writing in the CSV file? Enabling the
property "print_field_names" in the file jmeter.properties doesn't help.
Here's a copy of that file:

Thanks
Thanh

#---------------------------------------------------------------------------
# Results file configuration
#---------------------------------------------------------------------------

# This section helps determine how result data will be saved.
# The commented out values are the defaults.

# legitimate values: xml, csv, db. Only xml and csv are currently supported.
#jmeter.save.saveservice.output_format=xml
#jmeter.save.saveservice.output_format=csv

# true when field should be saved; false otherwise

# assertion_results_failure_message only affects CSV output
#jmeter.save.saveservice.assertion_results_failure_message=false
#
# legitimate values: none, first, all
#jmeter.save.saveservice.assertion_results=none
#
#jmeter.save.saveservice.data_type=true
#jmeter.save.saveservice.label=true
#jmeter.save.saveservice.response_code=true
# response_data is not currently supported for CSV output
#jmeter.save.saveservice.response_data=false
# Save ResponseData for failed samples
#jmeter.save.saveservice.response_data.on_error=false
#jmeter.save.saveservice.response_message=true
#jmeter.save.saveservice.successful=true
#jmeter.save.saveservice.thread_name=true
#jmeter.save.saveservice.time=true
#jmeter.save.saveservice.subresults=true
#jmeter.save.saveservice.assertions=true
#jmeter.save.saveservice.latency=true
#jmeter.save.saveservice.samplerData=false
#jmeter.save.saveservice.responseHeaders=false
#jmeter.save.saveservice.requestHeaders=false
#jmeter.save.saveservice.encoding=false
#jmeter.save.saveservice.bytes=true
#jmeter.save.saveservice.url=false
#jmeter.save.saveservice.filename=false
#jmeter.save.saveservice.hostname=false
#jmeter.save.saveservice.thread_counts=false
#jmeter.save.saveservice.sample_count=false
#jmeter.save.saveservice.idle_time=false

# Timestamp format - this only affects CSV output files
# legitimate values: none, ms, or a format suitable for SimpleDateFormat
#jmeter.save.saveservice.timestamp_format=ms
#jmeter.save.saveservice.timestamp_format=yyyy-MM-dd HH:mm:ss.SSSS
jmeter.save.saveservice.timestamp_format=yyyy-MM-dd HH:mm:ss

# For use with Comma-separated value (CSV) files or other formats
# where the fields' values are separated by specified delimiters.
# Default:
#jmeter.save.saveservice.default_delimiter=,
# For TAB, since JMeter 2.3 one can use:
#jmeter.save.saveservice.default_delimiter=\t
jmeter.save.saveservice.default_delimiter=;

# Only applies to CSV format files:
#jmeter.save.saveservice.print_field_names=false
jmeter.save.saveservice.print_field_names=true

# Optional list of JMeter variable names whose values are to be saved in the
result data files.
# Use commas to separate the names. For example:
#sample_variables=SESSION_ID,REFERENCE
sample_variables=SCENARIO

# N.B. The current implementation saves the values in XML as attributes,
# so the names must be valid XML names.
# Versions of JMeter after 2.3.2 send the variable to all servers
# to ensure that the correct data is available at the client.

# Optional xml processing instruction for line 2 of the file:
#jmeter.save.saveservice.xml_pi=<?xml-stylesheet type="text/xsl"
href="../extras/jmeter-results-detail-report_21.xsl"?>
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Producing a csv file with a header in Simple Data Writer

shettyd
Did you try this setting on the Configure button?

On Thu, Aug 19, 2010 at 1:21 PM, thanh nguyen <[hidden email]>wrote:

> Hi all,
>
> Can anyone help me to enable header writing in the CSV file? Enabling the
> property "print_field_names" in the file jmeter.properties doesn't help.
> Here's a copy of that file:
>
> Thanks
> Thanh
>
>
> #---------------------------------------------------------------------------
> # Results file configuration
>
> #---------------------------------------------------------------------------
>
> # This section helps determine how result data will be saved.
> # The commented out values are the defaults.
>
> # legitimate values: xml, csv, db. Only xml and csv are currently
> supported.
> #jmeter.save.saveservice.output_format=xml
> #jmeter.save.saveservice.output_format=csv
>
> # true when field should be saved; false otherwise
>
> # assertion_results_failure_message only affects CSV output
> #jmeter.save.saveservice.assertion_results_failure_message=false
> #
> # legitimate values: none, first, all
> #jmeter.save.saveservice.assertion_results=none
> #
> #jmeter.save.saveservice.data_type=true
> #jmeter.save.saveservice.label=true
> #jmeter.save.saveservice.response_code=true
> # response_data is not currently supported for CSV output
> #jmeter.save.saveservice.response_data=false
> # Save ResponseData for failed samples
> #jmeter.save.saveservice.response_data.on_error=false
> #jmeter.save.saveservice.response_message=true
> #jmeter.save.saveservice.successful=true
> #jmeter.save.saveservice.thread_name=true
> #jmeter.save.saveservice.time=true
> #jmeter.save.saveservice.subresults=true
> #jmeter.save.saveservice.assertions=true
> #jmeter.save.saveservice.latency=true
> #jmeter.save.saveservice.samplerData=false
> #jmeter.save.saveservice.responseHeaders=false
> #jmeter.save.saveservice.requestHeaders=false
> #jmeter.save.saveservice.encoding=false
> #jmeter.save.saveservice.bytes=true
> #jmeter.save.saveservice.url=false
> #jmeter.save.saveservice.filename=false
> #jmeter.save.saveservice.hostname=false
> #jmeter.save.saveservice.thread_counts=false
> #jmeter.save.saveservice.sample_count=false
> #jmeter.save.saveservice.idle_time=false
>
> # Timestamp format - this only affects CSV output files
> # legitimate values: none, ms, or a format suitable for SimpleDateFormat
> #jmeter.save.saveservice.timestamp_format=ms
> #jmeter.save.saveservice.timestamp_format=yyyy-MM-dd HH:mm:ss.SSSS
> jmeter.save.saveservice.timestamp_format=yyyy-MM-dd HH:mm:ss
>
> # For use with Comma-separated value (CSV) files or other formats
> # where the fields' values are separated by specified delimiters.
> # Default:
> #jmeter.save.saveservice.default_delimiter=,
> # For TAB, since JMeter 2.3 one can use:
> #jmeter.save.saveservice.default_delimiter=\t
> jmeter.save.saveservice.default_delimiter=;
>
> # Only applies to CSV format files:
> #jmeter.save.saveservice.print_field_names=false
> jmeter.save.saveservice.print_field_names=true
>
> # Optional list of JMeter variable names whose values are to be saved in
> the
> result data files.
> # Use commas to separate the names. For example:
> #sample_variables=SESSION_ID,REFERENCE
> sample_variables=SCENARIO
>
> # N.B. The current implementation saves the values in XML as attributes,
> # so the names must be valid XML names.
> # Versions of JMeter after 2.3.2 send the variable to all servers
> # to ensure that the correct data is available at the client.
>
> # Optional xml processing instruction for line 2 of the file:
> #jmeter.save.saveservice.xml_pi=<?xml-stylesheet type="text/xsl"
> href="../extras/jmeter-results-detail-report_21.xsl"?>
>
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Producing a csv file with a header in Simple Data Writer

gurjant singh
In reply to this post by thanh nguyen
Hi Thanh,

In the configuration, un-check the save as XML option and in the properties
file set *jmeter.save.saveservice.*
*output_format=csv*, you will* *get the response in the as a CSV file.

Thank,
-Bunty



On Fri, Aug 20, 2010 at 1:51 AM, thanh nguyen <[hidden email]>wrote:

> Hi all,
>
> Can anyone help me to enable header writing in the CSV file? Enabling the
> property "print_field_names" in the file jmeter.properties doesn't help.
> Here's a copy of that file:
>
> Thanks
> Thanh
>
>
> #---------------------------------------------------------------------------
> # Results file configuration
>
> #---------------------------------------------------------------------------
>
> # This section helps determine how result data will be saved.
> # The commented out values are the defaults.
>
> # legitimate values: xml, csv, db. Only xml and csv are currently
> supported.
> #jmeter.save.saveservice.output_format=xml
> #jmeter.save.saveservice.output_format=csv
>
> # true when field should be saved; false otherwise
>
> # assertion_results_failure_message only affects CSV output
> #jmeter.save.saveservice.assertion_results_failure_message=false
> #
> # legitimate values: none, first, all
> #jmeter.save.saveservice.assertion_results=none
> #
> #jmeter.save.saveservice.data_type=true
> #jmeter.save.saveservice.label=true
> #jmeter.save.saveservice.response_code=true
> # response_data is not currently supported for CSV output
> #jmeter.save.saveservice.response_data=false
> # Save ResponseData for failed samples
> #jmeter.save.saveservice.response_data.on_error=false
> #jmeter.save.saveservice.response_message=true
> #jmeter.save.saveservice.successful=true
> #jmeter.save.saveservice.thread_name=true
> #jmeter.save.saveservice.time=true
> #jmeter.save.saveservice.subresults=true
> #jmeter.save.saveservice.assertions=true
> #jmeter.save.saveservice.latency=true
> #jmeter.save.saveservice.samplerData=false
> #jmeter.save.saveservice.responseHeaders=false
> #jmeter.save.saveservice.requestHeaders=false
> #jmeter.save.saveservice.encoding=false
> #jmeter.save.saveservice.bytes=true
> #jmeter.save.saveservice.url=false
> #jmeter.save.saveservice.filename=false
> #jmeter.save.saveservice.hostname=false
> #jmeter.save.saveservice.thread_counts=false
> #jmeter.save.saveservice.sample_count=false
> #jmeter.save.saveservice.idle_time=false
>
> # Timestamp format - this only affects CSV output files
> # legitimate values: none, ms, or a format suitable for SimpleDateFormat
> #jmeter.save.saveservice.timestamp_format=ms
> #jmeter.save.saveservice.timestamp_format=yyyy-MM-dd HH:mm:ss.SSSS
> jmeter.save.saveservice.timestamp_format=yyyy-MM-dd HH:mm:ss
>
> # For use with Comma-separated value (CSV) files or other formats
> # where the fields' values are separated by specified delimiters.
> # Default:
> #jmeter.save.saveservice.default_delimiter=,
> # For TAB, since JMeter 2.3 one can use:
> #jmeter.save.saveservice.default_delimiter=\t
> jmeter.save.saveservice.default_delimiter=;
>
> # Only applies to CSV format files:
> #jmeter.save.saveservice.print_field_names=false
> jmeter.save.saveservice.print_field_names=true
>
> # Optional list of JMeter variable names whose values are to be saved in
> the
> result data files.
> # Use commas to separate the names. For example:
> #sample_variables=SESSION_ID,REFERENCE
> sample_variables=SCENARIO
>
> # N.B. The current implementation saves the values in XML as attributes,
> # so the names must be valid XML names.
> # Versions of JMeter after 2.3.2 send the variable to all servers
> # to ensure that the correct data is available at the client.
>
> # Optional xml processing instruction for line 2 of the file:
> #jmeter.save.saveservice.xml_pi=<?xml-stylesheet type="text/xsl"
> href="../extras/jmeter-results-detail-report_21.xsl"?>
>
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Producing a csv file with a header in Simple Data Writer

sebb-2-2
On 20 August 2010 06:44, gurjant singh <[hidden email]> wrote:
> Hi Thanh,
>
> In the configuration, un-check the save as XML option and in the properties
> file set *jmeter.save.saveservice.*
> *output_format=csv*, you will* *get the response in the as a CSV file.

Note:

The Configuration dialogue applies to its Listener only.
The properties apply to the listener which is added when you use the
-l flag, usually only used in non-GUI mode.

> Thank,
> -Bunty
>
>
>
> On Fri, Aug 20, 2010 at 1:51 AM, thanh nguyen <[hidden email]>wrote:
>
>> Hi all,
>>
>> Can anyone help me to enable header writing in the CSV file? Enabling the
>> property "print_field_names" in the file jmeter.properties doesn't help.
>> Here's a copy of that file:
>>
>> Thanks
>> Thanh
>>
>>
>> #---------------------------------------------------------------------------
>> # Results file configuration
>>
>> #---------------------------------------------------------------------------
>>
>> # This section helps determine how result data will be saved.
>> # The commented out values are the defaults.
>>
>> # legitimate values: xml, csv, db. Only xml and csv are currently
>> supported.
>> #jmeter.save.saveservice.output_format=xml
>> #jmeter.save.saveservice.output_format=csv
>>
>> # true when field should be saved; false otherwise
>>
>> # assertion_results_failure_message only affects CSV output
>> #jmeter.save.saveservice.assertion_results_failure_message=false
>> #
>> # legitimate values: none, first, all
>> #jmeter.save.saveservice.assertion_results=none
>> #
>> #jmeter.save.saveservice.data_type=true
>> #jmeter.save.saveservice.label=true
>> #jmeter.save.saveservice.response_code=true
>> # response_data is not currently supported for CSV output
>> #jmeter.save.saveservice.response_data=false
>> # Save ResponseData for failed samples
>> #jmeter.save.saveservice.response_data.on_error=false
>> #jmeter.save.saveservice.response_message=true
>> #jmeter.save.saveservice.successful=true
>> #jmeter.save.saveservice.thread_name=true
>> #jmeter.save.saveservice.time=true
>> #jmeter.save.saveservice.subresults=true
>> #jmeter.save.saveservice.assertions=true
>> #jmeter.save.saveservice.latency=true
>> #jmeter.save.saveservice.samplerData=false
>> #jmeter.save.saveservice.responseHeaders=false
>> #jmeter.save.saveservice.requestHeaders=false
>> #jmeter.save.saveservice.encoding=false
>> #jmeter.save.saveservice.bytes=true
>> #jmeter.save.saveservice.url=false
>> #jmeter.save.saveservice.filename=false
>> #jmeter.save.saveservice.hostname=false
>> #jmeter.save.saveservice.thread_counts=false
>> #jmeter.save.saveservice.sample_count=false
>> #jmeter.save.saveservice.idle_time=false
>>
>> # Timestamp format - this only affects CSV output files
>> # legitimate values: none, ms, or a format suitable for SimpleDateFormat
>> #jmeter.save.saveservice.timestamp_format=ms
>> #jmeter.save.saveservice.timestamp_format=yyyy-MM-dd HH:mm:ss.SSSS
>> jmeter.save.saveservice.timestamp_format=yyyy-MM-dd HH:mm:ss
>>
>> # For use with Comma-separated value (CSV) files or other formats
>> # where the fields' values are separated by specified delimiters.
>> # Default:
>> #jmeter.save.saveservice.default_delimiter=,
>> # For TAB, since JMeter 2.3 one can use:
>> #jmeter.save.saveservice.default_delimiter=\t
>> jmeter.save.saveservice.default_delimiter=;
>>
>> # Only applies to CSV format files:
>> #jmeter.save.saveservice.print_field_names=false
>> jmeter.save.saveservice.print_field_names=true
>>
>> # Optional list of JMeter variable names whose values are to be saved in
>> the
>> result data files.
>> # Use commas to separate the names. For example:
>> #sample_variables=SESSION_ID,REFERENCE
>> sample_variables=SCENARIO
>>
>> # N.B. The current implementation saves the values in XML as attributes,
>> # so the names must be valid XML names.
>> # Versions of JMeter after 2.3.2 send the variable to all servers
>> # to ensure that the correct data is available at the client.
>>
>> # Optional xml processing instruction for line 2 of the file:
>> #jmeter.save.saveservice.xml_pi=<?xml-stylesheet type="text/xsl"
>> href="../extras/jmeter-results-detail-report_21.xsl"?>
>>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Producing a csv file with a header in Simple Data Writer

MaheshRana
This post has NOT been accepted by the mailing list yet.
Hi,
I am using "Save Response to a File" listener, and my properties is

"
# legitimate values: xml, csv, db.  Only xml and csv are currently supported.
jmeter.save.saveservice.output_format=csv

even After applying all these, I am not getting my response in CSV format.

Can you please hel p me?

Thanks
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Producing a csv file with a header in Simple Data Writer

prabhu
This post has NOT been accepted by the mailing list yet.
Hi,
   This change in properties file apply only for the aggregate report listener JTL file format. If you want the custom results to be in desired format, use Flexible file writer plugin. http://code.google.com/p/jmeter-plugins/wiki/FlexibleFileWriter

Thanks
prabhu
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Producing a csv file with a header in Simple Data Writer

MaheshRana
This post has NOT been accepted by the mailing list yet.
Hi Prabhu,
Thanks first of all,
how i can use this plugin?
I just extract this plugin under lib folder and after that i could able to add this flexible file writer into my test plan and even i could able to generate CSV file but could not able to get data inside that CSV.
I want to get Respose data of one of my sampler.

Pls help....

Thanks,
Mahesh


On Fri, Aug 10, 2012 at 4:28 PM, prabhu [via JMeter] <[hidden email]> wrote:
Hi,
   This change in properties file apply only for the aggregate report listener JTL file format. If you want the custom results to be in desired format, use Flexible file writer plugin. http://code.google.com/p/jmeter-plugins/wiki/FlexibleFileWriter

Thanks
prabhu


If you reply to this email, your message will be added to the discussion below:
http://jmeter.512774.n5.nabble.com/Producing-a-csv-file-with-a-header-in-Simple-Data-Writer-tp2641496p5714282.html
To unsubscribe from Producing a csv file with a header in Simple Data Writer, click here.
NAML

Loading...