Mysql – amazon dynamoDB or MySQL for storing large arrays inside each row

amazon-dynamodbamazon-rdsamazon-web-servicesMySQL

I am trying to decide which database I should use for an application I'm making. I was leaning toward dynamoDB because of its scalability, but then I read in the documentation which said:

there is a limit of 64 KB on the item size

although it looks like MySQL has a similar restriction documented here

This application will be storing a lot of data in two arrays, which could contain upwards of 10,000-100,000 strings in each. I estimate that these strings will each be somewhere around 20 characters long, so each element of the array will be around 40bytes and each array could be around 4MB.

Given this predicament, what database on amazon AWS would you use; or how would you get around the limit of size per row?

Best Answer

There is a hard limit of 4096 columns per table, but the effective maximum may be less for a given table. The exact limit depends on several interacting factors.

Every table (regardless of storage engine) has a maximum row size of 65,535 bytes. Storage engines may place additional constraints on this limit, reducing the effective maximum row size.

MySql 5.0 Manual

So either DBMS should allow you the same amount of data inside each row. Looks like neither will be sufficient for your needs or for your way to process data.

Anyway, you shouldn't store this much data in each row, you'd probably be better off storing each string separately and using other tables to reference them.

Related Topic