Can someone see the data without being the creator or having it as a button unless it goes into something like an excel sheet?

Hello @kevmur,

does this program actually pertain to code.org? if we assume this is on there and is using Applab as the storage center I’d recommend just having the button alert you that the student is a frequent flyer than needing to see all the data at the given time however you can access the CDO data paths if that’s what your asking for

Using the CDO data API

you can use the /datablock_storage/:id/:method to interact with the CDO data even if the account isn’t yours

/*
            @routes
                @POST
                    * set_key_value
                        @desc
                            * sets a key to the corresponding value
                    * create_record
                        @desc
                            * creates a given record to the corresponding table
                    * create_table
                        @desc
                            * initalizies a given table name in the dataset
                    * add_column
                        @desc
                            * adds a column to a given table
                    * add_shared_table
                        @desc
                            * would add any shared tables in the given library manifest
                    * import_csv
                        @desc
                            * would import a csv datasheet into the dataset
                @PUT
                    * populate_key_values
                        @desc
                            * populates multiple keys within a given project
                    * populate_tables
                        @desc
                            * populates multiple tables within a given project
                    * update_record
                        @desc
                            * updates a given record in a table
                    * rename_column
                        @desc
                            * changes the given column name in a table
                    * coerce_column
                        @desc
                            * coerces a column of data to a <number>, <boolean>, or <string> type
                @GET
                    * get_key_value
                        @desc
                            * gets an established key from the database
                    * get_key_values
                        @desc
                            * gets all key values in the established database
                    * get_column
                        @desc
                            * gets a specific column specified in a given table
                    * get_columns_for_table
                        @desc
                            * gives all availible columns on a given table
                    * export_csv
                        @desc
                            * exports a given table to a csv file
                    * read_records
                        @desc
                            * gets all records/entries from a given table 
                    * get_table_names
                        @desc
                            * returns all availible table names on a given project
                    * get_library_manifest
                        @desc
                            * would return the inbuilt availible librarys that can be shared
                    * project_has_data
                        @desc
                            * checks to see if the project has any data
                @DELETE
                    * delete_key_value
                    * clear_table
                    * delete_record
                    * delete_column
                    * delete_table
                    * clear_all_data
*/

Note that you need an account signed in to interact with project data and that have not documented the paths with the necessary parameters to use so you will have to do a bit of research of your own if you want to use this route

However if you want to see the given data for any student without using this you may want to consider the further solutions i have provided below

View the Content within the App

you can try a much simpler approach something like this would do if you want to see it within the app

onEvent("userData_btn", "clicked", function() {
var records = readRecords("bathroomUsers" + Date().slice(0,15), function(v){
// parse data here
var text = "";
for(var i = 0; i < v.length; i++) {
var user = v[i];
text += user.name + ": " + user.used + "\n";
}
setText("users", text);
})
})

I don’t want the app to display it i just want to have the csv file

you are also able to export the data as a csv if you wish to keep a physical log outside of CDO since it does have limited space per project not sure exactly of what you want but this will also be included

You don’t have to be the owner of the project to export the tables off of CDO just make sure you have a CDO account so that you can properly interact with the storage API to do this it’d be easiest if you know the table you want within the project otherwise your going to have to run a check to see what table your trying to extract from the project. you will most likely have to test for get_table_names path as referenced with the earlier data API there is no parameters necessary besides the project id which is always required with the API


once you have located the table you want it’s time to export it from the project. To do this we are going to use this datablock path
https://studio.code.org/datablock_storage/:id/export_csv?table_name=:name
by doing this you should be able to view any table on CDO as an excel table

I know this is a lot but i hope one of these solutions helps

Varrience