|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| ||||||||||||||||||||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Database storege ! Bad or good !
I'm intreseted in finding out what are the winings and the losses of using database storage!
I don't know if i should use it or i shouldn't ! |
|
#2
|
|||
|
|||
|
Message Moved
Thread moved from 'Database Help' to 'Programming Theory' by nawlej.
Reason: theory...... |
|
#3
|
|||
|
|||
|
RE: Database storege ! Bad or good !
Well, what do you wish to accomplish? There are pro's and cons for every application.
|
|
#4
|
|||
|
|||
|
Database storege ! Bad or good !
well i'm bilding a site for managing an on-line classified ads ...so there will be many pictures
every ad with his own picture ... |
|
#5
|
|||
|
|||
|
RE: Database storege ! Bad or good !
Well, database storage would definitely be the way to go in that case....What you can do is have your database just link to the pictures you place in a different directory, but have all the ad stuff in the database itself.
|
|
#6
|
|||
|
|||
|
RE: Database storege ! Bad or good !
tank you !
|
|
#7
|
|||
|
|||
|
So the new question is
so i have one new question i hope you get this!
I have to print some thumbnails ... so you know there is a problem with making them ... i know how to make them but the question is: "i make them from the original picture every time a ad is printed or i make another table in the database where i store the tumbnails ? "... and i get them from there wenever i need them ... and so the server wouldn't have to shrink the pitures every time they are printed ... I'm new to php and i have all sorts of problems regarding the speed and eficacy(i hope i spelled it right) .. so please help ! |
|
#8
|
||||
|
||||
|
RE: Database storege ! Bad or good !
It will save resources on the server if you have the thumbnails as separate images. Generally thumbnail images won't take too much disk space, so it might be good to create the thumbnail files for all images instead of regenerating them on every page load.
|
|
#9
|
|||
|
|||
|
RE: Database storege ! Bad or good !
Well, its a trade off....Do you want more of a load on your server, or do you want to spend more time editing them and shrinking them by hand?
|
|
#10
|
|||
|
|||
|
RE: Database storege ! Bad or good !
So i choose makeing the thumbnails and storing them in another table ... this way we only need more space cause when i think about it i realize that the same number of querys would be answered only this time for the thumbnails ...and when requesting for the big pictures another query for another table would be done ...
Being a biginer is hard cause i freak when i see the size of the database ... witch is growing ... growing ... and realy when would de like 1.000 ads then it will have an impresioning size like 1 Gb with an average of 100k per pic ... so that is really a big figure ... i really want to know how others managed this problem ... I'm at a university in the computer science department but my teachers aren't really very helpfull... |
|
#11
|
||||
|
||||
|
RE: Database storege ! Bad or good !
Or if you really wanted too you could store the actual image in the database using BLOB type.
|
|
#12
|
||||
|
||||
|
RE: RE: Database storege ! Bad or good !
Quote:
But you can always make a PHP script that shrinks the images and saves them to another file. No need for doing it by hand, computers are invented |
|
#13
|
|||
|
|||
|
RE: Database storege ! Bad or good !
i heva a mysql database in witch i use the blob field and i save the pictures ... but i ask you what could be betted .. to save a thumbnail in another table or to create the thumbnail with mogrify (ImageMagick) every time a picture is needed ...but meanwhile i decided that i save the thumbnails in another table
10x ! The question is what is better ... ? |
![]() |
| Viewing: Codewalkers Forums > Other Technologies > Programming Theory > Database storege ! Bad or good ! |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|