Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 Saving HTML To Sql

Author  Topic 

Mauricio Moreno
Starting Member

18 Posts

Posted - 2007-10-25 : 15:11:55
hello,

Im not really sure if this is the right thing to do. But i want to save a copy of the html from my invoice to sql so that i can keep a history of the invoices in case their are changes done to them. Anybody know what would be the best way to do this?

Thank you,

~ Mauricio

dinakar
Master Smack Fu Yak Hacker

2507 Posts

Posted - 2007-10-25 : 15:19:05
you can use varchar datatype.. its treated as any other string..

Dinakar Nethi
************************
Life is short. Enjoy it.
************************
http://weblogs.sqlteam.com/dinakar/
Go to Top of Page

jackv
Master Smack Fu Yak Hacker

2179 Posts

Posted - 2007-10-26 : 02:53:35
You could look at ntext or if the invoice has got more characters than VARCHAR can hold , you will need to set up your procedures to store across multiple rows

Jack Vamvas
--------------------
Search IT jobs from multiple sources- http://www.ITjobfeed.com
Go to Top of Page

Kristen
Test

22859 Posts

Posted - 2007-10-26 : 06:15:33
"Im not really sure if this is the right thing to do"

Sounds reasonable to me.

An alternative would be to store the Invoice in a "file" and a path/filename to that in the database. Note that storing large objects in the database will bloat the backups etc., so it is usually preferred to store such objects in the file system, all other things being equal!

Kristen
Go to Top of Page
   

- Advertisement -