You create a MySQL table in the normal way, with three attributes - height, width and price, and insert the values as required. The Select query given will return the value of price which matches your input height and width, assuming these values already exist in the table of course.
But if you use a formula to calculate the price
eg height x width x 1.25 = price in pounds, you don't need a database at all, just do the calculation in a script.
Dare I suggest reading a book on databases in general, and then one on using php with mysql, to get a better idea of what is involved. You'll also have to learn some sql commands as well.
Learning databases is not a five minute, or five day or five month job, unfortunately. It takes time.
A simple introductory text such as Relational Databases by Colin Ritchie would help. I also used PHP Fast & Easy by Julie Meloni as a basic intro in simple linking of php to mysql databases.