Jump to content
  • 0

Pulling values with a query to manipulate and display


jeffdillon
 Share

Question

Napoleon got me started in setting up a system to record judges' ratings of a variety of nominations in a contest -- every time a logged-in judge rates an entry accessed through a DataPage, it creates a new entry recording that rating in a table, recording the Building_ID, the Judge_ID and the Rating itself.

The challenge I've run into after that is how to tally the results of those votes -- that is, it's easy to display a full table for all of those ratings, but what I'd like to do is:

--Either sum or average the judges' votes per each unique Building_ID

--And, since we didn't prevent judges from voting multiple times, just pull the last vote (which may be too hard since it will be the last value matching the Judge_ID and Building_ID parameters in the table)

--And, if possible, display each judge's own rating of a submission to them while they looking through at the DataPage of entries, so they can see whether they've already rated something.

I can do the math and the display of the results for each building in JavaScript -- I just can't find a Caspio reference for setting up the query, such as \"show RATING where JUDGE_ID=1 and Building_ID=VeryTallBuilding (fieldname for this record)\".

Thanks for any suggestions.

Link to comment
Share on other sites

3 answers to this question

Recommended Posts

  • 0

To calculate the sum or avarage of those values, custom programming is needed. You need to contact us and we will give you our suggestions.

As I understood you nedd to display each judge's own rating of a submission to them, so you need to have a Predefined Search and Report DataPage inside an athenticated folder (Password protected for Judges) in which the Record Level Security is checked and \"matching identity field in user authentication\" is set to Judge_ID and \"identify field in datasource\" set to Judge_ID field coming from the table inwhich you are storing the Judge_ID, Building_ID, and votes.

Bahareh M.

Technical Support | Caspio Inc.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...