Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » zMUD General Discussion
Maximus
Wanderer


Joined: 21 May 2001
Posts: 59
Location: USA

PostPosted: Thu Mar 13, 2003 2:34 am   

Expanding a variable in a trigger pattern
 
I have a database, and each record has a field called Success. What I want to be able to do is make a trigger based on the contents of that field.

While looping through records, I have:

#TRIGGER {&Success} {[whatever]}

Obviously, the above doesn't have the desired effect. How can I create a trigger that expands the field before creating itself?

-Maximus
Reply with quote
Kjata
GURU


Joined: 10 Oct 2000
Posts: 4379
Location: USA

PostPosted: Thu Mar 13, 2003 3:43 am   
 
Whenever this field changes it must be because you change it by code. Why not include what you want to do along with the same code that changes the Success field?

Kjata
Reply with quote
Maximus
Wanderer


Joined: 21 May 2001
Posts: 59
Location: USA

PostPosted: Thu Mar 13, 2003 4:58 am   
 
I meant to say that the trigger is temporary. It is created without prior knowledge of what record is being called, and at any time. I'm not changing the Success field at all. But no worries, I figured it out.

#EXEC "#TEMP {"%rec.Success"} {[whatever]}"

Looks dirty, but it works perfectly.

-Maximus
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD General Discussion All times are GMT
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

© 2009 Zugg Software. Hosted by Wolfpaw.net