Error Creating a Record

I’m playing with files and I have an error when creating a record.

My Project: https://studio.code.org/projects/applab/XUdEnQAvUwtxyNpU61ssbj1rkypewIi1h2b6iwOH8qI/edit
My error:

Can anyone help? or point me at some more comprehensive documentation on the createRecord function than you have on the site?

Thanks! - Ellen

Did you look at this documentation?

https://docs.code.org/applab/updateRecord/

I did, but it wasn’t very comprehensive. My code was an attempt to mimic the example, and I need more detailed information about the syntax in order to correct the error.

So…I am absolutely NOT an expert, but this “worked”. I added an additional var on line 3: mostRecentId=1, and two lines to getScrData (now line 80 infractionData.id=mostRecentId; and mostRecentId ++).

I think that you have to explicitly give your record an id field and I think that you need to update the value of mostRecentId so that you aren’t saving all records to the same place. That said, I strongly suspect that mostRecentId++ is the wrong choice–I feel like this won’t put all of a single student’s info into the same searchable location?

This gave me a bunch of errors.

@esatter1 - The code.org folks took a preliminary look and the app appears to working correctly. They may need access to your data set to help debug this. They ask that you send email to support@code.org with as much info as possible so they can start a dialog with you to debug this privately.

thanks! I will! ________

Hey, can you tell me how they fixed your error? I’m getting this error: “WARNING: Line: 116: Error: permission_denied at /v3/config/channels: Client doesn’t have permission to access the desired data.”
The sample lessons work fine for me but I can’t get it to work inside the program i’m writing.

In the end I gave up. There was a bit of email back and forth after I sent them my code, and I think basically code studio wasn’t up to the task.

Is the string you’re submitting a JSON object?