Jump to content
  • Advertisement
WinterDragon

javascript - database

Recommended Posts

I'm learning javascript for game development.

One of my side projects is to build a database that I can enter images and data into, which can then output visual assets based on images and data into a pre-built video game environment.

thinking about building the database first, what could I use to program this? mysql?

anatomical database for creature creation sandbox - open source indie video game

Edited by WinterDragon

Share this post


Link to post
Share on other sites
Advertisement

So you use node.js? I think it has a binding to almost any database.
MySql is compatible to oracle. From everything I read, Postgres must be more nice if you do not need that feature.

Speaking of images I am thinking about using a filesystem for these. I read that MS SQL server can enforce relational consistency between these and data in tables. I think Postgres can too. Also all cloud vendors offer blob space. There must be a reason, why there are 3 types of storages, which refuse to die: Hierarchical , relational, schemaless. One basically needs all three in every larger project.

Right now I am far from earning money, but maybe others can clarify on this. It seems to me, that blob storage is cheapest. This pushes my design in an unhealthy direction where I put all data into one big XML file (blob) and process this in memory and in process of my webserver ...

Edited by arnero

Share this post


Link to post
Share on other sites

You can use SQL databases or NoSQL databases or just keep it on the server's File system.

If you use SQL databases (such as postgresql, mariadb, mysql, MSSQL, Oracle, etc), you may keep it as BLOB (Binary Large Object) inside the DB or you keep the path that point to image on filesystem. and you need to understand table relations and also SQL language.

If you use NoSQL (such as MongoDB, couchdb, cassandra, redis, etc), again you may keep it as BLOB or path to image. you need to understand JSON and the provided API from database engine that you use (i think there is no api standard for nosql yet)

If you use filesystem, you need to organize directory structure and filename (actually if you keep path in DB, you also need to organize it as well) 

IMHO, I will use filesystem for small project but for large project, I will use BLOB in SQL database because we can utilize database features for backup/restore, scaling, monitoring, kind of that, jobs 

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!