egghelp.org community Forum Index
[ egghelp.org home | forum home ]
egghelp.org community
Discussion of eggdrop bots, shell accounts and tcl scripts.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

[MySQL] Not doing anything with mysqltcl

 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Scripting Help
View previous topic :: View next topic  
Author Message
T-Xorcist
Halfop


Joined: 14 Nov 2005
Posts: 47
Location: Netherlands

PostPosted: Tue May 09, 2006 7:21 pm    Post subject: [MySQL] Not doing anything with mysqltcl Reply with quote

Hi all!

I just started to work with mysqltcl, but I can't find the error. I have the following code:

Code:
proc test {nick host hand chan arg} {
  package require mysqltcl
  set mysql(conn) [mysqlconnect -host localhost -user tbot -db tbot -password xxxxxxx]

  [b][u]set query "SELECT id FROM channels WHERE name = 'T-Xorcist'"
  set chanid [mysqlsel $mysql(conn) $query -list][/u][/b]

  mysqlclose $mysql(conn)
}


The wanabee bold/underlined lines are the problem! If I remove that line, it works.

What is wrong with this script? I am looking for 3 hours now Confused

Thanks in advance!
_________________
is-1337.org IRC server!
Back to top
View user's profile Send private message Visit poster's website
demond
Revered One


Joined: 12 Jun 2004
Posts: 3073
Location: San Francisco, CA

PostPosted: Wed May 10, 2006 1:11 am    Post subject: Re: [MySQL] Not doing anything with mysqltcl Reply with quote

T-Xorcist wrote:

What is wrong with this script? I am looking for 3 hours now Confused


the 'wanabee bold/underlined lines'?
_________________
connection, sharing, dcc problems? click <here>
before asking for scripting help, read <this>
use [code] tag when posting logs, code
Back to top
View user's profile Send private message Visit poster's website
T-Xorcist
Halfop


Joined: 14 Nov 2005
Posts: 47
Location: Netherlands

PostPosted: Wed May 10, 2006 9:23 am    Post subject: Reply with quote

Hm, my MySQL user / password wasn't correct :S

Which is very strange, because it is there. Oh wel, sorry for bothering you guys

1 more question: how can I remove all the channels at ones? like:
channel remove * ? Is that possible?
_________________
is-1337.org IRC server!
Back to top
View user's profile Send private message Visit poster's website
De Kus
Revered One


Joined: 15 Dec 2002
Posts: 1361
Location: Germany

PostPosted: Wed May 10, 2006 8:05 pm    Post subject: Reply with quote

T-Xorcist wrote:
1 more question: how can I remove all the channels at ones? like:
channel remove * ? Is that possible?

Try it. I am for sure NOT going to try it on my bot Very Happy.
_________________
De Kus
StarZ|De_Kus, De_Kus or DeKus on IRC
Copyright © 2005-2009 by De Kus - published under The MIT License
Love hurts, love strengthens...
Back to top
View user's profile Send private message MSN Messenger
T-Xorcist
Halfop


Joined: 14 Nov 2005
Posts: 47
Location: Netherlands

PostPosted: Thu May 11, 2006 2:36 am    Post subject: Reply with quote

But what is it? Razz Any ideas?
_________________
is-1337.org IRC server!
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Scripting Help All times are GMT - 4 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Forum hosting provided by Reverse.net

Powered by phpBB © 2001, 2005 phpBB Group
subGreen style by ktauber