Wrox Programmer Forums
|
SQL Server 2005 General discussion of SQL Server *2005* version only.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the SQL Server 2005 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old August 25th, 2007, 01:22 AM
Registered User
 
Join Date: Aug 2007
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default savingObjectsInSQlDatabase

HI my friends
I want to save objects in tables of my database but i dont know how to do it.i read some articles about serialization but i dont see , i want to know by using serialization classes i will use odbc ? and please guide me to understand what to do

 
Old August 26th, 2007, 01:54 PM
planoie's Avatar
Friend of Wrox
 
Join Date: Aug 2003
Posts: 5,407
Thanks: 0
Thanked 16 Times in 16 Posts
Default

Serialization is not a database operation so you won't use ODBC or any other database specific classes to perform the actual serialization.

You will use the classes found under the System.Xml.Serialization Namespace. You can create an XmlSerializer Class specifying your class type and use it to de/serialize an instance of the class to a string of XML which you can store using standard character storage methods into the database.

-Peter









Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.