Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / New
Stats: 3,152,795 members, 7,817,293 topics. Date: Saturday, 04 May 2024 at 09:45 AM

What Mysql Select Type Can I Use For Picture/audio/video - Programming - Nairaland

Nairaland Forum / Science/Technology / Programming / What Mysql Select Type Can I Use For Picture/audio/video (2170 Views)

What Platform Do You Use For Web Development / What Development Chain Do You Use For C++? / Database For Picture Storage (2) (3) (4)

(1) (Reply) (Go Down)

What Mysql Select Type Can I Use For Picture/audio/video by adamuabu: 3:40am On Mar 12, 2013
I am having challenges creating a database in phpmyadmin which I need to fetch information from a registration form to include picture upload, select menu and text area datas. What is the best approach to go about it.
Re: What Mysql Select Type Can I Use For Picture/audio/video by Javanian: 6:02am On Mar 12, 2013
Use a blob, medium blob or long blob. Do some research to know which suits what you are doing. But you are better of saving the images to a directory and then saving the directory path(link/url) in your database
Re: What Mysql Select Type Can I Use For Picture/audio/video by Nobody: 3:12pm On Mar 13, 2013
Javanian: Use a blob, medium blob or long blob. Do some research to know which suits what you are doing. But you are better of saving the images to a directory and then saving the directory path(link/url) in your database

Exactly. That's what I did for my site in the signature...
Re: What Mysql Select Type Can I Use For Picture/audio/video by kodewrita(m): 5:20pm On Mar 14, 2013
dont store your files in the database directly.
Best practice nowadays is to store it in your directory, rename it to a meaningful name and then store that filename in your database as a varchar field.

a 100 character length varchar field should be enough if your naming rules are smart e.g userid_6letterformname_6digitdate.jpg like 00898_schreg_140313.jpg.

All the best.
Re: What Mysql Select Type Can I Use For Picture/audio/video by codeninja(m): 5:25pm On Mar 14, 2013
Storing images directly into databases isnt a good idea.
It makes your db unecessarily too large, causes a deal of bottleneck in both READ and WRITE activities
Re: What Mysql Select Type Can I Use For Picture/audio/video by Nobody: 11:02am On Mar 15, 2013
blob will be it, but it's always a bad idea to store the actual binary data in the database.
store the reference and save the data in a folder.
Re: What Mysql Select Type Can I Use For Picture/audio/video by adamuabu: 4:22pm On Mar 15, 2013
Thanks everyone.

(1) (Reply)

MATLAB Programming Assignment Help - 15k / Synchronize Tow Mysql Databases (remote And Local) / BB OSv10 Ships With Qt C++ Libraries

(Go Up)

Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health
religion celebs tv-movies music-radio literature webmasters programming techmarket

Links: (1) (2) (3) (4) (5) (6) (7) (8) (9) (10)

Nairaland - Copyright © 2005 - 2024 Oluwaseun Osewa. All rights reserved. See How To Advertise. 10
Disclaimer: Every Nairaland member is solely responsible for anything that he/she posts or uploads on Nairaland.