Webmastersite.net
Register Log In

between search broken

Comments on between search broken

david
Forum Regular

Usergroup: Customer
Joined: Jun 22, 2005

Total Topics: 91
Total Comments: 305
david
Posted Sep 05, 2008 - 1:38 PM:

Hi Paul,

After upgrading to 5.0.3, the between searches that worked a minute ago, didn't work. I don't have the debug info, but I remember that instead of seeing a single digit (the 'search' part of a between search), I now saw both the 'search' and the 'searchmax' numbers in the DB query. So technically it was search a single field in the DB for 2 numbers.

I had to revert to 5.0.2, so I couldn't spend time on getting the debug info, but please test this on your WSN.

Thanks
David
david
Forum Regular

Usergroup: Customer
Joined: Jun 22, 2005

Total Topics: 91
Total Comments: 305
david
Posted Sep 05, 2008 - 2:37 PM:

I think I figured out the problem. I had one of the searchmax fields mistyped, and it threw the search into a frenzy.
david
Forum Regular

Usergroup: Customer
Joined: Jun 22, 2005

Total Topics: 91
Total Comments: 305
david
Posted Sep 05, 2008 - 2:59 PM:

An error occoured at c-ccc.com/search.php?action...r&filled=1&whichtype=links on 2008-09-05 21:57:53. Please relay this data to support. Error #2: 'mysql_fetch_row(): supplied argument is not a valid MySQL result resource' in /home/ccc/public_html/cventura/databases/mysql.php on line 50. Debug info:

An error occoured at cccc.com/search.php?action=...r&filled=1&whichtype=links on 2008-09-05 21:57:53. Please relay this data to support. Error #2: 'mysql_num_rows(): supplied argument is not a valid MySQL result resource' in /home/ccc/public_html/cventura/databases/mysql.php on line 47. Debug info:

That was the original error, and now I just got it again. Still figuring out why exactly...
david
Forum Regular

Usergroup: Customer
Joined: Jun 22, 2005

Total Topics: 91
Total Comments: 305
david
Posted Sep 05, 2008 - 3:07 PM:

the above error comes up when using both a min. and max. number to search between. if you just enter only a min. or a max. then everything is fine.
david
Forum Regular

Usergroup: Customer
Joined: Jun 22, 2005

Total Topics: 91
Total Comments: 305
david
Posted Sep 05, 2008 - 3:34 PM:

Here is a debug info:

Query 6: SELECT `id`,`to`,`subject`,`message`,`headers`,`replacement`,`mime` FROM wsnlinks_email WHERE timesent=0 AND inprogress=0 ORDER BY id ASC LIMIT 0,10

Load time so far: 0.1 seconds.

Number of rows is 0

Creating search with new as new

Query 7: INSERT INTO wsnlinks_searches(`id`,`value`,`memberid`,`catid`,`time`) VALUES('','budapest , kiado 1 223 2 222','1','','1220653959')

Query 8: SELECT `id` FROM wsnlinks_searches ORDER BY id DESC

Load time so far: 0.11 seconds.

Setting cookie with name testcookie, value 25 and expiration time 3441307917

Query 9: SELECT `id`,`title`,`url`,`description`,`rating`,`votes`,`validated`,`catid`,`sumofvotes`,`email`,`time`,`hits`,`numcomments`,`hide`,`ownerid`,`voterips`,`voterids`,`lastedit`,`type`,`notify`,`suspect`,`pendingedit`,`funds`,`suspended`,`alias`,`expire`,`ip`,`inalbum`,`typeorder`,`recipurl`,`hitsin`,`recipwith`,`hitsinips`,`hitsoutips`,`lastcomment`,`related`,`inhidden`,`viewers`,`threadviewers`,`hitsintemp`,`hitsouttemp`,`origtype`,`importance`,`parentids`,`timesdead`,`timesemailed`,`threadclosed`,`threadposters`,`lastposterid`,`lastpostername`,`ownername`,`deleted`,`deletionreason`,`movedto`,`deletedby`,`timevalidated`,`filefield`,`message`,`sticky`,`downloads`,`pollid`,`posticon`,`savedby`,`validatedemail`,`unpaid`,`recipverified`,`effectivetime`,`sugcatid`,`pagerank`,`wysihtml`,`movedid`,`unrevised`,`feedurl`,`feedcache`,`feedcachetime`,`tags`,`xmlsource`,`ordercomments`,`lastpadupdate`,`padfile`,`lastmonthlycheck`,`invisibleto`,`profileurl`,`lastprofileurl`,`timesrenewed`,`timedeleted`,`helyseg`,`ar`,`varos`,`epitoanyag`,`alapterulet`,`kertmeret`,`szobaszam`,`felszobaszam`,`erkely`,`futes`,`kilatas`,`tajolas`,`komfort`,`lift`,`emeleten`,`parkolas`,`lakasallapot`,`extrak`,`butorozott`,`szintek`,`kiadoar`,`helysegenglish`,`epitoanyagenglish`,`erkelyenglish`,`futesenglish`,`kilatasenglish`,`tajolasenglish`,`komfortenglish`,`liftenglish`,`parkolasenglish`,`lakasallapotenglish`,`extrakenglish`,`butorozottenglish`,`descriptionenglish`,`kerulet`,`megye`,`eladokiado`,`gepesitett`,`gepesitettenglish`,`cim`,`hazszam`,`adminnotes`,`telek`,`sponsorend`,`address`,`city`,`state`,`country`,`latitude`,`longitude`,`zip`,`kiadoareuro` FROM wsnlinks_links WHERE (validated=1 AND invisibleto NOT LIKE '%|3|%' AND hide=0 AND deleted=0 AND alias=0 AND inalbum=0) AND ((effectivetime < 1220653959) AND (helyseg = 'budapest' AND eladokiado LIKE '%, kiado%' AND kiadoareuro '1 223')) ORDER BY typeorder ASC,time DESC LIMIT 0,60

