Search based on previous answer

Hi all,

We can reference the previous answer by ${'answer'} as a label to the
subsequent question.
If perhaps I have a CSV labelled as one of my answers, will it be able to
search (${'answer'})?

Hi Justice,

To be precise, the syntax is ${answer}. There are no quotes.

You can pull individual records from a CSV if you have a unique key
into that data. See http://xlsform.org/#how-to-pull-data-from-csv.

You can also search for those records, and yes, that search should
work for previous values.
https://opendatakit.org/help/form-design/data-preloading/

Yaw

··· On Sat, Feb 18, 2017 at 2:12 AM, Justice Danso Jr. wrote: > Hi all, > > We can reference the previous answer by ${'answer'} as a label to the > subsequent question. > If perhaps I have a CSV labelled as one of my answers, will it be able to > search (${'answer'})? > > -- > -- > Post: opendatakit@googlegroups.com > Unsubscribe: opendatakit+unsubscribe@googlegroups.com > Options: http://groups.google.com/group/opendatakit?hl=en > > --- > You received this message because you are subscribed to the Google Groups > "ODK Community" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to opendatakit+unsubscribe@googlegroups.com. > For more options, visit https://groups.google.com/d/optout.

Indeed, But it doesn't work..

error....
external data for ${answer} has not been imported. Perhaps you forgot to
include .....

But i have included all the files i need to the form

··· - - - - -

On Friday, 17 February 2017 18:12:50 UTC, Justice Danso Jr. wrote:

Hi all,

We can reference the previous answer by ${'answer'} as a label to the
subsequent question.
If perhaps I have a CSV labelled as one of my answers, will it be able to
search (${'answer'})?

Hi

you have to use the pull data function to retrieve data from your .CSV file
pulldata('mysheet','std_name','std_id',${answer})

mysheet: your .CSV file name
std_name: the value you want to pull from your .CSV file
std_id: the unique value in your .CSV file(primary key)
${answer}: the value sent to your .CSV file to search based on it

Regards

··· On Friday, February 17, 2017 at 8:12:50 PM UTC+2, Justice Danso Jr. wrote: > Hi all, > > > We can reference the previous answer by ${'answer'} as a label to the subsequent question. > If perhaps I have a CSV labelled as one of my answers, will it be able to search (${'answer'})?