My Database project

Idea of the project

In this consumer society, a lot of people want to be careful what they eat. That's way more and more people try to count their calories per day, to respect the standard limit. According to the 2015-2020 Dietary Guidelines for Americans, women are likely to need between 1,600 and 2,400 calories a day, and men from 2,000 to 3,000. However, this depends on their age, size, height, lifestyle, overall health, and activity level. Moreover, a lot of people want to lose weight and so they reduce thei daily caloric intake. But the problem is: we don't know the number of calories in each ingredient or dish. And so people can't measure if they eat more or less calories each day.

Nowadays, many apps do exist to count calories. But they're not always accurate, and they don't always give the calories for mixed dishes.

How can databases increase the accuracy of calorie counter applications ?

The idea is that when people enter a dish, the application gives the number of calories corresponding to this dish. The database will be very extensive. Data could be add for every new dish. Through the use of databases, people who wants to count calories will get an acces to a Firebase Realtime Database allowing them to consult, create, modify or delete datas.

How to code it

For example, if we want to know the number of calories for a meal consisting of: 100g of rice, 50cl of beer and 200g of minced steak.

What is a database ?

A database refers to a set of related data and the way it is organized. Access to this data is usually provided by a database management system (DBMS), a software that allows users to interact with one or more databases and provides access to all of the data contained in the database (although restrictions may exist that limit access to particular data). The DBMS provides various functions that allow definition, creation, update and query of large quantities of information and provides ways to manage how that information is organized. (See CRUD for more details).

Database designers typically organize the data to model aspects of reality in a way that supports processes requiring information, such as (for example) modelling the availability of rooms in hotels in a way that supports finding a hotel with vacancies.

Computer scientists may classify database-management systems according to the database models that they support. Relational databases became dominant in the 1980s. These model as rows and columns in a series of tables, and the vast majority use SQL (Structured Query Language) for writing and querying data.

Relational DBs can be thought of as spreadsheets, but we’ve seen that we’re more and more confronted to data that need more complex structure. Therefore, since the 2000s, non-relational database became more popular, referred to as NoSQL because they use different query languages.