Start from here. Choose table(phptest2.phtml) Set query(phptest3.phtml) Show result(phptest4.phtml) Retrieve All(phptest5.phtml)