Wrox Programmer Forums
Go Back   Wrox Programmer Forums > PHP/MySQL > BOOK: Beginning PHP 5.3
|
BOOK: Beginning PHP 5.3
This is the forum to discuss the Wrox book Beginning PHP 5.3 by Matt Doyle; ISBN: 978-0-470-41396-8
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning PHP 5.3 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old October 20th, 2011, 12:48 AM
Authorized User
 
Join Date: Jun 2011
Posts: 51
Thanks: 9
Thanked 0 Times in 0 Posts
Send a message via MSN to nawar youssef
Default I resolve all the errors but this one..

I still have this error which I found no way to solve;
its :
Code:
public static function getMembers($startRow, $numRows, $order) {
			$conn = parent::connect();
			$sql = "SELCET SQL_CALC_FOUND_ROWS * FROM" . TBL_MEMBERS . "ORDER BY $order LIMIT :startRow, :numRows";
and the browser tells me that the syntax of SQL is not correct and I am sure of that and checked the documentation of the same sql that I have.
so whats the next step. thank you
 
Old October 20th, 2011, 08:58 AM
Friend of Wrox
 
Join Date: May 2011
Posts: 125
Thanks: 0
Thanked 24 Times in 24 Posts
Default

Greetings,

Try:
Code:
$sql = "SELCET SQL_CALC_FOUND_ROWS * FROM " . TBL_MEMBERS . " ORDER BY $order LIMIT :startRow, :numRows";
Added a space before and after TBL_MEMBERS, because if there are no spaces in the table name then the sql would end up being;
Code:
$sql = "SELCET SQL_CALC_FOUND_ROWS * FROMmembersORDER BY $order LIMIT :startRow, :numRows";
the above assumes the members table is simply called 'members'.
The Following User Says Thank You to UseLess For This Useful Post:
nawar youssef (October 21st, 2011)
 
Old October 21st, 2011, 12:14 AM
Authorized User
 
Join Date: Jun 2011
Posts: 51
Thanks: 9
Thanked 0 Times in 0 Posts
Send a message via MSN to nawar youssef
Default ooooohh man thank you so much

you know its very hard to find such a bug if you are not used to.
at first I added the space in one part, becasue I did not read you comment well and did not work. but after that I correct them, thanks





Similar Threads
Thread Thread Starter Forum Replies Last Post
How to resolve IDREF in XSL teahouse XSLT 3 September 15th, 2006 01:14 PM
need to resolve this.,. razmar78 BOOK: Professional SQL Server Reporting Services ISBN: 0-7645-6878-7 2 November 23rd, 2004 01:41 PM
cannot resolve symbol (struts) tomeksupergosc J2EE 2 November 23rd, 2004 01:19 PM
Error-cannot resolve symbol Rusk JSP Basics 1 February 18th, 2004 09:20 AM
cannot resolve symbol problem ioda006 JSP Basics 2 July 28th, 2003 06:04 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.