did you make the change to the code I suggested? What does MySQL say the error is? -Micah On Friday 10 September 2004 07:49 am, Stuart Felenstein wrote: > As I said this is a code generator (dbqwiksite). So, > describing the process for creating the code is > different. The $sql is fine, as far as typos or > incorrect characterrs. I've gone through those > statement very carefully. > I've also tried to run a debug with no luck. > But I do know that there is something wrong with the > statement, since I can get a complete display of all > records, but can't search using criteria. > > Below is the $sql, one I know works , though I've > tried others. VendorJobs is the table I'm querying , > and since it's made up of values from other static > type tables I have all the joins in place. > > I've also taken the tick marks out, thinking maybe it > was a style issue. I'm not sure where to go with it. > Getting a response from the company is like pretty > difficult. > > `VendorJobs`.`JobID`, > `VendorSignUp`.`CompanyName`, > `StaIndTypes`.`CareerCategories`, > `StaUSCities`.`City`, > `USStates`.`States`, > `VendorJobs`.`AreaCode`, > `staTaxTerm`.`TaxTerm`, > `VendorJobs`.`PayRate`, > `staTravelReq`.`TravelReq`, > `VendorJobDetails`.`Details`, > `VendorJobs`.`PostStart`, > `VendorJobs`.`JobTitle` > FROM > `VendorJobs` > INNER JOIN `VendorSignUp` ON > (`VendorJobs`.`VendorID` = `VendorSignUp`.`VendorID`) > INNER JOIN `StaIndTypes` ON (`VendorJobs`.`Industry` > = `StaIndTypes`.`CareerIDs`) > LEFT OUTER JOIN `StaUSCities` ON > (`VendorJobs`.`LocationCity` = `StaUSCities`.`CityID`) > LEFT OUTER JOIN `USStates` ON > (`VendorJobs`.`LocationState` = `USStates`.`StateID`) > LEFT OUTER JOIN `staTaxTerm` ON > (`VendorJobs`.`TaxTerm` = `staTaxTerm`.`TaxTermID`) > INNER JOIN `staTravelReq` ON > (`VendorJobs`.`TravelReq` = > `staTravelReq`.`TravelReqID`) > INNER JOIN `VendorJobDetails` ON > (`VendorJobs`.`JobID` = `VendorJobDetails`.`JobID`) > > Stuart > > --- Philip Thompson <prthomp@xxxxxxxx> wrote: > > I think everyone knows that $sql is a statement. But > > what people are > > asking is: what is that statement?! Because if there > > are "incorrect" > > characters or 's in that statement, then that can > > break your > > code/statement. > > > > ~Philip > > > > On Sep 9, 2004, at 5:49 PM, Stuart Felenstein wrote: > > > Just getting back to this thing. There are 3 > > > > files > > > > > involved, search.php, connections.php and > > > functions.php. > > > > > > I searched through all and couldn't find the > > > > meaning > > > > > of the $sql_ext. $sql is just the sql statement > > > > I > > > > > inserted into the code. > > > > > > Great that I can't get a response from the > > > > company. > > > > > If anyone thinks it would be useful to post the > > > > code I > > > > > will. That is if anyone would want to see and look > > > > at > > > > > it. > > > > > > The weird thing is searching on one table is > > > > great. > > > > > The list (all records) works great. The problem > > > starts when I insert all my joins. Now I've > > > > tested > > > > > and retested the query and I know it's fine. > > > > > > Thank you , > > > Stuart > > > > > > --- Steve Davies <steve@xxxxxxxxxxxxxxxxxx> wrote: > > >> What's contained in $sql and $sql_ext ??? > > >> > > >> Stuart Felenstein wrote: > > >>> I'm using a product called dbqwiksite pro. PHP > > >>> generator for PHP - MySQL > > >>> > > >>> The code seems to be working fine except in my > > >> > > >> search > > >> > > >>> page where I receive an "invalid query" > > >>> > > >>> $result = mysql_query($sql . " " . $sql_ext . " > > >> > > >> limit > > >> > > >>> 0,1") > > >>> or die("Invalid query"); > > >>> > > >>> This is the place I where the code is taking the > > >> > > >> die > > >> > > >>> path. > > >>> I'm guessing something belongs between the > > >> > > >> quotation > > >> > > >>> marks , just not sure. > > >>> > > >>> Anyone ? > > >>> > > >>> Thank you > > >>> Stuart > > >> > > >> -- > > >> PHP Database Mailing List (http://www.php.net/) > > >> To unsubscribe, visit: > > > > http://www.php.net/unsub.php > > > > > -- > > > PHP Database Mailing List (http://www.php.net/) > > > To unsubscribe, visit: > > > > http://www.php.net/unsub.php > > > > > > -- > > PHP Database Mailing List (http://www.php.net/) > > To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php