Load dynamic data from SQL

  • 27 November 2017
  • 3 replies
  • 11 views

Badge +8

We have a simple checklist form which a user needs to answer questions.

The questions are in SQL

What is the best way to load data from a sql table into a view, and then be able to make a selection of Yes or No to answer the question?

 

Cheers


3 replies

Badge +7

I think what you are asking is how to display the questions for several different people and allow them to answer the questions while also tracking there answers. If this is correct  a simple way is this.

 

You need two tables and associated smartobjects

table1 - has your questions, it needs 3 collums: ID (auto increment),Question, Answer (you wont use answer in this table but you need it to display)

Table2 has your answers it needs 5 collums: TransID (you will group all answers by this, so you need a way to create this), Personwhoanswers, question, answer

 

Create an editable list view from Table1 (dont allow new rows to be added).

In the answer collumn on the addedit row change it to a dropdown and populate it with valid answers like: YesNo, Make the Question a Datalabel.

 

Now edit the Save rule and instead of saving all items to table 1, save them to table 2.

 

Now Table2 has all the records for each person who answered the questions.

 

There are other ways to do this but this is probablable the sinplest.

Does this help?

Badge +8

will that editable list view still require a user to select the question to answer (select the row) before they can answer it? 

or will it be posssible to simply go through the list and answer each question

 

 

Badge +7

Yes but to make it much easier you can do it with just one click so if they click on the answer it will be easier. Just look at the rules fro double click and make the single click rules the same. Disable the double click rule.

 

I hope this helps.

Reply