<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
		>
<channel>
	<title>Comments on: SQL SERVER &#8211; Do Not Store Images in Database &#8211; Store Location of Images (URL)</title>
	<atom:link href="http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/</link>
	<description>Personal Notes of Pinal Dave</description>
	<lastBuildDate>Fri, 10 Feb 2012 04:45:32 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
	<item>
		<title>By: Rahul Patil</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-242493</link>
		<dc:creator><![CDATA[Rahul Patil]]></dc:creator>
		<pubDate>Mon, 23 Jan 2012 05:29:12 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-242493</guid>
		<description><![CDATA[i want to store image database]]></description>
		<content:encoded><![CDATA[<p>i want to store image database</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: business directory</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-208155</link>
		<dc:creator><![CDATA[business directory]]></dc:creator>
		<pubDate>Wed, 30 Nov 2011 19:44:22 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-208155</guid>
		<description><![CDATA[Good day very cool blog!! Man .. Excellent .. Amazing .. I will bookmark your site and take the feeds also?I&#039;m glad to search out so many helpful information here in the submit, we&#039;d like develop extra techniques on this regard, thanks for sharing. . . . . .]]></description>
		<content:encoded><![CDATA[<p>Good day very cool blog!! Man .. Excellent .. Amazing .. I will bookmark your site and take the feeds also?I&#8217;m glad to search out so many helpful information here in the submit, we&#8217;d like develop extra techniques on this regard, thanks for sharing. . . . . .</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Harsha Bhagat</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-206523</link>
		<dc:creator><![CDATA[Harsha Bhagat]]></dc:creator>
		<pubDate>Mon, 28 Nov 2011 14:48:01 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-206523</guid>
		<description><![CDATA[Hi Pinal,

Everywhere its said not to use image /BLOB data types. But when the database have those columns and which is unavoidable then what we can do. I need to replicate a table and this table take 5hrs.. to replicate.  Can you suggest how to increase the performance for replicate this table.

Thanks in advance.]]></description>
		<content:encoded><![CDATA[<p>Hi Pinal,</p>
<p>Everywhere its said not to use image /BLOB data types. But when the database have those columns and which is unavoidable then what we can do. I need to replicate a table and this table take 5hrs.. to replicate.  Can you suggest how to increase the performance for replicate this table.</p>
<p>Thanks in advance.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Froggy</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-202984</link>
		<dc:creator><![CDATA[Froggy]]></dc:creator>
		<pubDate>Wed, 23 Nov 2011 16:13:53 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-202984</guid>
		<description><![CDATA[I think it depends on how well the indexing system of the DBM works. When you only store the filepath/filename in the database you practically handle the indexing yourself. That at least in theory should be faster unless you cram thousands of small files into one directory -- more than 2000-2500 files and you will move at a snail pace -- try placing that many files in a directory and then try accessing it - it will take forever. So depending on how you arrange those files it could even be slower.
I work on a daily basis with a 400K+ records IBM DB2 table containing 16kb images and access time is usually under 1s so it&#039;s pretty good. And that&#039;s an old DBM version(7.2)  running on an old IBM OS2 operating system inside a virtual machine so there is much room for improvements.
I think every DBM has caching mechanisms that work quite good so we shouldn&#039;t be afraid of using them. As I said storing only the filename should be faster but only if you spend the time on optimizing the directory structure and for me that is not worth it. Just let the DBM handle it.
Of course for databases with tens of millions of records things could be different and performance issues could force someone to reconsider.]]></description>
		<content:encoded><![CDATA[<p>I think it depends on how well the indexing system of the DBM works. When you only store the filepath/filename in the database you practically handle the indexing yourself. That at least in theory should be faster unless you cram thousands of small files into one directory &#8212; more than 2000-2500 files and you will move at a snail pace &#8212; try placing that many files in a directory and then try accessing it &#8211; it will take forever. So depending on how you arrange those files it could even be slower.<br />
I work on a daily basis with a 400K+ records IBM DB2 table containing 16kb images and access time is usually under 1s so it&#8217;s pretty good. And that&#8217;s an old DBM version(7.2)  running on an old IBM OS2 operating system inside a virtual machine so there is much room for improvements.<br />
I think every DBM has caching mechanisms that work quite good so we shouldn&#8217;t be afraid of using them. As I said storing only the filename should be faster but only if you spend the time on optimizing the directory structure and for me that is not worth it. Just let the DBM handle it.<br />
Of course for databases with tens of millions of records things could be different and performance issues could force someone to reconsider.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mohammed Khaja Ahsanuddin</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-197969</link>
		<dc:creator><![CDATA[Mohammed Khaja Ahsanuddin]]></dc:creator>
		<pubDate>Thu, 17 Nov 2011 21:07:47 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-197969</guid>
		<description><![CDATA[Could any one tell me how can I export the IMAGE or any other FILE which is inserted in database?

how to retrieve it in sql command prompt?]]></description>
		<content:encoded><![CDATA[<p>Could any one tell me how can I export the IMAGE or any other FILE which is inserted in database?</p>
<p>how to retrieve it in sql command prompt?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: madhivanan</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-182970</link>
		<dc:creator><![CDATA[madhivanan]]></dc:creator>
		<pubDate>Mon, 24 Oct 2011 16:58:11 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-182970</guid>
		<description><![CDATA[The simple and effecient method is to store only path of the file in a column and store actual images in the server&#039;s directory.]]></description>
		<content:encoded><![CDATA[<p>The simple and effecient method is to store only path of the file in a column and store actual images in the server&#8217;s directory.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: upender</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-181104</link>
		<dc:creator><![CDATA[upender]]></dc:creator>
		<pubDate>Thu, 20 Oct 2011 08:54:37 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-181104</guid>
		<description><![CDATA[how can we storage image in database and how to retrieving it in sql command prompt.]]></description>
		<content:encoded><![CDATA[<p>how can we storage image in database and how to retrieving it in sql command prompt.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ehsan</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-176744</link>
		<dc:creator><![CDATA[Ehsan]]></dc:creator>
		<pubDate>Sun, 09 Oct 2011 09:48:40 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-176744</guid>
		<description><![CDATA[I think the size of a Data Base is not Important anyway. Because today&#039;s DBMS&#039;s are very Powerful (such as SQL Server 2008).
But its better you use two or more File-group For a Data Base.
You can determine each table goes to a different File-Group and even you can determine each File-Group save in a different Drive

example:
Table1 save to  File-Group1 And File-Group1 Save in Drive C
Table2 save to  File-Group2 And File-Group2 Save in Drive D Of Hard Disc2

Today&#039;s if someone say: &quot; it&#039;s not correct to save the images to the database because the database will huge &quot; Like someone say : &quot; it&#039;s Not correct to save the images to the Hard Disc!&quot;]]></description>
		<content:encoded><![CDATA[<p>I think the size of a Data Base is not Important anyway. Because today&#8217;s DBMS&#8217;s are very Powerful (such as SQL Server 2008).<br />
But its better you use two or more File-group For a Data Base.<br />
You can determine each table goes to a different File-Group and even you can determine each File-Group save in a different Drive</p>
<p>example:<br />
Table1 save to  File-Group1 And File-Group1 Save in Drive C<br />
Table2 save to  File-Group2 And File-Group2 Save in Drive D Of Hard Disc2</p>
<p>Today&#8217;s if someone say: &#8221; it&#8217;s not correct to save the images to the database because the database will huge &#8221; Like someone say : &#8221; it&#8217;s Not correct to save the images to the Hard Disc!&#8221;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: ravi</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-172262</link>
		<dc:creator><![CDATA[ravi]]></dc:creator>
		<pubDate>Mon, 26 Sep 2011 18:45:21 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-172262</guid>
		<description><![CDATA[you can use the image data type instead of string var 
for eg. Image img=&quot;src path&quot;
and pass this img to the label]]></description>
		<content:encoded><![CDATA[<p>you can use the image data type instead of string var<br />
for eg. Image img=&#8221;src path&#8221;<br />
and pass this img to the label</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Riza</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-132537</link>
		<dc:creator><![CDATA[Riza]]></dc:creator>
		<pubDate>Mon, 02 May 2011 18:53:50 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-132537</guid>
		<description><![CDATA[//--- You can store the file location into the database using the below code. --//

//-- you need to have a FileUpload control in your page to upload the images --//

string myFileName = FileUpload1.PostedFile.FileName;
        string copy = Path.GetFileName(myFileName);

        try
        {
            string Upath = @&quot;~\Images\&quot; + copy; //-- This is the server path where the images are stored--//
            FileUpload1.PostedFile.SaveAs(@&quot;C:\Images\&quot; + copy); //-- This is the same server path in file system using file path instead of root directory. This is just for an example --//

            string sql = &quot;INSERT INTO Frm_ATAC_Events (Content_Type, File_Path) VALUES (&#039;&quot; + FileUpload1.PostedFile.ContentType + &quot;&#039;, &#039;&quot; + Upath + &quot;&#039;);&quot;;
            SqlConnection connection = ConnectionManager.GetAetnaForumDBConnection();
            SqlCommand command = new SqlCommand(sql, connection);
            command.CommandType = CommandType.Text;

            command.ExecuteNonQuery();
        }
        catch (Exception ex)
        {
            Response.Write(ex.Message);
        }


//-- You can use the below code to retrieve the images back to a grid view--//
        DataSet ds=new DataSet();
        string sql = &quot;SELECT FILE_PATH, CONTENT_TYPE FROM Image_Table&quot;;
        SqlConnection connection = ConnectionManager.GetAetnaForumDBConnection();
        SqlCommand command = new SqlCommand(sql, connection);
        command.CommandType = CommandType.Text;

        SqlDataAdapter adapter = new SqlDataAdapter(command);
        adapter.Fill(ds, &quot;Images&quot;);

        GridView2.DataSource = ds.Tables[0];
        GridView2.DataBind();

//--- Now Bind the ImageUrl in the gridview to the File_path field using the code &#039;Eavl(&quot;File_Path&quot;)&#039;.--//

This should work very well...]]></description>
		<content:encoded><![CDATA[<p>//&#8212; You can store the file location into the database using the below code. &#8211;//</p>
<p>//&#8211; you need to have a FileUpload control in your page to upload the images &#8211;//</p>
<p>string myFileName = FileUpload1.PostedFile.FileName;<br />
        string copy = Path.GetFileName(myFileName);</p>
<p>        try<br />
        {<br />
            string Upath = @&#8221;~\Images\&#8221; + copy; //&#8211; This is the server path where the images are stored&#8211;//<br />
            FileUpload1.PostedFile.SaveAs(@&#8221;C:\Images\&#8221; + copy); //&#8211; This is the same server path in file system using file path instead of root directory. This is just for an example &#8211;//</p>
<p>            string sql = &#8220;INSERT INTO Frm_ATAC_Events (Content_Type, File_Path) VALUES (&#8216;&#8221; + FileUpload1.PostedFile.ContentType + &#8220;&#8216;, &#8216;&#8221; + Upath + &#8220;&#8216;);&#8221;;<br />
            SqlConnection connection = ConnectionManager.GetAetnaForumDBConnection();<br />
            SqlCommand command = new SqlCommand(sql, connection);<br />
            command.CommandType = CommandType.Text;</p>
<p>            command.ExecuteNonQuery();<br />
        }<br />
        catch (Exception ex)<br />
        {<br />
            Response.Write(ex.Message);<br />
        }</p>
<p>//&#8211; You can use the below code to retrieve the images back to a grid view&#8211;//<br />
        DataSet ds=new DataSet();<br />
        string sql = &#8220;SELECT FILE_PATH, CONTENT_TYPE FROM Image_Table&#8221;;<br />
        SqlConnection connection = ConnectionManager.GetAetnaForumDBConnection();<br />
        SqlCommand command = new SqlCommand(sql, connection);<br />
        command.CommandType = CommandType.Text;</p>
<p>        SqlDataAdapter adapter = new SqlDataAdapter(command);<br />
        adapter.Fill(ds, &#8220;Images&#8221;);</p>
<p>        GridView2.DataSource = ds.Tables[0];<br />
        GridView2.DataBind();</p>
<p>//&#8212; Now Bind the ImageUrl in the gridview to the File_path field using the code &#8216;Eavl(&#8220;File_Path&#8221;)&#8217;.&#8211;//</p>
<p>This should work very well&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tommy Long</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-122884</link>
		<dc:creator><![CDATA[Tommy Long]]></dc:creator>
		<pubDate>Fri, 11 Mar 2011 15:20:57 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-122884</guid>
		<description><![CDATA[As you mentioned yourself, DTC is your friend.  You can encompass SQL Server Changes and File/IO changes inside a single transaction.]]></description>
		<content:encoded><![CDATA[<p>As you mentioned yourself, DTC is your friend.  You can encompass SQL Server Changes and File/IO changes inside a single transaction.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: dev.fslash.null</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-105789</link>
		<dc:creator><![CDATA[dev.fslash.null]]></dc:creator>
		<pubDate>Wed, 15 Dec 2010 06:54:15 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-105789</guid>
		<description><![CDATA[The ACID properties of transactions are difficult and complex to maintain if you use a file.

You may want to write to a temporary file and rename the file on successful transaction.

Moreover, optimizations to database design and query style can be more helpful.

As suggested above you can use another table to store the images, and retrieve the image only when necessary. Thereby, reducing the load on database server.]]></description>
		<content:encoded><![CDATA[<p>The ACID properties of transactions are difficult and complex to maintain if you use a file.</p>
<p>You may want to write to a temporary file and rename the file on successful transaction.</p>
<p>Moreover, optimizations to database design and query style can be more helpful.</p>
<p>As suggested above you can use another table to store the images, and retrieve the image only when necessary. Thereby, reducing the load on database server.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Richardson</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-93096</link>
		<dc:creator><![CDATA[Richardson]]></dc:creator>
		<pubDate>Thu, 14 Oct 2010 19:35:23 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-93096</guid>
		<description><![CDATA[IMO...
SQL Server 2008 has a option wich alocate phisically (file system) the file stored in a field, this does not stay together the &quot;normal&quot; content row.]]></description>
		<content:encoded><![CDATA[<p>IMO&#8230;<br />
SQL Server 2008 has a option wich alocate phisically (file system) the file stored in a field, this does not stay together the &#8220;normal&#8221; content row.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: AM</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-85738</link>
		<dc:creator><![CDATA[AM]]></dc:creator>
		<pubDate>Tue, 31 Aug 2010 05:14:04 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-85738</guid>
		<description><![CDATA[Just run a SELECT * on your table with images and then run a select without the blob field and you will see the performance difference.]]></description>
		<content:encoded><![CDATA[<p>Just run a SELECT * on your table with images and then run a select without the blob field and you will see the performance difference.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Aammini</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-82461</link>
		<dc:creator><![CDATA[Aammini]]></dc:creator>
		<pubDate>Sat, 31 Jul 2010 12:06:59 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-82461</guid>
		<description><![CDATA[I am not disputing about storing images in the filesytem and store rest of the file info in the database.  I have seen so many links that teach you from the scratch in different logic than my code. but I am trying to fit only this binaryfile blocks into my code logic.  Though  my destination is to get to display the directory path in the browser, I think I have to rephrase my question to avoid confusion at this point. 

I only want this single question answered please. 

 Could you store directory path in a string variable and display that value in the browser through any other webcontrols or directly? If yes please show me how did you do it?

Thanks
Ama]]></description>
		<content:encoded><![CDATA[<p>I am not disputing about storing images in the filesytem and store rest of the file info in the database.  I have seen so many links that teach you from the scratch in different logic than my code. but I am trying to fit only this binaryfile blocks into my code logic.  Though  my destination is to get to display the directory path in the browser, I think I have to rephrase my question to avoid confusion at this point. </p>
<p>I only want this single question answered please. </p>
<p> Could you store directory path in a string variable and display that value in the browser through any other webcontrols or directly? If yes please show me how did you do it?</p>
<p>Thanks<br />
Ama</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Feodor</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-82430</link>
		<dc:creator><![CDATA[Feodor]]></dc:creator>
		<pubDate>Sat, 31 Jul 2010 07:20:54 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-82430</guid>
		<description><![CDATA[Hello,
the implementation depends on what technology you use for the middle tier, but the logic for the images is very similar: the players in your game are Web server, database server and middle tier (.NET programming language, lets say which commands the database and serves the Web server.)
So, you save the physical images on the web server (well, in an ideal world you have a media server), then in the web.config in the middle tier you save the first part of the path to the image, i.e. the directory path which is common for the images. Then in the database you write only the picture unique path and the picture file name. (And you will need a imageID or something to distinguish it from the other images when you search for it in the database table). Now, when you need an image displayed on your website, you will have a control (some kind of encapsulated logic) to which you will pass the imageID and the control will go to the database, get the image info, concatenate it with the information from the web.config, and voila - you have a image path which works. I am sure that there are plenty of examples on the web.]]></description>
		<content:encoded><![CDATA[<p>Hello,<br />
the implementation depends on what technology you use for the middle tier, but the logic for the images is very similar: the players in your game are Web server, database server and middle tier (.NET programming language, lets say which commands the database and serves the Web server.)<br />
So, you save the physical images on the web server (well, in an ideal world you have a media server), then in the web.config in the middle tier you save the first part of the path to the image, i.e. the directory path which is common for the images. Then in the database you write only the picture unique path and the picture file name. (And you will need a imageID or something to distinguish it from the other images when you search for it in the database table). Now, when you need an image displayed on your website, you will have a control (some kind of encapsulated logic) to which you will pass the imageID and the control will go to the database, get the image info, concatenate it with the information from the web.config, and voila &#8211; you have a image path which works. I am sure that there are plenty of examples on the web.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: aammini</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-82385</link>
		<dc:creator><![CDATA[aammini]]></dc:creator>
		<pubDate>Fri, 30 Jul 2010 18:54:57 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-82385</guid>
		<description><![CDATA[I been trying to get the answer for this for long time. I dont&#039; know either, how to store the filepath in the database.  Did you solve this issue.  Pleaes let me know if you know how to store.  Atleast I would like to see it displayed in a lable control or something if not in DB. Cuz I assigned a directory path using &quot;~/picture/ samples &quot; to a string variable, but when I tried to dispaly this string variable in a lable control I dont&#039; see any value at all. Can anyone answer me why or tell me how to get it displayed?

thanks
Ama]]></description>
		<content:encoded><![CDATA[<p>I been trying to get the answer for this for long time. I dont&#8217; know either, how to store the filepath in the database.  Did you solve this issue.  Pleaes let me know if you know how to store.  Atleast I would like to see it displayed in a lable control or something if not in DB. Cuz I assigned a directory path using &#8220;~/picture/ samples &#8221; to a string variable, but when I tried to dispaly this string variable in a lable control I dont&#8217; see any value at all. Can anyone answer me why or tell me how to get it displayed?</p>
<p>thanks<br />
Ama</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Wolf</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-78637</link>
		<dc:creator><![CDATA[Wolf]]></dc:creator>
		<pubDate>Sat, 03 Jul 2010 02:33:47 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-78637</guid>
		<description><![CDATA[As I read above, true and must be concern for “It depends of your company strategy and direction”. We lived for almost 8 years with, SQL for main human resource information of “30 GB” size, with 1T of image with average 150k on file system. We hardly face problem. linked with the “path name”, “filenumber”, File Name”. Because some time the ID change to new one, so we must have different number for it in our database, with new path link in his record.
First, we start it fine, but now as I see the same person come back after a while with new picture and information to add in our system. New scan added to last point in our file system. Whish after a while we start to have defragmentation process for file system to keep all the image together.
But after reading here, I Liked the Ida of having the second Database, which it can be index, Linked with first SQL, Cluster,  and a lot of easy to recover for DR, redundancy, backup, even in the future if we feel in performance problem, we can easily add more server for load balance, with share hard disk like SAN, or IBM Shark.
Also, I see in important point of a lot of IO in file system, which is most of the time killing the system or wait a lot more second to get in process. But in SQL, in the future you can have a lot of backup for yourself to play with or even to expand, like adding extra server for load balancing, fail over and a lot more, which a lose don’t put you in bad shape as a designer or responsible for the project .
From the application side, once the employee enter ID, automatically he get in the back process to “his PC cash” five to ten image arrived. And as SQL, or DB2, you can have a lot of option to play with as increasing hardware like, cash memory, increase number of server, a lot of tools to have your data also in cash level and so on. With file system, you will see yourself a lot restricted, and not mush to do.
Regard…]]></description>
		<content:encoded><![CDATA[<p>As I read above, true and must be concern for “It depends of your company strategy and direction”. We lived for almost 8 years with, SQL for main human resource information of “30 GB” size, with 1T of image with average 150k on file system. We hardly face problem. linked with the “path name”, “filenumber”, File Name”. Because some time the ID change to new one, so we must have different number for it in our database, with new path link in his record.<br />
First, we start it fine, but now as I see the same person come back after a while with new picture and information to add in our system. New scan added to last point in our file system. Whish after a while we start to have defragmentation process for file system to keep all the image together.<br />
But after reading here, I Liked the Ida of having the second Database, which it can be index, Linked with first SQL, Cluster,  and a lot of easy to recover for DR, redundancy, backup, even in the future if we feel in performance problem, we can easily add more server for load balance, with share hard disk like SAN, or IBM Shark.<br />
Also, I see in important point of a lot of IO in file system, which is most of the time killing the system or wait a lot more second to get in process. But in SQL, in the future you can have a lot of backup for yourself to play with or even to expand, like adding extra server for load balancing, fail over and a lot more, which a lose don’t put you in bad shape as a designer or responsible for the project .<br />
From the application side, once the employee enter ID, automatically he get in the back process to “his PC cash” five to ten image arrived. And as SQL, or DB2, you can have a lot of option to play with as increasing hardware like, cash memory, increase number of server, a lot of tools to have your data also in cash level and so on. With file system, you will see yourself a lot restricted, and not mush to do.<br />
Regard…</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Picture this</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-76660</link>
		<dc:creator><![CDATA[Picture this]]></dc:creator>
		<pubDate>Thu, 17 Jun 2010 16:20:43 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-76660</guid>
		<description><![CDATA[Pictures in Database.
1) Is there any reduction in the image quality of the picture?
2) If the database crashes (hopefully there is a backup) do you loose thousands of pictures?
3) Which loads into a web page faster?  The DB picture or the file system picture?  I would think the DB picture.
4) If the pictures are not in the database you can easily review them,  edit them, and update them if you need to without digging into the database.   This can be a plus, or as said, a minus for medical or legal pictures.  It could be a mess if the relation to the database links is not clearlly understood.
5)  If somone needs a copy of the picture, say on flash drive, how easy is it to extract it and provide that?]]></description>
		<content:encoded><![CDATA[<p>Pictures in Database.<br />
1) Is there any reduction in the image quality of the picture?<br />
2) If the database crashes (hopefully there is a backup) do you loose thousands of pictures?<br />
3) Which loads into a web page faster?  The DB picture or the file system picture?  I would think the DB picture.<br />
4) If the pictures are not in the database you can easily review them,  edit them, and update them if you need to without digging into the database.   This can be a plus, or as said, a minus for medical or legal pictures.  It could be a mess if the relation to the database links is not clearlly understood.<br />
5)  If somone needs a copy of the picture, say on flash drive, how easy is it to extract it and provide that?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Feodor</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-67701</link>
		<dc:creator><![CDATA[Feodor]]></dc:creator>
		<pubDate>Thu, 29 Apr 2010 07:27:53 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-67701</guid>
		<description><![CDATA[I definitely agree with Pinal regarding the images in a database - it is a bad idea in general. The reason for this is scalability: over time you will eventually come to an IO bottleneck if you keep your images in a database. The you will try to purchase more and faster storage, then you will have to think about partitioning of your database, then about complicated backup strategies. On the other hand, if you keep the images on disk, there are many free tools (Microsoft Resource toolkit, for example) which will give you the opportunity to backup only the changed files, and eventually you will come to a point when you will need a standalone media server. 
In SQL 2008 you can look into filestream, which changes things a bit.]]></description>
		<content:encoded><![CDATA[<p>I definitely agree with Pinal regarding the images in a database &#8211; it is a bad idea in general. The reason for this is scalability: over time you will eventually come to an IO bottleneck if you keep your images in a database. The you will try to purchase more and faster storage, then you will have to think about partitioning of your database, then about complicated backup strategies. On the other hand, if you keep the images on disk, there are many free tools (Microsoft Resource toolkit, for example) which will give you the opportunity to backup only the changed files, and eventually you will come to a point when you will need a standalone media server.<br />
In SQL 2008 you can look into filestream, which changes things a bit.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: mcat-atl</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-64235</link>
		<dc:creator><![CDATA[mcat-atl]]></dc:creator>
		<pubDate>Thu, 01 Apr 2010 14:25:43 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-64235</guid>
		<description><![CDATA[I would like to know which drives for the NTFS files system would be preferred.

We have a SAN with combonation SATA and FC-drives.   
Can I still store the binary\photo files onto the SATA (15k) drives with HBA(4gb) and get good performance on the reads and writes?  Very curious about this one?   The system will produce fast transaction from mobile pda&#039;s and about 6000 users will update within about 3hr period.  Any other performance recommendation will be greatly appreciated.  I have already sepreate all data files on seperat arrrays and give tempdb 6 fix length files.

Please comment at will.]]></description>
		<content:encoded><![CDATA[<p>I would like to know which drives for the NTFS files system would be preferred.</p>
<p>We have a SAN with combonation SATA and FC-drives.<br />
Can I still store the binary\photo files onto the SATA (15k) drives with HBA(4gb) and get good performance on the reads and writes?  Very curious about this one?   The system will produce fast transaction from mobile pda&#8217;s and about 6000 users will update within about 3hr period.  Any other performance recommendation will be greatly appreciated.  I have already sepreate all data files on seperat arrrays and give tempdb 6 fix length files.</p>
<p>Please comment at will.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jobin</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-64092</link>
		<dc:creator><![CDATA[Jobin]]></dc:creator>
		<pubDate>Wed, 31 Mar 2010 06:40:33 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-64092</guid>
		<description><![CDATA[it is a wonderful site providing valueble information for my project]]></description>
		<content:encoded><![CDATA[<p>it is a wonderful site providing valueble information for my project</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: swd1974</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-64067</link>
		<dc:creator><![CDATA[swd1974]]></dc:creator>
		<pubDate>Tue, 30 Mar 2010 17:39:15 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-64067</guid>
		<description><![CDATA[I prefer to store in the DB. Space is not an argument. You will either have a larger DB or you will need a file server fo rlarge sites with a lot of photos for example. So its much cheaper tohave it in the DB.

The insert/update/select is by no means &quot;massive&quot; as the author says. You would have a memberid or some other indexed cilumn in which you are using to grab the row.

I think it is much nicer to not have to worry about a file server. The performance hit is marginal it is definately worth doing. 

Plus it also allows you to stop using cffile and you cna use cfimage tags and functions to alter image to a blob and pas sit to your stored proc. 

Its a win win all the way around really. I own a dating site with over 100k members and store all profile pictures in the DB. Each member can have up to 200 photos. When I display the gallery I do a next n and only show 10 at a time.]]></description>
		<content:encoded><![CDATA[<p>I prefer to store in the DB. Space is not an argument. You will either have a larger DB or you will need a file server fo rlarge sites with a lot of photos for example. So its much cheaper tohave it in the DB.</p>
<p>The insert/update/select is by no means &#8220;massive&#8221; as the author says. You would have a memberid or some other indexed cilumn in which you are using to grab the row.</p>
<p>I think it is much nicer to not have to worry about a file server. The performance hit is marginal it is definately worth doing. </p>
<p>Plus it also allows you to stop using cffile and you cna use cfimage tags and functions to alter image to a blob and pas sit to your stored proc. </p>
<p>Its a win win all the way around really. I own a dating site with over 100k members and store all profile pictures in the DB. Each member can have up to 200 photos. When I display the gallery I do a next n and only show 10 at a time.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Madhivanan</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-63054</link>
		<dc:creator><![CDATA[Madhivanan]]></dc:creator>
		<pubDate>Wed, 17 Mar 2010 08:12:16 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-63054</guid>
		<description><![CDATA[Just pass the file path as the column value in the SELECT statement and make sure the files are located in Server&#039;s directory]]></description>
		<content:encoded><![CDATA[<p>Just pass the file path as the column value in the SELECT statement and make sure the files are located in Server&#8217;s directory</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Brian</title>
		<link>http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-62511</link>
		<dc:creator><![CDATA[Brian]]></dc:creator>
		<pubDate>Tue, 09 Mar 2010 11:20:19 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/12/13/sql-server-do-not-store-images-in-database-store-location-of-images-url/#comment-62511</guid>
		<description><![CDATA[sorry the last one was:
http://images.cars.com/supersized/DMI/148974/F4777A.jpg

Also never finish the sentence &quot;In my case all images..&quot; 

should say &quot;In my case all images are probably less than 50k each.]]></description>
		<content:encoded><![CDATA[<p>sorry the last one was:<br />
<a href="http://images.cars.com/supersized/DMI/148974/F4777A.jpg" rel="nofollow">http://images.cars.com/supersized/DMI/148974/F4777A.jpg</a></p>
<p>Also never finish the sentence &#8220;In my case all images..&#8221; </p>
<p>should say &#8220;In my case all images are probably less than 50k each.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

