Chat LIVE With Programming Experts! There Are 23 Online Right Now...

Welcome to Dream.In.Code
Become an Expert!

Join 244,310 Programmers for FREE! Get instant access to thousands of experts, tutorials, code snippets, and more! There are 864 people online right now. Registration is fast and FREE... Join Now!




saving images in database

 
Reply to this topicStart new topic

saving images in database, using java swing

mbkweb
24 Jun, 2005 - 02:45 AM
Post #1

New D.I.C Head
*

Joined: 28 May, 2005
Posts: 5

hi all!
i need to physically store images in database

i think its done by converting them to binaries ...

i am using JDBC-ODBC bridge in java
and the database is

MS Access Database .mdb file


i need help

tell me howto do it

dont ask y!

thnx!

User is offlineProfile CardPM
+Quote Post


Amadeus
RE: Saving Images In Database
24 Jun, 2005 - 04:24 AM
Post #2

g++ -o drink whiskey.cpp
Group Icon

Joined: 12 Jul, 2002
Posts: 12,977



Thanked: 116 times
Dream Kudos: 25
My Contributions
Y? Why? Por qué? Pourquoi? Warum? почему?

Actually, I don't care.

If you are using an Access database to store images, you should add an OLE Object field to the table, and store it there. the storage procedure is the same as it is for other record inserts.

Although your motivations are your own business, I would be remiss if I did not mention that physical storage of images to a database (especially Access) will lead to db bloat and application slowdowns in the long run.
User is online!Profile CardPM
+Quote Post

chiahyuigiek
RE: Saving Images In Database
18 Sep, 2005 - 08:27 PM
Post #3

New D.I.C Head
*

Joined: 18 Sep, 2005
Posts: 1


My Contributions
hihi , i facing the same problems here , which is how to store movie file which is in avi format in to my MYSQL database ....

Anyone can help me ? Thanks a lot !
User is offlineProfile CardPM
+Quote Post

skyhawk133
RE: Saving Images In Database
18 Sep, 2005 - 08:41 PM
Post #4

Head DIC Head
Group Icon

Joined: 17 Mar, 2001
Posts: 16,441



Thanked: 117 times
Dream Kudos: 1650
Expert In: Web Development

My Contributions
In the table you want to store your movies, create a field that has LONGBLOB as the datatype. If you need further information on how to get the AVI in to mySQL, I would suggest looking at this article:

http://www.phpbuilder.com/columns/florian19991014.php3

Same concept, just with images.

I too will say the same thing Amadeus said. Storing images or other binary data in a database is not the best idea. You will end up with database bloat and problems with your applications under load. It's much better to just store a reference to the file.

Welcome to dream.in.code!!!
User is offlineProfile CardPM
+Quote Post

jspidy
RE: Saving Images In Database
31 Oct, 2005 - 06:24 AM
Post #5

New D.I.C Head
*

Joined: 25 Feb, 2005
Posts: 11



Thanked: 1 times
My Contributions
QUOTE(skyhawk133 @ Sep 19 2005, 06:38 AM)
In the table you want to store your movies, create a field that has LONGBLOB as the datatype. If you need further information on how to get the AVI in to mySQL, I would suggest looking at this article:

http://www.phpbuilder.com/columns/florian19991014.php3

Same concept, just with images.

I too will say the same thing Amadeus said. Storing images or other binary data in a database is not the best idea. You will end up with database bloat and problems with your applications under load. It's much better to just store a reference to the file.

Welcome to dream.in.code!!!

Iam using access i wnat to store images either in the database or on the server with a link in the database.
I can insert the link for the image if uploaded to the server but it wont upload the image, or it uploads the image to the server but doesnt create a link in the database where am i going wrong please help me
Jay
Iam using coldfusion7 and access 2003..
User is offlineProfile CardPM
+Quote Post

enteng
RE: Saving Images In Database
14 Sep, 2007 - 11:35 PM
Post #6

D.I.C Head
**

Joined: 2 Sep, 2007
Posts: 56



Thanked: 1 times
My Contributions
hello i'm experiencing same problem, i want to save images n my access table using vb.net. please help me. tnx
User is offlineProfile CardPM
+Quote Post

born2c0de
RE: Saving Images In Database
14 Sep, 2007 - 11:52 PM
Post #7

printf("I'm a %XR",195936478);
Group Icon

Joined: 26 Nov, 2004
Posts: 4,353



Thanked: 81 times
Dream Kudos: 2800
Expert In: J2ME, 80x86 Assembly, C/C++, VB6, VB.NET, C#, J2SE, Win32 API, Reversing

My Contributions
All the answers are already here on </dic>.
Search for posts before you start one.
Click here.
User is offlineProfile CardPM
+Quote Post

rajeev kumar
RE: Saving Images In Database
21 Sep, 2007 - 06:17 AM
Post #8

New D.I.C Head
*

Joined: 21 Sep, 2007
Posts: 1


My Contributions
hi i want to know how to store images in oracle

This post has been edited by rajeev kumar: 21 Sep, 2007 - 06:22 AM
User is offlineProfile CardPM
+Quote Post

Swetadri
RE: Saving Images In Database
22 Nov, 2007 - 05:44 AM
Post #9

New D.I.C Head
*

Joined: 22 Nov, 2007
Posts: 8


My Contributions
i also need to save audio file in MSQL database....but in java platform....can anybody help?
Thanx in advance
User is offlineProfile CardPM
+Quote Post

Swetadri
RE: Saving Images In Database
22 Nov, 2007 - 05:52 AM
Post #10

New D.I.C Head
*

Joined: 22 Nov, 2007
Posts: 8


My Contributions
QUOTE(Swetadri @ 22 Nov, 2007 - 06:44 AM) *

I also need to save audio file in MySQL database....but in java platform,not in php....can anybody help?
Thanx in advance


User is offlineProfile CardPM
+Quote Post

baavgai
RE: Saving Images In Database
22 Nov, 2007 - 06:46 AM
Post #11

Dreaming Coder
Group Icon

Joined: 16 Oct, 2007
Posts: 3,572



Thanked: 268 times
Dream Kudos: 525
Expert In: C, C++, Java, C#, ASP.NET, PHP, Perl, Python, Oracle, SQL Server, MySql, HTML, JavaScript, Lua, Cheese

My Contributions
This topic just wont die, huh?

For Java, blob, and mysql, I found this: http://www.informit.com/guides/content.asp...um=166&rl=1

It should be noted that in all "I want to store random binary stuff in my database" scenarios, it's generally not ideal. Sure, it sounds cool, but it's just not what databases do well and they tend to do it under protest. Consider long and hard why a filesystem solution is not preferred before traveling down this path.

User is online!Profile CardPM
+Quote Post

Fast ReplyReply to this topicStart new topic

Time is now: 7/4/09 07:19PM

Live Help!

Be Social

Dream.In.Code RSS Feed Dream.In.Code LinkedIn Group Follow Us On Twitter Fan Us On Facebook

Tutorials

Programming

Web Development

Reference Sheets

Code Snippets

DIC Chatroom

Bye Bye Ads

Monthly Drawing

Thumb Drive

Top Contributors

Top 10 Kudos This Month