"It didn't work" is one of the most useless problem descriptions we get: unfortunately we get it a lot.
It tells us nothing about what you tried, how you tried it, what happened when you tried it, what you did to find out why, or what you need from us.
So in future, please show us code you tried and what exactly happened when you did...
But most times, when you try to store info in a DB and it doesn't work, it's because you are doing it wrong, and images normally show it as a problem when you try to fetch them from the db with a "Parameter not valid error" - other file types will give different errors, but for the same reasons.
So start here: Why do I get a "Parameter is not valid." exception when I read an image from my database?
] - it's image based, but it's applicable to any array of data you try to store.