JMeter tutorial 07 - How to read data from CSV File | Parameterization in JMeter

  Рет қаралды 56,524

Quality Assurance Lab

Quality Assurance Lab

5 жыл бұрын

Hi Guys!
This video covers the concept of Parameterization, i.e. how to read data from CSV File in JMeter.
Learning:
What is Parameterization?
Parameterization is the process of creating multiple test data for single/multiple users in a test script
Why Parameterization?
Let’s say You have the task to load test the login functionality of the application under test. Since, it is a load test, you can not test it with a single login. In this case, you need to test it with multiple test data and hence you need to use the concept of parameterization.
Steps to parameterize your test data:
1)Put the test data in CSV file
2)Configure JMeter to read those test data from CSV file by adding Config Element - CSV data set config
3)Replace hard coded test data with variable
Fields under CSV dataset config:
1)Filename: This refers to the path to the CSV file which contains the test data
2)File Encoding: The encoding technique by which you want to read the CSV file eg: UTF-8
3)Variable Names: List your variable names(comma separated) to match the columns in the CSV file. You can keep this field empty if you want to use first line of CSV file as variable name
4)Ignore First Line: Set this field to True if you want to ignore the first line of CSV file, else take the default value -False. It is used only if Variable Names is not empty
5)Delimiter: ',' by default, you can set anything else too
6)Allow Quoted Data: Set this field to True if you have double quotes in CSV columns, else take the default value -False
7)Recycle on EOF: Set this field to True if you want JMeter to restart from the beginning when the End Of File is reached, else take the default value -False
8)Stop Thread on EOF: Set this field to True if you want to stop the current thread if EOF is reached; else take the default value -False;
9)Sharing Mode: It selects threads which share the same file pointer
==================================================================
JMeter Tutorial Playlist:
• JMeter Tutorial
Git and GitHub Tutorial Playlist:
• Git and GitHub Tutorial
Automation Anywhere Tutorial Playlist:
• Automation Anywhere A1...
UiPath Tutorial Playlist:
• UiPath Tutorial
Subscribe for more tutorials - / @qualityassurancelab7764

