Re: DBD::mysql::st execute failed: You have an error in your SQL syntax near ')
"tony_bierman" <[email protected]> Thu, 17 Apr 2003 23:28:46 -0000
| Newsgroups | gmane.network.ubh |
|---|---|
| Message-ID | <[email protected]> |
Gerald, Well, you put me on the right track. The 'active' column for my 'servers' entry was not set to TRUE. However, after making that adjustment, I only get this output: [biermana@localhost stable3]$ ./ubh ------------------------------------------------------------------------------ ubh 3.0b1, (C) 2000-2003 Gerard Lanois This software comes with ABSOLUTELY NO WARRANTY; for details use -w. This is free software, and you are welcome to redistribute it under certain conditions; see the file LICENSE for details. ------------------------------------------------------------------------------ 2003/04/17 17:27:24 Ubh.NNTP INFO> Connecting to news.machlink.com:119 2003/04/17 17:27:24 Ubh.NNTP INFO> Successfully connected. 2003/04/17 17:27:24 Ubh.NNTP INFO> Authenticating as 2003/04/17 17:27:24 Ubh.NNTP INFO> Successfully authenticated. 2003/04/17 17:27:24 ubh.process_servers INFO> Constructing list of groups to process. 2003/04/17 17:27:24 ubh.process_servers INFO> Begin processing groups. 2003/04/17 17:27:24 ubh.process_group INFO> Begin processing group alt.binaries.movies 2003/04/17 17:27:25 ubh.process_group INFO> Begin processing single part articles. SQL> SELECT h.msgid, h.subject, h.category FROM headers h, xref_headers x WHERE h.header_id = x.header_id AND x.newsgroup_id = 2 AND x.server_id IN (6) AND h.category = 'SINGLE' AND h.status = 'UNREAD' GROUP by h.header_id ORDER BY h.subject 2003/04/17 17:27:25 ubh.process_group INFO> Begin processing multipart articles. 2003/04/17 17:27:25 ubh.process_group INFO> STATS: news.machlink.com total bytes = 0 secs = 0 rate = 0.000 KB/sec 2003/04/17 17:27:25 ubh.process_group INFO> Finished processing group alt.binaries.movies 2003/04/17 17:27:25 ubh.process_servers INFO> Finished processing groups. 2003/04/17 17:27:25 Ubh.NNTP INFO> Disconnecting from news.machlink.com:119 By the way here's my .ubhrc file. NNTPSERVER = news.machlink.com NEWSRCNAME = .newsrc DATADIR = data MULTI_EXT = (?i)asf|avi|gif|jpg|mov|mpg|rm|r??|R??|p??|P?? SINGLE_EXT = (?i)asf|avi|gif|jpg|mov|mpg|rm|r??|R??|p??|P?? # ACCOUNT = # PASSWORD = Thanks again, Tony --- In [email protected], Gerard Lanois <gerardlanois@y...> wrote: > This makes me think that no server connections have > been opened. > > Did you set up the server table? In other words, did you > customize the contents of the 2_servers.sql file prior to > running the installer script? > > Here is an SQL procedure you can use to determine if there > are any servers in your server table: > > USE ubhcache; > SELECT * FROM servers; > > > That should show you all the servers you are going to > connect to during a run. > > If that table is non-empty, then it is possible that > ubh was not able to connect to any of them at the beginning > of the run. Were there any error or warning messages about > this earlier in the run? > > Now that I look at the code, I see the connection logic > bails out with exit(-1) if a server connection cannot be > established. So, you would never get as far as you did > if a server connection could not be made. > > The thing to look for is a message in the log that > says "Sucessfully connected". You should see that for > each server in your server table. > > The more I think about it the more likely it is your > server table has nothing in it. > > If it does, let me know. > > > > Hope this helps. > > -Gerard > > > --- tony_bierman <biermana@h...> wrote: > > Here's the output: > > > > SQL> SELECT h.msgid, h.subject, h.category FROM headers h, > > xref_headers x WHERE > > h.header_id = x.header_id AND x.newsgroup_id = 2 AND x.server_id IN ) > > AND h.category = 'SINGLE' AND h.status = 'UNREAD' GROUP by h.header_id > > ORDER BY h.subject > > > > Thanks, > > Tony > > > > --- In [email protected], Gerard Lanois <gerardlanois@y...> wrote: > > > go into sub process_group > > > > > > right *before* where it says > > > > > > my $sth = $dbh->prepare($stmt); > > > $sth->execute; > > > > > > insert a print statment, so that it looks like this: > > > > > > print "SQL> $stmt\n"; > > > my $sth = $dbh->prepare($stmt); > > > $sth->execute; > > > > > > and tell me what it says > > > > > > this dumps out the complete SQL statement text prior to > > > executing it - it should help us understand how/why it > > > did not get put together correctly > > > > > > > > > > > > --- Tony Bierman <biermana@h...> wrote: > > > > Help?? > > > > > > > > [biermana@localhost stable3]$ ./ubh -g > > > > > > > > > > ------------------------------------------------------------------------------ > > > > ubh 3.0b1, (C) 2000-2003 Gerard Lanois > > > > This software comes with ABSOLUTELY NO WARRANTY; for details use -w. > > > > This is free software, and you are welcome to redistribute > > > > it under certain conditions; see the file LICENSE for details. > > > > > > > > > > ------------------------------------------------------------------------------ > > > > 2003/04/16 16:04:08 ubh.process_servers INFO> Constructing list of > > groups > > > > to > > > > process. > > > > 2003/04/16 16:04:08 ubh.process_servers INFO> Begin processing groups. > > > > 2003/04/16 16:04:08 ubh.process_group INFO> Begin processing group > > > > alt.binaries.movies > > > > 2003/04/16 16:04:08 ubh.process_group INFO> Begin processing > > single part > > > > articles. > > > > DBD::mysql::st execute failed: You have an error in your SQL > > syntax near ') > > > > > > > > AND > > > > h.category IN ('UNKNOWN','SINGLE') AND h.status = 'UNREAD' GROUP > > by h.head' > > > > > > > > at line 1 at ./ubh line 1752. > > > > DBD::mysql::st execute failed: You have an error in your SQL > > syntax near ') > > > > > > > > AND > > > > h.category IN ('UNKNOWN','SINGLE') AND h.status = 'UNREAD' GROUP > > by h.head' > > > > > > > > at line 1 at ./ubh line 1752. > > > > > > > > > > > > > > > > > > > > > > > > > > > > _________________________________________________________________ > > > > The new MSN 8: advanced junk mail protection and 2 months FREE* > > > > http://join.msn.com/?page=features/junkmail > > > > > > > > > > > > ------------------------ Yahoo! Groups Sponsor ---------------------~--> Get 128 Bit SSL Encryption! http://us.click.yahoo.com/W7NydA/hdqFAA/VygGAA/IHFolB/TM ---------------------------------------------------------------------~-> To unsubscribe from this group, send an email to: [email protected] Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/