Ruud Hermans Posted October 28, 2006 Share Posted October 28, 2006 I got the following table witch also needs to include a picture (foto) of a person but what do I put behind it? CREATE TABLE adressen(id VARCHAR(25) NOT NULL,voornaam VARCHAR(30) NULL,achternaam VARCHAR(30) NULL,volledige_naam VARCHAR(50) NULL,schuilnaam VARCHAR(30) NULL,geslacht ENUM('Man','Vrouw') NULL,adres VARCHAR(40) NULL,postcode VARCHAR(6) NULL,woonplaats VARCHAR(40) NULL,provincie VARCHAR(20) NULL,telefoon VARCHAR(12) NULL,email VARCHAR(20) NULL,info VARCHAR(255) NULLfoto) Ruud Hermans Link to comment Share on other sites More sharing options...
aspnetguy Posted October 30, 2006 Share Posted October 30, 2006 when dealing with pictures I only store the path to the file in my database, I use VARCHAR(255) NULL Link to comment Share on other sites More sharing options...
justsomeguy Posted October 30, 2006 Share Posted October 30, 2006 If you want to store the actual picture, you will use a blob or mediumblob datatype. You will also need to store the type so that when you get it out of the database you send the correct MIME type. Link to comment Share on other sites More sharing options...
Ruud Hermans Posted October 30, 2006 Author Share Posted October 30, 2006 Thanks both, I googled for "mysql blob" and got some good tuturials on how to store images in mysql.Ruud Hermans Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now