Date validation - check that a a date in a field is within a date range


Your XML is not well formed, and does not comply with the Rules
schema. Check it and try again. It returned the message: Line : -1 -
cvc-complex-type.2.3: Element 'RuleDef' cannot have character [children],
because the type's content type is element-only.

I get the above error message when I try to import the rule in the attachment. I can't figure out what is wrong in the cryptic message!





Comments

  • ebsebs Posts: 112 ✭✭
    Extra " in the Expression item?

    <Expression>I_STREE_SSA_START lt 2010-08-01 or gt "2015-02-01</Expression>
  • lkeitalkeita Posts: 43
    Three things I noticed: 
    • There is a closing tag > prior to Name in your RuleDef - that should be removed (it belongs at the end of that line). 
    • There is a random open quote in your expression (prior to the second date listed).
    • F_STREET1 is missing in the Target path. 
    Hopefully this helps!
  • kristiakkristiak Posts: 1,249 ✭✭✭

    Sharp Eyes, but it still give the same cryptic eror message:



    Your XML is not well formed, and does not comply with the Rules
    schema. Check it and try again. It returned the message: Line : -1 -
    cvc-complex-type.2.3: Element 'RuleDef' cannot have character [children],
    because the type's content type is element-only.

  • lkeitalkeita Posts: 43
    Please attach the updated Rule and I'll take another look.
  • agoodwinagoodwin Posts: 131 admin
    via Email
    You may also try

    I_STREE_SSA_START lt 2010-08-01 or I_STREE_SSA_START gt 2015-02-01

    On Tue, Apr 7, 2015 at 10:27 AM, lkeita
    wrote:

    > Please attach the updated Rule and I'll take another look.
    >
    > --
    > To manage your email notifications, please visit:
    > https://www.openclinica.com/forums#/profile/preferences
    >
    > Reply to this email directly or follow the link below to check it out:
    > https://forums.openclinica.com/discussion/comment/16761#Comment_16761
    >
    >
  • kristiakkristiak Posts: 1,249 ✭✭✭

    We are getting closer. Now the error message is as below.. This is simply "greek" to a Clinical Pharmacologist like me!

    I attach the modified rule.

    Invalid Rule Assignments









    Target Rules Errors
    F_STREET1.SE_STREET.IG_STREE_UNGROUPED.I_STREE_SSA_START









    Rule OID Action Message Info

    OCRERR_0033 : CRF is
    Invalid.




  • tkhajatkhaja Posts: 54
    Update your target to as follows

    SE_STREET.F_STREET1.IG_STREE_UNGROUPED.I_STREE_SSA_START

    Best,
    Thasbiha

  • agoodwinagoodwin Posts: 131 admin
    via Email
    Hi Krister,

    I don't see the full attached rule. Typically when you get an error of
    "invalid rule assignment" it means that either the rule def did not load
    and therefor is not able to be referenced or your RuleDef OID does not
    match the RuleRef OID.

    I just noticed this path, too:
    F_STREET1.SE_STREET.IG_STREE_UNGROUPED.I_STREE_SSA_START


    That would not be valid as the heirarchy is supposed to be
    Study Event > CRF > Item Group > Item

    In the above you have CRF > Study Event > Item Group > Item

    Perhaps this would work:
    SE_STREET.F_STREET1.IG_STREE_UNGROUPED.I_STREE_SSA_START



    On Tue, Apr 7, 2015 at 11:35 AM, kristiak
    wrote:

    > We are getting closer. Now the error message is as below.. This is simply
    > "greek" to a Clinical Pharmacologist like me!
    >
    > I attach the modified rule.
    >
    >
    > Invalid Rule Assignments
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    > Target
    > Rules
    > Errors
    >
    > F_STREET1.SE_STREET.IG_STREE_UNGROUPED.I_STREE_SSA_START
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    > Rule OID
    > Action Message
    > Info
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    >
    > OCRERR_0033 : CRF is
    > Invalid.
    >
    > --
    > To manage your email notifications, please visit:
    > https://www.openclinica.com/forums#/profile/preferences
    >
    > Reply to this email directly or follow the link below to check it out:
    > http://forums.openclinica.com/discussion/comment/16763#Comment_16763
    >
    >
  • kristiakkristiak Posts: 1,249 ✭✭✭

    Thanks ever so much all of you that helped out. Now it works. You simply get blind when you sit a whole day with a problem like this-


    Again thanks, specially to .Thasbiha and Alicia

    Regards

    Krister


  • agoodwinagoodwin Posts: 131 admin
    via Email
    No Problem. In future, if you use the Rule Designer and go to "View by
    Event", select and drag-and-drop the item you want, it should build the
    full path ( Study Event > CRF > Item Group > Item)


    On Tue, Apr 7, 2015 at 12:08 PM, kristiak
    wrote:

    > Thanks ever so much all of you that helped out. Now it works. You simply
    > get blind when you sit a whole day with a problem like this-
    >
    >
    >
    >
    > Again thanks, specially to .Thasbiha and Alicia
    >
    > Regards
    >
    > Krister
    >
    > --
    > To manage your email notifications, please visit:
    > https://www.openclinica.com/forums#/profile/preferences
    >
    > Reply to this email directly or follow the link below to check it out:
    > http://forums.openclinica.com/discussion/comment/16766#Comment_16766
    >
    >
This discussion has been closed.