How to use CSV file for data driven testing

Hi, please someone help me on this.

I know there are some article about this but i still couldn’t figure it out.
I am creating script for testing login function
I have a CSV file which contains many records of login information, formatted as below
No userEmail userPassword status
1 hotest@gmail.com qwerty123
2 email2@gmail.com qwerty123
3 email3@gmail.com qwerty123
4 email4@gmail.com qwerty123

i created a script named login1 used as table action,please see attached image for the code.
and i have a table to actually execute the login flow,please check attached image for table

When i run the table. it keeps telling me that errors happen without any details.
Could anyone tells me what do i need to do to make this code run.

Thanks so much.

Your file isn’t a CSV file. CSV stands for comma-separated values and your values are separated with spaces. This means that your variables don’t exist (because “userEmail” isn’t separated from “No” and “userPassword” by commas) and each line is just one long data chunk.