Load time so far: 0.12 seconds.

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''1 223')) ORDER BY typeorder ASC,time DESC LIMIT 0,60' at line 1

Load time so far: 0.12 seconds.

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''1 223')) ORDER BY typeorder ASC,time DESC LIMIT 0,60' at line 1

Query 10: SELECT COUNT(id) FROM wsnlinks_links WHERE (validated=1 AND invisibleto NOT LIKE '%|3|%' AND hide=0 AND deleted=0 AND alias=0 AND inalbum=0) AND ((effectivetime < 1220653959) AND (helyseg = 'budapest' AND eladokiado LIKE '%, kiado%' AND kiadoareuro '1 223'))

An error occoured at ccc.com/search.php?action=f...r&filled=1&whichtype=links on 2008-09-05 22:32:39. Please relay this data to support. Error #2: 'mysql_fetch_row(): supplied argument is not a valid MySQL result resource' in /home/ccc/public_html/cventura/databases/mysql.php on line 50. Debug info:
Count is

An error occoured at ccc.com/search.php?action=f...r&filled=1&whichtype=links on 2008-09-05 22:32:39. Please relay this data to support. Error #2: 'mysql_num_rows(): supplied argument is not a valid MySQL result resource' in /home/ccc/public_html/cventura/databases/mysql.php on line 47. Debug info:

Number of rows is You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''1 223'))' at line 1

Load time so far: 0.13 seconds.

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''1 223'))' at line 1

Query 11: SELECT COUNT(id) FROM wsnlinks_sessions WHERE memberid>0
Count is 1

Load time so far: 0.13 seconds.

Query 12: SELECT COUNT(id) FROM wsnlinks_sessions WHERE memberid=0 AND isrobot=0
Count is 0

Load time so far: 0.13 seconds.

Query 13: SELECT COUNT(id) FROM wsnlinks_sessions WHERE memberid=0 AND isrobot=1
Count is 1

Query 14: SELECT `id`,`memberid`,`location`,`time`,`ip`,`browser`,`starttime`,`catid`,`threadid`,`areaname`,`lastsearch`,`nopermission`,`inchat`,`name`,`isrobot`,`lastchat`,`groupnamestyle`,`acceptims`,`visibility`,`profileurl` FROM wsnlinks_sessions WHERE time > 1220653059 AND (memberid>0) ORDER BY time DESC LIMIT 0,100

Load time so far: 0.14 seconds.

Number of rows is 1

Creating online with Array as row

Query 15: SELECT `id`,`memberid`,`location`,`time`,`ip`,`browser`,`starttime`,`catid`,`threadid`,`areaname`,`lastsearch`,`nopermission`,`inchat`,`name`,`isrobot`,`lastchat`,`groupnamestyle`,`acceptims`,`visibility`,`profileurl` FROM wsnlinks_sessions WHERE memberid=1

Load time so far: 0.32 seconds.

Number of rows is 1

Creating online with Array as row

Load time so far: 0.32 seconds.

Query 16: UPDATE wsnlinks_sessions SET starttime = '1220653410', name = 'daa@gmail.com', time = '1220653959', location = 'http://cccc.com/search.php?action=filter&&whichtype=links', catid = '', threadid = '', areaname = 'Search Results for {SEARCHTERM}', nopermission = '0', inchat = '0', ip = 'xxx.xxx.29.241' WHERE id=20
Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7867
Paul
Posted Sep 06, 2008 - 2:39 AM:

