05-18-2009, 08:21 PM
|
#3 (permalink)
|
|
The Acquainted
Join Date: May 2009
Posts: 178
Thanks: 9
|
I assume i wouldnt be instantiating an object if it was a static method. Not really understanding your explantion. If i have mysql table with 10 rows in it each row being one of my favourite films with each column storing various info on that film and i want to recall all rows for display on a page i would, for example, have the query "select * from films". How do i handle this from an OO perspective. Do i run the select then loop through th results instantiating an object for each row and calling a method to display the objects? I could stick the query in a static method within the class. Dunno if i'm making sense but i assume this is one of the most fundamental situations in OOP but i'm clueless any guidance appreciated.
|
|
|
|