3
$\begingroup$

I'm a web design teacher and I teach 9th graders (14 year olds) in the US.

Currently the 9th grade curriculum in my HS programme teaches students CSS, HTML and JavaScript. Students can create buttons, forms, navigation bars, and other fun things at the end of the course.

I was wondering - I want students to be able to get data from a database so they can inject data onto their websites.

Is there any easy to use database platform that would allow 9th graders to enter data easily (like Google Sheets), and pull data using client-side JS?

Even better would be that there already exists an API for getting queries so I don't have to teach SQL?

Just looking for ideas! Even instructions on how to build the service myself would be great.

$\endgroup$
6
  • $\begingroup$ This topic is covered, more or less in other questions with tag databases. $\endgroup$
    – Buffy
    Jul 8, 2018 at 17:45
  • $\begingroup$ Stackoverflow also covers this topic. Use tag database on that site, among other tags. $\endgroup$
    – Buffy
    Jul 8, 2018 at 17:53
  • $\begingroup$ A google search for [populate database] will turn up several links, including many at stack overflow. $\endgroup$
    – Buffy
    Jul 8, 2018 at 18:00
  • $\begingroup$ see also nosql. SQL is being used less and less. (I have been using couchdb, but not with students). $\endgroup$ Jul 10, 2018 at 23:22
  • 1
    $\begingroup$ The return to nosql is by no means a given in industry. There is a trade-off between the ease of support for SQL solutions and the raw speed of many nosql solutions. The reasons industry switched to SQL from ISAM, VSAM and other nosql solutions in the 1990's are still valid. $\endgroup$
    – pojo-guy
    Jul 17, 2018 at 3:14

4 Answers 4

2
$\begingroup$

Is there any easy to use database platform that would allow 9th graders to enter data easily (like Google Sheets), and pull data using client-side JS?

Given that you're thinking about Google Sheets as a data entry method, I understand that your goals don't extend to getting the students to implement server-side form handling. But in that case, why do you need a database? It seems to me that the requirements given can be met perfectly well by a hand-coded JSON file.

$\endgroup$
1
$\begingroup$

There are some websites that have free APIs. One is JSONPlaceholder, but you can easily request access to some others. For instance, Strava offers some for those interested in developing applications from running / swimming / biking data; all you need is an account, which can be made at no cost!

So in regards to the challenge at hand, you could use these online APIs in lieu of a database or a database platform. This would allow your students to learn about HTTP requests (or the like) and how these can be sent from and used by client-side JavaScript. But, perhaps more importantly, this confines the scope of the class to front-end technologies and methodologies, rather than delving too much into back-end techologies and databases, restricting this only to APIs.


Now, depending on your knowledge, if you have some web development experience or are willing to learn about it, I recommend using Node.js and setting up a localserver on your network, or perhaps on a hosting platform (e.g. Firebase, which I believe is free). From here, you can set up routes which handle HTTP requests, or the like, from which your students can send GET requests to. And since you would set up the routes and the data to be returned, you could tailor and personalize the data and the routes to the students (e.g. have a hypothetical endpoint <YOUR-FIREBASE-APP>.firebaseapp.com/Jeremy which would return info about your student Jeremy).

My opinion? As a student, I would not only be impressed by a teacher who could do something like this, but also personally intrigued as to how routing and servers work. But, hey, maybe that's just me :)

$\endgroup$
0
$\begingroup$
  1. Google sheets is not a database. I'd yank my kids from any class that pretended that so fast the friction would burn the tile floors
  2. Using client end JavaScript to talk directly to the database is poor design for many reasons.

Microsoft Access is about as clean a teaching tool as you can get for introducing databases. IT folk love to hate it, but it is the reason that nosql solutions were neglected for nearly two decades. In the hands of a pro, it tunes up much like DB2, and you can perform most functions without writing the SQL yourself.

If you're concerned about the bad habits that Access programmers develop, the big 3 (Oracle, DB2, and SQL server) have free versions available. Postgresql is open source and robust enough that it can compete head to head with the big 3. However, of you go this route you will have to teach SQL.

If you choose a "nosql" solution, you will have to teach the DSL for the nosql solution, which will not be less than the effort of teaching SQL.

My 7 year old son is learning Java from an online self study course (and as a java programmer I am watching what he's learning so I know it's good), so there is no reason a motivated 14 year old can't learn a server side framework, which will provide the correct decoupling and connectivity for a serious web spp. 14 year old programmers are regular contributors to the open source MMORPG game engines such as Trinity (World of Warcraft enulator), programming in C++, SQL, and Lua.

You might check out nodeJs if you don't want to get out of the JavaScript world.

$\endgroup$
-1
$\begingroup$

You can try to use browser storages to explain some concepts of storing and retrieving data: cookies, local storage, session storage or even WebSQL.

$\endgroup$
1
  • $\begingroup$ It is worth noting that WebSQL is deprecated and not supported properly in many major browsers; IndexedDB replaces it essentially. $\endgroup$
    – Aurora0001
    Jul 22, 2018 at 8:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.