Demo Discussion
Forum Config Examples Contributions Vulnerabilities
  Discussion forum about ELOG, Page 354 of 807  Not logged in ELOG logo
icon5.gif   Problems with execute delete, posted by Stefan Kanitz on Tue Dec 23 11:02:26 2008 

Hi all,

i have problems with execute delete (execute new works fine) in following config (the attribute 'Counter' will not evaluated). Can anybody help me?

 

Here is the config:

 

Attributes = Counter, Autor, Adressat, Start, Ende, Mitteilung, TextBeachten

Show Attributes = Counter, Autor, Adressat, Start, Ende, Mitteilung, TextBeachten
Show Attributes Edit = Counter, Autor, Adressat, Start, Ende, Mitteilung, TextBeachten


Type Start = date
Type Ende = date
Required Attributes =  Autor, Adressat, Start, Ende, Mitteilung
Extendable options = Adressat
Preset Autor = $long_name
Preset Counter = SoMi-#####



Locked Attributes = Autor, Counter
Required Attributes =  Adressat, Start, Ende, Mitteilung

Options Adressat = Alle, 1. Semester, 2. Semester, 3. Semester, 4. Semester, 5. Semester, 6. Semester, 7. Semester, 8. Semester
MOptions Textbeachten = Bitte Mitteilungs-Text anzeigen lassen



Execute new = C:\xampp\mysql\bin\mysql.exe -h localhost -u root -p123456 -D screen -e "insert into somi (counter,adressat,start,ende,kumi,mitlami,lami) values ('$Counter', '$Adressat', '$Start', '$Ende', '$Mitteilung',  '$TextBeachten', '$text')"


Execute delete = C:\xampp\mysql\bin\mysql.exe -h localhost -u root -p123456 -D screen -e "delete from somi where counter='$Counter'"

 

 

 

Thanks in advance and Merry Christmas!!

 

Steve

 

    icon2.gif   Re: Problems with execute delete, posted by Stefan Kanitz on Tue Dec 23 12:17:06 2008 

Stefan Ritt wrote:

 

Stefan Kanitz wrote:

i have problems with execute delete (execute new works fine) in following config (the attribute 'Counter' will not evaluated). Can anybody help me?

 

Attribute substitution on 'execute delete' was not implemented, since I thought that the ELOG message ID would be used as the primary key in an SQL database, so one would not need the attributes. I added howver this functrionality in SVN revision 2159, so the next release will contain this fix. 

 This sounds very good! Thank you very much (Could you please add this functionality for execute edit too? Please :-))

Steve

 

    icon2.gif   Re: Problems with execute delete, posted by Stefan Kanitz on Tue Dec 23 12:31:39 2008 

Stefan Ritt wrote:

 

Stefan Kanitz wrote:

 

Stefan Ritt wrote:

 

Stefan Kanitz wrote:

i have problems with execute delete (execute new works fine) in following config (the attribute 'Counter' will not evaluated). Can anybody help me?

 

Attribute substitution on 'execute delete' was not implemented, since I thought that the ELOG message ID would be used as the primary key in an SQL database, so one would not need the attributes. I added howver this functrionality in SVN revision 2159, so the next release will contain this fix. 

 

This sounds very good! Thank you very much (Could you please add this functionality for execute edit too? Please :-))

 

For 'execute edit' this worked from the beginning. 

 Thank you!

icon5.gif   elogd hangs when Date format in elogd.cfg, posted by Stefan Kanitz on Thu Jan 8 14:42:34 2009 

Hi,

 

after setting

Date format = %Y-%m-%e

in elogd.cfg,

 

 

elogd hangs and must be restarted manually. Can anybody help me?

 

Thanks,

Steve

    icon2.gif   Re: elogd hangs when Date format in elogd.cfg, posted by Stefan Kanitz on Thu Jan 8 15:36:28 2009 

Stefan Kanitz wrote:

Hi,

 

