Question on using SAIL to pull information from DB

Hi

I am working on version 16.1.

I have a scenario where I want to display names of fruits in my drop down on SAIL whose values I am getting from DB.
In DB there are four distinct fruit names i.e. Apple, Orange, Banana, Mango and I am fetching these values via. query rule on my SAIL interface itself.
The SAIL interface rule is:
                                                                      load(
                                                                                 local!fruit,
                                                                                 local!dropDownValues:union(rule!Get_FruitData().fruitname,rule!Get_FruitData().fruitname),
                                                                                 a!formLayout(
                                                                                          label:"Drop Down Test",
                                                                                          firstColumnContents:{
                                                                                           a!dropdownField(
                                                                                                    label:"Fruit Names",
                                                                                                    placeholderLabel:"Select a fruit",
                                                                                                    choiceLabels:local!dropDownValues,
                                                                                                    choiceValues:local!dropDownValues,
                                                                                                    value:ri!fruit,
                                                                                                    saveInto:{ri!fruit
                                                                                                    }
                                                                                           )
                                                                                          },
                                                                                          buttons:a!buttonLayout(
                                                                                           primaryButtons:{
                                                                                                    a!buttonWidgetSubmit(
                                                  ...

OriginalPostID-211459

OriginalPostID-211459

  Discussion posts and replies are publicly visible

Parents
  • @konalc - if you use saveinto local! - and if you click save changes it will not save the data on the form. If you are okay with this behaviour where save changes should not work then you can go ahead with saveInto local!. But if you are allowing users to save form changes using out of the box Save changes feature you have to make sure your data is stored in rule inputs and not in local variables.
Reply
  • @konalc - if you use saveinto local! - and if you click save changes it will not save the data on the form. If you are okay with this behaviour where save changes should not work then you can go ahead with saveInto local!. But if you are allowing users to save form changes using out of the box Save changes feature you have to make sure your data is stored in rule inputs and not in local variables.
Children
No Data