更新SQL Server中的映像 [英] update the image in sql server
本文介绍了更新SQL Server中的映像的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
更新sqlserver中的映像:
当我在SQLserver中使用像这样的更新命令时.
更新TableName设置ImageCoumnName = @ImageData,其中ID = @ID
它会更新图像,但它是白色的,而不是正确的图像.
update image in sqlserver :
when i am using update command like this in SQLserver.
Update TableName set ImageCoumnName = @ImageData where ID = @ID
it updates the image but it is white and not the proper image.
推荐答案
检查这些链接
http://chiragrdarji.wordpress.com/2007/03 /05/storing-and-retrieving-image-in-sql-server/ [存储图像 [检索图像 [
Check these links
http://chiragrdarji.wordpress.com/2007/03/05/storing-and-retrieving-image-in-sql-server/[^]
Storing images[^]
Retrieving images[^]
您没有给我们足够的代码.
检查这堆如何在其中保存和检索图像使用Asp.net的数据库 [ ^ ](它也包含有趣的讨论)
You didn''t give us enough code.
Check this bunch How to save and retrieve Image in Database using Asp.net[^](It contains also interesting discussions too)
通过使用命令参数,我们可以存档
it is by using command parameters we can archive
System.Data.SqlClient.SqlParameter param1 = new System.Data.SqlClient.SqlParameter("@Pic3", SqlDbType.Image);
param1.Value = im3;
cmd.Parameters.Add(param1);
* im3是二进制数组
* im3 is a binary array
这篇关于更新SQL Server中的映像的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文