Probably a template issue, tested between searches in the default template and they work, changed to
<br />and the number of comments
<select name="numcommentscondition">
<option value="between">is between</option>
</select>
<input type="text" name="numcommentssearch" size="5" /> and <input type="text" name="numcommentssearchmax" size="5" />

and it still works.
david
Forum Regular

Usergroup: Customer
Joined: Jun 22, 2005

Total Topics: 91
Total Comments: 305
david
Posted Sep 06, 2008 - 2:49 AM:

This is all I have in a template, with no wrappers of any kind:


<form action="search.php?action=filter&filled=1&whichtype=links" method="post" name="searchadvanced">
<input type="text" class="bordered" name="arsearch"/>
<input type="text" class="bordered" name="arsearchmax"/>
<input type="hidden" name="arsearchcondition" value="between" />
<input type="submit" value="Search" class="button" />
</form>


and produces this:

Query 3: SELECT `name`,`value` FROM wsnlinks_switches

Load time so far: 0.05 seconds.

Query 4: SELECT `id`,`title`,`caneditown`,`caneditall`,`canvote`,`isadmin`,`canpost`,`canemail`,`validatecats`,`validatecomments`,`validatelinks`,`validateedits`,`cansubmitlinks`,`cansubmitcategories`,`cansubmitcomments`,`caneditownlinks`,`caneditowncategories`,`caneditowncomments`,`caneditownprofile`,`caneditalllinks`,`caneditallcategories`,`caneditallcomments`,`caneditallprofiles`,`candownloadfiles`,`canupload`,`canviewip`,`limitlinks`,`canemailmembers`,`canusehtml`,`limitlinksdaily`,`canalias`,`cancopy`,`candeleteown`,`candeleteall`,`candofulledit`,`candeletecategories`,`candeletecomments`,`candeleteowncategories`,`candeleteowncomments`,`candeletemembers`,`candeleteownmembers`,`canaliascategories`,`canviewpages`,`caneditvotes`,`numaliases`,`canviewvotes`,`canhideownlinks`,`canhideowncategories`,`canhideowncomments`,`canhidealllinks`,`canhideallcategories`,`canhideallcomments`,`canratecomments`,`bytespermem`,`canpm`,`canim`,`canharddelete`,`limitpms`,`limitpmsdaily`,`canviewdeleted`,`cansubmitpolls`,`candeletepolls`,`candeleteownpolls`,`caneditpolls`,`caneditownpolls`,`attachperpost`,`attachperpm`,`canviewshouts`,`caneditshouts`,`caneditownshouts`,`candeleteshouts`,`candeleteownshouts`,`cansubmitshouts`,`canpollvote`,`customtitle`,`canviewinvisible`,`namestyle`,`canpmimportant`,`canviewmodlog`,`isleader`,`cansubmitquotes`,`validatequotes`,`candeletequotes`,`candeleteownquotes`,`canreport`,`canusesearch`,`attachperlink`,`validateattachments`,`caneditownquotes`,`caneditallquotes`,`canviewchat`,`caneditownevents`,`caneditallevents`,`candeleteownevents`,`candeleteevents`,`cansubmitevents`,`validateevents`,`bulkpms`,`issupermod`,`numinv`,`allowugspec`,`validateemails`,`validatesponsorlinks`,`cansubmittags`,`candeletetags`,`cansubmitfeeds`,`validatefeeds`,`validatefeeditems`,`numaliasestot`,`shoutsperday`,`validatetrader`,`renewdays`,`renewtimes`,`canviewownfulltrc`,`canviewallfulltrc` FROM wsnlinks_membergroups

Load time so far: 0.06 seconds.

