Re: help with PHP/SQL

2004-05-18 Thread Craig Sanders
On Thu, May 13, 2004 at 09:58:35PM -0400, ziada Mrisho wrote:
> I got your e-mail address from a forum thread on SQL Help. I desperately need
> help for my class project. I need to know how to insert an image in a
> database table. When I issue a CREATE table command, what attribute
> represents an image file? eg:
> 
> CREATE TABLE SClassTable (
>   ?image _? NOT NULL,
>   description VARCHAR (64) DEFAULT NULL,
>   reference INT (5) DEFAULT NULL,
>   price VARCHAR(15),
>   PRIMARY KEY (reference),
>   KEY (description)

it's not a good idea to store images in databases.  you're much better off
storing the image in the filesystem and using the database to store metadata
about the image, including description, title, copyright details, and
especially the path and/or URL to the image.

craig

-- 
craig sanders <[EMAIL PROTECTED]>

The next time you vote, remember that "Regime change begins at home"




Re: help with PHP/SQL

2004-05-18 Thread Craig Sanders
On Thu, May 13, 2004 at 09:58:35PM -0400, ziada Mrisho wrote:
> I got your e-mail address from a forum thread on SQL Help. I desperately need
> help for my class project. I need to know how to insert an image in a
> database table. When I issue a CREATE table command, what attribute
> represents an image file? eg:
> 
> CREATE TABLE SClassTable (
>   ?image _? NOT NULL,
>   description VARCHAR (64) DEFAULT NULL,
>   reference INT (5) DEFAULT NULL,
>   price VARCHAR(15),
>   PRIMARY KEY (reference),
>   KEY (description)

it's not a good idea to store images in databases.  you're much better off
storing the image in the filesystem and using the database to store metadata
about the image, including description, title, copyright details, and
especially the path and/or URL to the image.

craig

-- 
craig sanders <[EMAIL PROTECTED]>

The next time you vote, remember that "Regime change begins at home"


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



Re: (OT!) help with PHP/SQL

2004-05-14 Thread Andreas Vent-Schmidt
Hi,
first: your question is off-topic in this mailing list! Please move 
to a mailing list dealing with database (MySQL?) questions.

The correct data type for binary data (like an image is) in most 
cases will be the Binary Large OBject - "BLOB". But it may differ 
depending on your database engine. For finding out how to put the 
image into the database table, please use one of these PHP mailing 
list / phorums.

Best regards,
Andreas
table. When I issue a CREATE table command, what attribute represents 
an image file? eg:

CREATE TABLE SClassTable (
  ?image _? NOT NULL,
--
procommerz - Internet fuer Unternehmen
http://www.procommerz.de | 033925-90710
Stoppt TCPA, das Zensursystem von Microsoft! | http://www.againsttcpa.com



Re: (OT!) help with PHP/SQL

2004-05-14 Thread Andreas Vent-Schmidt
Hi,

first: your question is off-topic in this mailing list! Please move 
to a mailing list dealing with database (MySQL?) questions.

The correct data type for binary data (like an image is) in most 
cases will be the Binary Large OBject - "BLOB". But it may differ 
depending on your database engine. For finding out how to put the 
image into the database table, please use one of these PHP mailing 
list / phorums.

Best regards,
Andreas
table. When I issue a CREATE table command, what attribute represents 
an image file? eg:

CREATE TABLE SClassTable (
  ?image _? NOT NULL,
--
procommerz - Internet fuer Unternehmen
http://www.procommerz.de | 033925-90710
Stoppt TCPA, das Zensursystem von Microsoft! | http://www.againsttcpa.com

--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]


help with PHP/SQL

2004-05-13 Thread ziada Mrisho



Hello,
 
I got your e-mail address from a forum thread on SQL Help. I desperately 
need help for my class project. I need to know how to insert an image in a 
database table. When I issue a CREATE table command, what attribute represents 
an image file? eg:
 
CREATE TABLE SClassTable (  ?image _? NOT 
NULL,  description VARCHAR (64) DEFAULT 
NULL,  reference INT (5) DEFAULT NULL,  price 
VARCHAR(15),  PRIMARY KEY (reference),  KEY 
(description)
 
Thanks in advance!


help with PHP/SQL

2004-05-13 Thread ziada Mrisho



Hello,
 
I got your e-mail address from a forum thread on SQL Help. I desperately 
need help for my class project. I need to know how to insert an image in a 
database table. When I issue a CREATE table command, what attribute represents 
an image file? eg:
 
CREATE TABLE SClassTable (  ?image _? NOT 
NULL,  description VARCHAR (64) DEFAULT 
NULL,  reference INT (5) DEFAULT NULL,  price 
VARCHAR(15),  PRIMARY KEY (reference),  KEY 
(description)
 
Thanks in advance!