0
votes

My script is created csv file and then read this file in csv data set config. I have a file name and put into a variable (path) and send ${path} in filename input of CSV data set config. I debug and path variable has value as I want, example (Perf_04.csv) and the file is also created. But Jmeter always shows issue that ${path} does not exist. Did anyone get the idea for this issue? Seemly that when running Jmeter will be run csv data set config first and it throws an error when can't find this file from the beginning.

1
Set the absolute file path rather the relative path.Masud Jahan
My file name is dynamic so i need put value into input filename of csv data set configAlex Le
Oh, Your CSV Data Set Config will initialise first in your test plan. Thats the reason.Masud Jahan
But why if i put exactly name or variable from User define variables, this issue is not occur?Alex Le

1 Answers

0
votes

As per JMeter Documentation the execution order of test elements looks like

  1. Configuration elements

  2. Pre-Processors

  3. Timers

  4. Sampler

  5. Post-Processors (unless SampleResult is null)

  6. Assertions (unless SampleResult is null)

  7. Listeners (unless SampleResult is null)

So your CSV Data Set Config is being initialized before the csv file is actually being created. As of current JMeter version (JMeter 5.0) there is no way of amending this behavior, you can consider consuming data from the CSV file using i.e. __CSVRead() function instead.