Query 5: SELECT `id`,`name`,`links`,`comments`,`time`,`usergroup`,`password`,`ip`,`totalhits`,`totalhitsin`,`email`,`validated`,`template`,`language`,`lastattempt`,`allowemail`,`signature`,`avatarname`,`stylesheet`,`allowuseremail`,`albumid`,`failedattempts`,`totalbytes`,`funds`,`notifyoflinks`,`lastvisit`,`timezone`,`rating`,`pmfolders`,`notifyofpms`,`acceptpms`,`cookieduration`,`banned`,`location`,`homepage`,`occupation`,`bio`,`aim`,`icq`,`msn`,`yahoo`,`inactive`,`timeonline`,`totalpms`,`buddies`,`ignored`,`isonline`,`acceptims`,`adminpermissions`,`referrer`,`groupreverttime`,`grouprevertto`,`moderationpm`,`secondarygroups`,`linksperpage`,`commentsperpage`,`shouts`,`customtitle`,`shoutban`,`topicbans`,`forumbans`,`visibility`,`birthdate`,`lastsession`,`interests`,`posteditor`,`forumaccess`,`pmpopup`,`pmnotify`,`modnotes`,`guestnotes`,`salt`,`lastmodnote`,`newpms`,`imflag`,`orderalbums`,`lastguestnote`,`autosubscribe`,`notifymethod`,`showavatars`,`showsigs`,`warninglevel`,`topics`,`posts`,`chatcolor`,`traderrating`,`invitessent`,`validatedemail`,`calsub`,`macros`,`guestnotify`,`keychecktime`,`notifykeywords`,`autosubscribepost`,`blogrss`,`positivepct`,`notifytrader`,`minar`,`maxar`,`varos`,`epitoanyag`,`minalapterulet`,`maxalapterulet`,`minszobaszam`,`maxszobaszam`,`minfelszobaszam`,`maxfelszobaszam`,`erkely`,`futes`,`kilatas`,`tajolas`,`komfort`,`lift`,`minemeleten`,`maxemeleten`,`parkolas`,`lakasallapot`,`extrak`,`butorozott`,`minszintek`,`maxszintek`,`telefon`,`minkiadoar`,`maxkiadoar`,`megye`,`kerulet`,`eladokategoria`,`gepesitett`,`mintelek`,`maxtelek`,`inactiveemail`,`minkiadoareuro`,`maxkiadoareuro`,`kiadokategoria` FROM wsnlinks_members WHERE id = '1' AND validated = 1

Load time so far: 0.07 seconds.

Query 6: SELECT `id`,`to`,`subject`,`message`,`headers`,`replacement`,`mime` FROM wsnlinks_email WHERE timesent=0 AND inprogress=0 ORDER BY id ASC LIMIT 0,10

Load time so far: 0.08 seconds.

Number of rows is 0

Creating search with new as new

Query 7: INSERT INTO wsnlinks_searches(`id`,`value`,`memberid`,`catid`,`time`) VALUES('','2 33 between','1','','1220694317')

Query 8: SELECT `id` FROM wsnlinks_searches ORDER BY id DESC

Load time so far: 0.11 seconds.

Setting cookie with name testcookie, value 74 and expiration time 3441388633

Query 9: SELECT `id`,`title`,`url`,`description`,`rating`,`votes`,`validated`,`catid`,`sumofvotes`,`email`,`time`,`hits`,`numcomments`,`hide`,`ownerid`,`voterips`,`voterids`,`lastedit`,`type`,`notify`,`suspect`,`pendingedit`,`funds`,`suspended`,`alias`,`expire`,`ip`,`inalbum`,`typeorder`,`recipurl`,`hitsin`,`recipwith`,`hitsinips`,`hitsoutips`,`lastcomment`,`related`,`inhidden`,`viewers`,`threadviewers`,`hitsintemp`,`hitsouttemp`,`origtype`,`importance`,`parentids`,`timesdead`,`timesemailed`,`threadclosed`,`threadposters`,`lastposterid`,`lastpostername`,`ownername`,`deleted`,`deletionreason`,`movedto`,`deletedby`,`timevalidated`,`filefield`,`message`,`sticky`,`downloads`,`pollid`,`posticon`,`savedby`,`validatedemail`,`unpaid`,`recipverified`,`effectivetime`,`sugcatid`,`pagerank`,`wysihtml`,`movedid`,`unrevised`,`feedurl`,`feedcache`,`feedcachetime`,`tags`,`xmlsource`,`ordercomments`,`lastpadupdate`,`padfile`,`lastmonthlycheck`,`invisibleto`,`profileurl`,`lastprofileurl`,`timesrenewed`,`timedeleted`,`helyseg`,`ar`,`varos`,`epitoanyag`,`alapterulet`,`kertmeret`,`szobaszam`,`felszobaszam`,`erkely`,`futes`,`kilatas`,`tajolas`,`komfort`,`lift`,`emeleten`,`parkolas`,`lakasallapot`,`extrak`,`butorozott`,`szintek`,`kiadoar`,`helysegenglish`,`epitoanyagenglish`,`erkelyenglish`,`futesenglish`,`kilatasenglish`,`tajolasenglish`,`komfortenglish`,`liftenglish`,`parkolasenglish`,`lakasallapotenglish`,`extrakenglish`,`butorozottenglish`,`descriptionenglish`,`kerulet`,`megye`,`eladokiado`,`gepesitett`,`gepesitettenglish`,`cim`,`hazszam`,`adminnotes`,`telek`,`sponsorend`,`address`,`city`,`state`,`country`,`latitude`,`longitude`,`zip`,`kiadoareuro` FROM wsnlinks_links WHERE (validated=1 AND invisibleto NOT LIKE '%|3|%' AND hide=0 AND deleted=0 AND alias=0 AND inalbum=0) AND ((effectivetime < 1220694317) AND (ar '2 33')) ORDER BY typeorder ASC,time DESC LIMIT 0,60

