In my page A.php , I prepare a query like this : SELECT * FROM table WHERE id = ?
And I can use same PDO Prepared statements in this page , that I know.
But , if other page B.php also need the same query .
Am I need to prepared that query again?
Or how can I use the same PDO Prepared statements.
Or when I prepare the same query , server will auto know that was prepared?
Situation:
If i have a database website , then there are hundreds of pages load data just like the same way.
When user open each page , the query will send every times.
How can I build the page more wisely?
I am not looking for use the same "STRING" of query ;
I mean it is prepared statements , that I don't use $PDO->prepare again.
Is it possible?