Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 242
  • Last Modified:

NEWBIE: Stroring XML in MS SQL 2005

Dear Experts,

My company is considering storing XML strings of maybe 10 or 20 thousand bytes in SQL Server 2005.  We don't know much of anything about it yet.  So first:

1.  Would we store the whole thing as a long string, or does SQL Server support storing it as actual XML nodes?

2.  If stored as one long string, how would you store it?  varchar?  blob?

3.  Does SQL Server provide it's own support for viewing the string as XML?  Some sort of UI, expandable nodes, etc.?

Thanks a lot?
--BrianMc1958
0
BrianMc1958
Asked:
BrianMc1958
1 Solution
 
Atlanta_MikeCommented:
SQL Server 2005 supports a new datatype called XML. It is more efficient storing an XML string as XML vs Text or varchar(MAX) because is will replace commonly used nodes and characters with a replacement character (in the background where you won't ever see it).

Not only can you view it, you can search the string.

It's probably one of the coolest features of SQL Server 2005.
0

Featured Post

NFR key for Veeam Backup for Microsoft Office 365

Veeam is happy to provide a free NFR license (for 1 year, up to 10 users). This license allows for the non‑production use of Veeam Backup for Microsoft Office 365 in your home lab without any feature limitations.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now