在Db中存储附录文件 [英] Store appendix Files in Db

查看:86
本文介绍了在Db中存储附录文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

HELLO

i可以将我的记录存储到sql server中的数据库。

但我如何将附录文件存储到DB?

IT可以存储图像文件,但是可以存储其他格式吗?例如word fils或excell文件存储在sql server DB中?

谢谢

HELLO
i can store my record to a database in sql server.
but how i can store appendix file to DB?
IT IS possible to store Image FILE , but is it possible to store other formats? such as word fils or excell files to store in sql server DB?
THANKS

推荐答案

是:如果你使用二进制字段,你可以在其中存储任何类型的信息,从Text(现代Word和Excel文件是XML文本文件)到二进制文件(如可执行文件)。

只需创建一个VARBINARY列,并使用参数化查询插入来自C#或VB代码的信息。
Yes: if you use a binary field, you can store any type of information in it, from Text (Modern Word and Excel files are XML text files) to binary such as executable files.
Just create a VARBINARY column, and use a parametrised query to insert the information from your C# or VB code.


这篇关于在Db中存储附录文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