Sql queries
How do you pass parameters in a SQL query to receive the data in a display page.
Here is my scenario:
SELECT *
FROM table1 LEFT JOIN table2 ON table1.iID=table2.pID
WHERE iID = pID
============================================
It joins all the records from table1 to table2 but it only displays the first record. I can´t seem to get the parameter correct to display the proper record when is passed.
I´ve seen other scenarios like:
WHERE (iID = ?) or WHERE iID = 'pID's
But they don't work, what am I missing here.
thanks.