We hope you'll join us for our 4/23 webinar on using data tables to apply reference ranges and AE codes in OC4. For more information and to register, visit https://register.gotowebinar.com/register/2882170018956684555

Rule with a repeating group

Hello all,
I use OpenClinca 3.0.3, I have a CRF that contains required item with a Yes/No question - "Does the Patient has COMORBIDITIE?" - followed by non required a repeating group which COMORBIDITIES?
I am trying to create a rule that validates that:
a) When "No" is selected then no records are added to the repeating group and save with no error massage show to end user.
b) When "Yes" is selected then at least one record, and when click save without any record an error massage show to end user.
The rule copied in belowis doing the job and upload successful , but with a problem it is not work when enter data , the form is saved and goes to the next section without any check .
Has anybody help me in this?

RuleImport>

SE_DEMOGRAPHIC.F_DEMOGRAPGIC_V1.IG_DEMOG_COMORBIDITIES_7153.I_DEMOG_COMORBID_CARDIOVASCULARDISE_8401


Please specify COMORBIDITIES.




If has COMORBIDITIES, then specify COMORBIDITIES
I_DEMOG_COMORBID_NONE_2412 eq 1 and I_DEMOG_COMORBID_CARDIOVASCULARDISE_8401 eq ""


Comments

  • maryam05maryam05 Posts: 89
    Hello all,
    I use OpenClinca 3.0.3, I have a CRF that contains required item with a Yes/No question - "Does the Patient has COMORBIDITIE?" - followed by non required a repeating group which COMORBIDITIES?
    I am trying to create a rule that validates that:
    a) When "No" is selected then no records are added to the repeating group and save with no error massage show to end user.
    b) When "Yes" is selected then at least one record, and when click save without any record an error massage show to end user.
    The rule copied in belowis doing the job and upload successful , but with a problem it is not work when enter data , the form is saved and goes to the next section without any check .
    Has anybody help me in this?

    RuleImport>

    SE_DEMOGRAPHIC.F_DEMOGRAPGIC_V1.IG_DEMOG_COMORBIDITIES_7153.I_DEMOG_COMORBID_CARDIOVASCULARDISE_8401


    Please specify COMORBIDITIES.




    If has COMORBIDITIES, then specify COMORBIDITIES
    I_DEMOG_COMORBID_NONE_2412 eq 1 and I_DEMOG_COMORBID_CARDIOVASCULARDISE_8401 eq ""


  • Dear Maryam,

    In my experience, you can check for the presence (but not absence) of a record in a repeating group:
    https://mailman.openclinica.com/pipermail/developers/2011-November/003296.html

    So you will only be able to detect when you have ‘No’ selected, and a record. You will not be able to detect when ‘Yes’ is selected, and there are no entries in the repeating group.

    If you allow a ‘blank’ entry in your comorbidity list (perhaps a field such as a comorbidity type that can be set to ‘(select)’), you could check that ‘Yes’ is selected and the first item in the list is ‘blank’.

    Yours,

    Michael
    Sent: 30 May 2012 07:14
    To: [email protected]; [email protected]
    Subject: [Developers] Rule with a repeating group

    Hello all,
    I use OpenClinca 3.0.3, I have a CRF that contains required item with a Yes/No question - "Does the Patient has COMORBIDITIE?" - followed by non required a repeating group which COMORBIDITIES?
    I am trying to create a rule that validates that:
    a) When "No" is selected then no records are added to the repeating group and save with no error massage show to end user.
    b) When "Yes" is selected then at least one record, and when click save without any record an error massage show to end user.
    The rule copied in belowis doing the job and upload successful , but with a problem it is not work when enter data , the form is saved and goes to the next section without any check .
    Has anybody help me in this?

    RuleImport>

    SE_DEMOGRAPHIC.F_DEMOGRAPGIC_V1.IG_DEMOG_COMORBIDITIES_7153.I_DEMOG_COMORBID_CARDIOVASCULARDISE_8401


    Please specify COMORBIDITIES.




    If has COMORBIDITIES, then specify COMORBIDITIES
    I_DEMOG_COMORBID_NONE_2412 eq 1 and I_DEMOG_COMORBID_CARDIOVASCULARDISE_8401 eq ""



    The University of Dundee is a registered Scottish Charity, No: SC015096
This discussion has been closed.