after setting

Date format = %Y-%m-%e

in elogd.cfg,

 

 

elogd hangs and must be restarted manually. Can anybody help me?

 

Thanks,

Steve

 I found my mistake:It must be

Date format = %Y-%m-%d

 

Steve

 

icon5.gif   Multiple outcomes to a conditional attribute, posted by Sofian Jafar on Tue Jul 12 08:06:36 2016 

Hi,

First of all, thanks for all the great work, we all thank you here at SESAME synchrotron smiley

I am trying to set a conditional attribute where selecting one option in that attribute should trigger multiple outcomes as shown below:

Options Type = Fault{1_1&1_2}, Test{2_1&2_2}, Report{2_1&2_2}

{1_1} Options Fault Status = Open{a}, Fixed{b}
{2_1} Preset Fault Status = NA
{1_2} Preset Icon = attn.png
{2_2} Preset Icon = icon1.gif

I tries adding "&" as shown but that didn't work, my goal is to have 1_1 and 1_2 triggered whenever I select "Fault" as type, how can I do that?

Thanks in advance.

Cheers,

Sofian.

 

    icon2.gif   Re: Multiple outcomes to a conditional attribute, posted by Sofian Jafar on Tue Jul 12 09:15:35 2016 

Thanks Andreas,

Works great.

I tried reading the documentation on this but I was not able to deduce this solution.

Thanks a lot again.

Andreas Luedeke wrote:

Hi Sofian,

it should work like this:

Options Type = Fault{1}, Test{2}, Report{3}

{1} Options Fault Status = Open{a}, Fixed{b}
{2,3} Preset Fault Status = NA
{1} Preset Icon = attn.png
{2,3} Preset Icon = icon1.gif

It is described under "Multiple conditions" in the documentation (https://midas.psi.ch/elog/config.html#conditional).

Cheers and good luck!

Andreas

Sofian Jafar wrote:

Hi,

First of all, thanks for all the great work, we all thank you here at SESAME synchrotron smiley

I am trying to set a conditional attribute where selecting one option in that attribute should trigger multiple outcomes as shown below:

Options Type = Fault{1_1&1_2}, Test{2_1&2_2}, Report{2_1&2_2}

{1_1} Options Fault Status = Open{a}, Fixed{b}
{2_1} Preset Fault Status = NA
{1_2} Preset Icon = attn.png
{2_2} Preset Icon = icon1.gif

I tries adding "&" as shown but that didn't work, my goal is to have 1_1 and 1_2 triggered whenever I select "Fault" as type, how can I do that?

Thanks in advance.

Cheers,

Sofian.

 

 

 

    icon2.gif   Re: Multiple outcomes to a conditional attribute, posted by Sofian Jafar on Tue Jul 12 09:17:03 2016 

Thank you Stefan as well smiley

Stefan Ritt wrote:

What about this:

Options Type = Fault{1}, Test{2}, Report{3}

{1} Options Fault Status = Open{a}, Fixed{b}
{2,3} Preset Fault Status = NA
{1} Preset Icon = attn.png
{2,3} Preset Icon = icon1.gif

-Stefan

Sofian Jafar wrote:

Hi,

First of all, thanks for all the great work, we all thank you here at SESAME synchrotron smiley

I am trying to set a conditional attribute where selecting one option in that attribute should trigger multiple outcomes as shown below:

Options Type = Fault{1_1&1_2}, Test{2_1&2_2}, Report{2_1&2_2}

{1_1} Options Fault Status = Open{a}, Fixed{b}
{2_1} Preset Fault Status = NA
{1_2} Preset Icon = attn.png
{2_2} Preset Icon = icon1.gif

I tries adding "&" as shown but that didn't work, my goal is to have 1_1 and 1_2 triggered whenever I select "Fault" as type, how can I do that?

Thanks in advance.

Cheers,

Sofian.

 

 

 

ELOG V3.1.5-3fb85fa6