Now that we have gone through the basics of php functions and how databases work, talk to the servers, and interact with those servers, it is important to understand how this process all works. This brings us to php recordsets. Now there wasn't much literature on what a recordset really is but I did find a couple sources that briefly describe what it is. On Wikipedia it describes a recordset as "a data structure that consists of a group of database records, and can either come from a base table or as the result of a query to the table." An assumed expert from Experts-Exchange.com says that a recordset is a collection of records, or a table in the database. Also when you call SELECT from a table you get back a recordset.
Now this is all and good but why is it important to you? If we were to understand how this recordset gets from the database to your computer, I'm sure you'll better appreciate all those company's websites that hold your billing and shipping information so that you don't have to retype over and over again. Bellow is an illustration that we discussed in class about this interaction.
As you can see when you login or "request" information from the database, it first hits the web server and it realizes that you php coding is reserved for the application server so it sends your request there to interpret what it is that you want to do and what you want to get. The application server sends a query to the database and pulls out the information that you requested. The information that comes out is referred to as a recordset. Then - as it was explained to us in class - the application server caches the information there and sends the information back to the web server in a language that it can interpret and then back to you! Now if you ever go back to request the similar information, the application server will already have it for you.
This is just a very simple description of what is happening but it explains what a recordset is and where it comes from.