Пікірлер: 58
@3VAudioVideo
@3VAudioVideo 2 жыл бұрын
For the "Send Parameters With the Request" section/table, for me if I replace "Value" columns with junk values, but not delete the "Jmeter" in the "Path" field (where it is "/wiki/Jmeter") as you mention at around 5:10, then the execution still takes me to the correct web page. So is my test still valid like this - meaning will my response time still be accurate and resemble how an actual person submits the request? Also, if i do delete "JMeter" in the path, the response also returns the JMeter page (as long as the "search" parameter is "JMeter". But if I also leave the other parameters as junk, it will still work. so this is confusing).
@kotamyogeswarreddy5165
@kotamyogeswarreddy5165 2 жыл бұрын
very clear explanation.Tq so much mam...
@Ravikumar-yp8rm
@Ravikumar-yp8rm 2 жыл бұрын
Thank you... very nice video
@Jagdeesh_mimicry
@Jagdeesh_mimicry Жыл бұрын
if we have multiple hard coated values in our script what will approac?
@farazshaikh3654
@farazshaikh3654 3 жыл бұрын
Hi 🙋‍♂️ All videos are very helpful and easy to understand. My question is how can we fetch data from csv file for POST request ? Awaiting for your reply Thanks 😊
@hiteshkumar2356
@hiteshkumar2356 10 ай бұрын
I have an entry as "Asia,America" in CSV file and set the Jmeter csv config with delimeter with , and Allow quoted Data True, still getting the error in execution
@nealkaffrey2384
@nealkaffrey2384 3 жыл бұрын
Hello I have seached North America and I got the error in Jmeter. But when I searched North_America test script passed. (I search North America in Wikipedia Then modified the CSV file as north_america). why jemeter do not search north america? and to we can add ' _ ' in searching
@gavinjames9476
@gavinjames9476 2 жыл бұрын
If i have integer values like No of Month in csv file and it contains all integer values in it and i want to pass dynamically in Body Data tab of particular HTTP request for integer values then how to do it For example for string data we pass [" ${username}"] in Body data tab for string values.
@parshavcollection6351
@parshavcollection6351 9 ай бұрын
if you want to read random data from csv file. what to do?
@modernlifemanager7146
@modernlifemanager7146 3 ай бұрын
Hello Please help me with query. What would be the possible failure reason for a script if the environment gets changed for example from UAT env to pre-production environment.
@vnecksurferdude7041
@vnecksurferdude7041 3 жыл бұрын
wow, the Sharing Mode drop down options...thanks for explaining them. Now I COmPLEtelY understand it all.
@3VAudioVideo
@3VAudioVideo 2 жыл бұрын
Blazemeter has an excellent blog explaining this. Don't be so hard on the instructor here, as she is only going over the basic just to get you started. Otherwise this video would last for hours in order to go over ever little detail.
@anmoldhiman1954
@anmoldhiman1954 3 жыл бұрын
hi there, i am not able to get send parameters with the the request in searchinwikipedia even after creating video and all , which make me difficult to understand the video please help.
@ankitapatel808
@ankitapatel808 3 жыл бұрын
Hi Mam Your're really explaining worthy and helpful, appreciated thanks
@qualityassurancelab7764
@qualityassurancelab7764 3 жыл бұрын
Thank you so much!
@ankitapatel808
@ankitapatel808 3 жыл бұрын
Ma'am me beanshell script bana rahi hoon CSV me data write krne k liye single record k liye ho gaya ab is me muje loop use krna he ki jitni bar request pass ho utni bar diff row me CSV me write kre... Please guide🙏 Thanks in advance
@sk15aug
@sk15aug Ай бұрын
@@qualityassurancelab7764 In CSV file data, can we run these data parallely by putting nos of thread in thread group. For example, if there is 3 values in CSV file and if we pass nof of thread 3 in thread group, then will ittake and execute 3 data of csv file parallely ?
@PankajSingh-bt9hj
@PankajSingh-bt9hj 3 жыл бұрын
Made my day
@3VAudioVideo
@3VAudioVideo 2 жыл бұрын
me too! :)
@Ganesh.Vaka_9492
@Ganesh.Vaka_9492 2 жыл бұрын
Hi, We need complere explanation for the paramitrization of the sharing modes of all threads, current thread group, current thread
@shirishachippagiri543
@shirishachippagiri543 3 жыл бұрын
pass test data from one csv file to multiple http requests like first row should take by 1st http sample and second row should take by 2nd http sample.Please help how to use this in jmeter
@3VAudioVideo
@3VAudioVideo 2 жыл бұрын
Do a google search for "Blazemeter CSV Data Set Config in Sharing Mode - Made Easy" Blazementer explained this is detail.
@SazidAhmedNassir
@SazidAhmedNassir Жыл бұрын
How to generate html report using Csv dataset in jemter ? Can you please tell me?
@hiteshkumar2356
@hiteshkumar2356 10 ай бұрын
if you already have csv output then you can use this command in CLI to generate the html report. jmeter -g -o thanks!
@behumanf1rst
@behumanf1rst 4 жыл бұрын
I have post operations with different payloads each time, how do I config to have multiple payloads to invoke same API? url: abc.com/testdata operation: POST payload1: {"k1":"Have more data here"} payload2: {"k1":"Have further more data"}
@qualityassurancelab7764
@qualityassurancelab7764 4 жыл бұрын
Hi, please follow the below steps: Step 1: Add multiple payloads - "Have more data here", "Have further more data" etc under the csv file. Step 2: Add CSV dataset config for the HTTP request and provide necessary field details. Let's say that Variable Names field is PayloadVar Step 3: Put the payload under Body Data as "k1":${PayloadVar}, where PayloadVar is a variable created in step 2 For any detail to work on APIs(SOAP and REST) in Jmeter, please refer - kzbin.info/www/bejne/nIbbfYp-j7Cpo8k
@Akfan78
@Akfan78 4 жыл бұрын
@@qualityassurancelab7764 What if the payload spans thousand of rows and not feasible to be copied in the csv?
@markjon578
@markjon578 Жыл бұрын
hi mam iam sravan i have a query about jmeter every time am going to command prompt i can give the path of my result folder my cmd promt showing error like there is no file external or internal
@hiteshkumar2356
@hiteshkumar2356 10 ай бұрын
Bro you have to set the jmeter path. Go to System Advance setting, environment varable >system variable>click on path and edit it > select new > and add the path of jemeter bin folder here and save close the CLI and reopen it
@shriprasadgujare8639
@shriprasadgujare8639 2 жыл бұрын
how to get particular data from csv? in case you don't want to iterate over all the data.
@kapiljain7325
@kapiljain7325 2 жыл бұрын
You can control the data iterations
@uzairsiddiqui6660
@uzairsiddiqui6660 4 жыл бұрын
Hi, Thanks alot for this video, I have one question, How can give the image parameter (attributes) in Body Data Like Firstname, Lastname, Profile_image Field for the Post Query in HTTP Request.
@hafizuzairhasan2115
@hafizuzairhasan2115 4 жыл бұрын
Mam, Waiting for your reply.
@qualityassurancelab7764
@qualityassurancelab7764 4 жыл бұрын
Hi, you are welcome and apologies for late response. Checkout this video to work with POST query - kzbin.info/www/bejne/nIbbfYp-j7Cpo8k
@uzairsiddiqui6660
@uzairsiddiqui6660 4 жыл бұрын
Quality Assurance Lab mam I watched this video but my question is how to give image file attribute to body data. I want to give path from local directory.
@qualityassurancelab7764
@qualityassurancelab7764 4 жыл бұрын
@@uzairsiddiqui6660 Hi, please follow the below steps In HTTP Request Sampler to upload image file: Step 1: Select the Method as POST Step 2: Check the box - "Use multipart/form-data for POST" Step 3: Move to Files Upload ,click on Add and provide below details: File Path - Provide the complete path of the Image file Parameter Name - Provide relevant form of “file” type name, eg. imageFile MIME Type - Provide File's Internet media type. For eg. For GIF image , MIME Type is: image/gif For JPEG JFIF image, MIME Type is: image/jpeg Please let me know for any further query.
@user-sp9zo5re6u
@user-sp9zo5re6u 4 жыл бұрын
В консоли может быть ошибка An error occurred: Unknown arg: errorlevel=1 .Jmeter не нравится пробелы
@hiteshkumar2356
@hiteshkumar2356 10 ай бұрын
thanks for knowledge sharing videos. video quality is not so good (720p). please update them with atleast 1080p.
@rajasekharmaddigalla1463
@rajasekharmaddigalla1463 4 ай бұрын
Wow with my like it reached 500
@jayeshmahadik9828
@jayeshmahadik9828 3 жыл бұрын
Hi Mam, PLease explain Sharing Mode in detail.what is the purpose of different option provided in sharing mode
@vnecksurferdude7041
@vnecksurferdude7041 3 жыл бұрын
you can go to Blazmeter webpage and they do an excellent job explaining it. I agree, she did not explain anything about it at all here but just read the options for us. useless
@3VAudioVideo
@3VAudioVideo 2 жыл бұрын
@@vnecksurferdude7041 That's what I said about Blazmemter's page.
@LoveUPes
@LoveUPes 3 жыл бұрын
please work the volume. in some videos the volume is high in some videos the volume is so low
@qualityassurancelab7764
@qualityassurancelab7764 3 жыл бұрын
Apologies for the inconvenience, I will take care of volume
@jacki546
@jacki546 5 жыл бұрын
Hi I have a doubt on jmeter . can you help me
@qualityassurancelab7764
@qualityassurancelab7764 5 жыл бұрын
Sure..I will try.
@jacki546
@jacki546 5 жыл бұрын
@@qualityassurancelab7764can you please share the mail or contact number so that I can report my issue
@engineers-blog
@engineers-blog 4 жыл бұрын
I need help backend-service/v1/create/version1/xyz/900 , how will pass dynamic data from csv file now its 900, plz reply.
@qualityassurancelab7764
@qualityassurancelab7764 4 жыл бұрын
Do you have multiple values in CSV file(like 900) which you wish to pass to this url? If yes, you can pass the value in url as - backend-service/v1/create/version1/xyz/${NumberVariable}
@engineers-blog
@engineers-blog 4 жыл бұрын
@@qualityassurancelab7764 , NumberVariable , need to pass in parameter, can u give me one example.
@qualityassurancelab7764
@qualityassurancelab7764 4 жыл бұрын
@@engineers-blog Let's say that your variable name is NumberVariable. Then, you will pass it as ${NumberVariable}
@saurankukitchen3087
@saurankukitchen3087 3 ай бұрын
Getting error.
@teja_lingamsetti
@teja_lingamsetti 4 жыл бұрын
Hie...Can you pls explain parameterization with set of username and password. I mean how to pass username and password into fields via jmeter...awaiting for your help...Thanks!
@qualityassurancelab7764
@qualityassurancelab7764 4 жыл бұрын
Hi, parameterization for username and password will be same as I did for Continent in the video. Please let me know if you face any issue.
@Akfan78
@Akfan78 4 жыл бұрын
@@qualityassurancelab7764 Is there a way to protect these passwords from being visible? I do not want to expose the text of password like how it is displayed as Asia, or Europe in your case. Could you pls help?
@vnecksurferdude7041
@vnecksurferdude7041 3 жыл бұрын
@@Akfan78 lock up your computers every time you walk away from it.
@yogesh6541
@yogesh6541 2 жыл бұрын
Always take new stuff for every video don't keep as it is of last session..it is difficult to understand for new viewers
Playing hide and seek with my dog 🐶
00:25
Zach King
Рет қаралды 35 МЛН
Inside Out 2: Who is the strongest? Joy vs Envy vs Anger #shorts #animation
00:22
Каха заблудился в горах
00:57
К-Media
Рет қаралды 9 МЛН
Spot The Fake Animal For $10,000
00:40
MrBeast
Рет қаралды 186 МЛН
JMeter Beginner Tutorial 15 - How to read data from CSV file (Parameterisation)
14:48
JMeter Fetch Data from JSON File in Jmeter | How to Read JSON File in Jmeter
15:57
Software Automation Experience
Рет қаралды 5 М.
Jmeter  - Parameterization Input
13:56
Techie Lite
Рет қаралды 3 М.
JMeter tutorial 27 - JMeter Real Time Project | Learn JMeter in 50 Minutes!
50:52
Quality Assurance Lab
Рет қаралды 200 М.
Playing hide and seek with my dog 🐶
00:25
Zach King
Рет қаралды 35 МЛН