Allow export as CSV for all students

Allow export as CSV for all students

by Matthias Giger -
Number of replies: 3
Picture of Particularly helpful Moodlers

I've set up a database activity where students collect some data (not personal). What settings do I need to allow students to download the collected data as CSV file?

I thought the following setting would work.

Setting for export

But students still can't export the data because there is no export button.

What am I missing?

Is there a way to allow students downloading the data without giving them an assistant role? (This is problematic because new students will join the course during the year.)

Also, providing students with the already downloaded file is not a good option because the data is constantly updated.

Average of ratings: -
In reply to Matthias Giger

Re: Allow export as CSV for all students

by William Lu -
Picture of Particularly helpful Moodlers
The student role can't see the "Export" tab anyway.

However, they can see the "Export to portfolio" button, or the icon "+" (in some themes).

You must include the tag "##export##" in your templates.

Your permission settings (as in your screenshot) are correct and they are for the buttons, not for the Tab (the Tab is for Teacher's role only).

After the student clicked the button and they will be able to download a HTML file that has better look than the csv file.
In reply to William Lu

Re: Allow export as CSV for all students

by Matthias Giger -
Picture of Particularly helpful Moodlers
Thanks for the reply. That clarifies it.

As I need the CSV file (we collect data which we then use in a statistical programme), I've given students the assistant teacher rights for the database, which is not ideal but at least works as long as I don't forget to give that role to new students.
In reply to Matthias Giger

Re: Allow export as CSV for all students

by William Lu -
Picture of Particularly helpful Moodlers
Ok. You can twist the permission of the "non-editing" role in the course context if you worry about them have too many rights (and change the role's name).