jmeter-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sebb <seb...@gmail.com>
Subject Re: Can one 'CSV Data Set Config' point, via a vriable, to another CSV file location?
Date Mon, 23 Jan 2012 01:14:38 GMT
On 22 January 2012 13:29, danimni <danimni@gmail.com> wrote:
> Hi All,
> I have a question regarding 'CSV Data Set Config'.
> Can one 'CSV Data Set Config' point, via a vriable, to another CSV file
> location?
> I have this test, where I would like to run it several time, each time with
> different 'CSV data set config'.
> So, I've created the first 'CSV Data Set Config', where one of the variables
> is "SECOND_CSV_LOCATION".
> And for the second 'CSV Data Set Config', in the 'Filename' field, I set
> ${SECOND_CSV_LOCATION}.
> This way, I don't have to open the jmeter GUI each time I need to change the
> second CSV file location.
> For example
> First CSV gets the following values:
> Filename: c:\jmeter\MyTest\FirstCSVFile
> Variable Names: Host,Port,SECOND_CSV_LOCATION
>
> where 'SECOND_CSV_LOCATION' gets "c:\jmeter\MyTest\SecondCSVFile1" OR
> "c:\jmeter\MyTest\SecondCSVFile2"
>
> Second CSV gets the following values:
> Filename: ${SECOND_CSV_LOCATION}
> Variable Names: Username,Password
>
> I hope my explanations are clear.. :)

No need to use CSV to read the variable.

Just pass the file name on the command line as a property:

jmeter -JCSVNAME=xxxxx

and then use ${__P(CSVNAME)} in the filename field.

Or you can define the property in user.properties.


> Thanks in advanced,
> Dan.
>
> --
> View this message in context: http://jmeter.512774.n5.nabble.com/Can-one-CSV-Data-Set-Config-point-via-a-vriable-to-another-CSV-file-location-tp5164044p5164044.html
> Sent from the JMeter - User mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@jmeter.apache.org
> For additional commands, e-mail: user-help@jmeter.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@jmeter.apache.org
For additional commands, e-mail: user-help@jmeter.apache.org


Mime
View raw message