[
https://jira.jboss.org/jira/browse/JBRULES-1970?page=com.atlassian.jira.p...
]
Norbert Ziegler commented on JBRULES-1970:
------------------------------------------
Thanks for solving in CR1.
So two things to be mentioned:
a) if escaping the "#" in the right side (value) of the dsl-property solves my
problem than this is ok for me and saves time for doing some dirty workaround.
b) Need confirmation of your sentence "...The escaping is only required for the
grammar, obviously, and does not affect the way users write the sentences. .."
If I understand it right, than the user still can use # in the rule (dslr)-file without
escaping it?
This is essential for me and works now.
E.g. a line of my dslr:
Berechne #ENTG-ZUSBEI-ATZ-AN als Personenfeld ZvAtzVzBetr holen - Rechenfeld
#ENTG-ZUSBEI-ATZ-AG holen
wich is mapped to technical stuff by some dsl-properties as follows:
[*][]Rechenfeld {tmpname} holen = $p.getTempVal("{tmpname}")
[*][]Personenfeld {variablenname} holen = $p.get{variablenname}()
[consequence][]Berechne {variable} als {numerischerWert} =
$p.setTempVal("{variable}", {numerischerWert});
and the result today is (and should be after your change)
$p.setTempVal("#ENTG-ZUSBEI-ATZ-AN", $p.getZvAtzVzBetr() -
$p.getTempVal("#ENTG-ZUSBEI-ATZ-AG"));
Can you please confirm that b) still works?
As I just see CR1 is available now for download. I could swear yesterday it wasn't...
I'll try it.
Btw: one should change the "Released"-Column in your download-Page which still
points to 10th Dec. 2008 which is wrong / irritating since M5.
Thanks and kind regards,
Norbert
Error expanding DSL when #-Character is in right-side of
dsl-property
---------------------------------------------------------------------
Key: JBRULES-1970
URL:
https://jira.jboss.org/jira/browse/JBRULES-1970
Project: JBoss Drools
Issue Type: Bug
Security Level: Public(Everyone can see)
Components: drools-compiler
Affects Versions: 5.0.0.M5
Environment: Eclipse 3.4, jre6u10, WinXp
Reporter: Norbert Ziegler
Assignee: Edson Tirelli
Fix For: 5.0.0.CR1
Having a line in a DSL like following:
[condition][]Bedingung-19-MKM4 = eval ( $p.getTempVal("#UML-ATZ-1") <
$p.getZvUmlStfr() )
Using "Bedingung-19-MKM4" in the LHS of a rule "Regel-151" in an
dslr-File I get the following 3 errors:
[12] Unable to expand: Bedingung-19-MKM4
[ERR 103] Line 201:2 no viable alternative at input 'Bedingung' in rule
"Regel-151"
Unknown error while parsing. This is a bug. Please contact the Development team.
The problem is the #-Character. If you change the line to
[condition][]Bedingung-19-MKM4 = eval ( $p.getTempVal("UML-ATZ-1") <
$p.getZvUmlStfr() )
it works. But that's not what I need.
Hint: maybe this is related to (JBRULES-1960) Syntaxcoloring wrong if DSLR contains a
"#"-Character.
But in this case it's more important because it's not an "optical"
problem only.
By the way: if I use the value #UML-ATZ-1 as an argument / placeholder it works (thank
God, need this often). But using a placeholder is not what I need.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira