Need help with SQL query using parameters from table rows

Hello everyone,

I’m currently working on an SQL query and I could really use your help. What I’m trying to achieve is to execute a query for each row in a table, where the parameters passed to the query come from the values in that row.

For example, let’s say I have a table with columns “Name”, “Age”, and “Gender”. I want to execute a query for each row, where the query is something like “SELECT * FROM People WHERE Name = ‘John’ AND Age = 30 AND Gender = ‘Male’”, but instead of using the hardcoded values, I want to use the values from each row in the table.

I’m not sure how to accomplish this, so any help or guidance would be greatly appreciated. Thank you in advance!