Which data type should you recommend?

You plan to create a new column in a table. The column must meet the following
requirements:
Be able to store images that are larger than 1 MB each.
Be able to access the images from Microsoft .NET Framework applications.
You need to recommend which data type must be used in the column.
Which data type should you recommend?
More than one answer choice may achieve the goal. Select the BEST answer.

You plan to create a new column in a table. The column must meet the following
requirements:
Be able to store images that are larger than 1 MB each.
Be able to access the images from Microsoft .NET Framework applications.
You need to recommend which data type must be used in the column.
Which data type should you recommend?
More than one answer choice may achieve the goal. Select the BEST answer.

A.
nvarchar

B.
varbinary

C.
image

D.
FileStream



Leave a Reply 4

Your email address will not be published. Required fields are marked *


CB

CB

B

dp

dp

No it’s not. “D” (FileStream) is the right answer.

The Microsoft Research To Blob or Not To Blob explains this in depth. Their conclusion:
– if your pictures or documents are typically below 256K in size, storing them in a database VARBINARY column is more efficient
– if your pictures or document are typically over 1 MB in size, storing them in the filesystem is more efficient (and with SQL Server 2008’s FILESTREAM attribute, they’re still under transactional control and part of the database)
– in between those two, it’s a bit of a toss-up depending on your use

See:
http://research.microsoft.com/apps/pubs/default.aspx?id=64525
https://msdn.microsoft.com/library/hh461480

CB

CB

I agree with Filestream as the technoligy we should use other than the question says datatype:

https://msdn.microsoft.com/en-us/library/cc645583.aspx

varbinary(max) column and add the FILESTREAM attribute

its a tough one, no doubt

M A

M A

I agree with CB, Filestream is not a datatype, ‘varbinary’ is the correct answer