Load time so far: 0.12 seconds.

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''2 33')) ORDER BY typeorder ASC,time DESC LIMIT 0,60' at line 1

Load time so far: 0.12 seconds.

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''2 33')) ORDER BY typeorder ASC,time DESC LIMIT 0,60' at line 1

Query 10: SELECT COUNT(id) FROM wsnlinks_links WHERE (validated=1 AND invisibleto NOT LIKE '%|3|%' AND hide=0 AND deleted=0 AND alias=0 AND inalbum=0) AND ((effectivetime < 1220694317) AND (ar '2 33'))

An error occoured at cccc.com/search.php?action=...r&filled=1&whichtype=links on 2008-09-06 09:45:17. Please relay this data to support. Error #2: 'mysql_fetch_row(): supplied argument is not a valid MySQL result resource' in /home/ccc/public_html/cventura/databases/mysql.php on line 50. Debug info:
Count is

An error occoured at cccc.com/search.php?action=...r&filled=1&whichtype=links on 2008-09-06 09:45:17. Please relay this data to support. Error #2: 'mysql_num_rows(): supplied argument is not a valid MySQL result resource' in /home/ccc/public_html/cventura/databases/mysql.php on line 47. Debug info:

Number of rows is You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''2 33'))' at line 1

Load time so far: 0.16 seconds.

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''2 33'))' at line 1

Query 11: SELECT COUNT(id) FROM wsnlinks_sessions WHERE memberid>0
Count is 1

Load time so far: 0.16 seconds.

Query 12: SELECT COUNT(id) FROM wsnlinks_sessions WHERE memberid=0 AND isrobot=0
Count is 0

Load time so far: 0.16 seconds.

Query 13: SELECT COUNT(id) FROM wsnlinks_sessions WHERE memberid=0 AND isrobot=1
Count is 1

Query 14: SELECT `id`,`memberid`,`location`,`time`,`ip`,`browser`,`starttime`,`catid`,`threadid`,`areaname`,`lastsearch`,`nopermission`,`inchat`,`name`,`isrobot`,`lastchat`,`groupnamestyle`,`acceptims`,`visibility`,`profileurl` FROM wsnlinks_sessions WHERE time > 1220693417 AND (memberid>0) ORDER BY time DESC LIMIT 0,100

Load time so far: 0.2 seconds.

Number of rows is 1

Creating online with Array as row

Query 15: SELECT `id`,`memberid`,`location`,`time`,`ip`,`browser`,`starttime`,`catid`,`threadid`,`areaname`,`lastsearch`,`nopermission`,`inchat`,`name`,`isrobot`,`lastchat`,`groupnamestyle`,`acceptims`,`visibility`,`profileurl` FROM wsnlinks_sessions WHERE memberid=1

Load time so far: 0.47 seconds.

Number of rows is 1

Creating online with Array as row

Load time so far: 0.47 seconds.

Query 16: UPDATE wsnlinks_sessions SET starttime = '1220687660', name = 'c@gmail.com', time = '1220694317', location = 'http://cccc.com/search.php?action=filter&&whichtype=links', catid = '', threadid = '', areaname = 'Search Results for {SEARCHTERM}', nopermission = '0', inchat = '0', ip = 'xx.99.29.241' WHERE id=26


I remember that WSN 4.x produced a between search query with a single number (the value of the '...search' field from the form, and not something like this:

AND ((effectivetime < 1220694317) AND (ar '2 33'))

See how it was searching for a number in the 'ar' link field, that has a value of '2 33'. it cannot find such a thing, since that would mean looking for a number with a space in it... or am I wrong in that assumption?

Thanks
David
david
Forum Regular

Usergroup: Customer
Joined: Jun 22, 2005

Total Topics: 91
Total Comments: 305
david
Posted Sep 06, 2008 - 5:13 AM:

DAMN! I put "arsearchcondition" instead of "arcondition".... smiling face
My bad.
Search thread for
Download thread as
  • 0/5
  • 1
  • 2
  • 3
  • 4
  • 5



Sorry, you don't have permission to post posts. Log in, or register if you haven't yet.