Solved

How to store math symbols and text in sql server 2005?

Posted on 2008-10-19
5
1,715 Views
Last Modified: 2012-05-05
I have an app that reads a text file containing course objectives and stores in SQL db.  When the asp.net 2.0 app reads the word file and converts to .txt.  The math symbols are lost.  This is bad but not tragic if I could update the db by editing the particular objective and inserting the math symbol.

How does one store math symbols along with text?
0
Comment
Question by:vstack
  • 2
  • 2
5 Comments
 
LVL 37

Accepted Solution

by:
momi_sabag earned 200 total points
ID: 22752355
if you use unicode data types (nvarchar) than you could store any symbol you want
you could also load the file directly into sql server and not going through the asp code at all and this way the symbols won't be lost
0
 
LVL 69

Assisted Solution

by:Qlemo
Qlemo earned 300 total points
ID: 22752363
You are limited to symbols included in a charset. There are many, e.g. greek letters like sigma. If you need more complex things you will have to store PDF, DOC or whatever directly as LOB (binary object type).
0
 

Author Comment

by:vstack
ID: 22753002
I hear you.  What we are trying to do is store the objectives so that instructors can map uploaded materials directly to them..  This way, other instructors can search on a particular objective to find appropriate materials, so storing the entire file would not work.

Possibly the unicode types might work.  But how do I create a 'sigma' character, for instance and send it along with, let's say, an update to a particular math objective...

The application is an asp.net 2.0 app.

Maybe this is not possible.

Thanks
0
 
LVL 69

Assisted Solution

by:Qlemo
Qlemo earned 300 total points
ID: 22768915
This select does give you several ways to retrieve those chars. To find out Unicode number of chars, you can use the charmap.exe.

select  N'', nchar(0x2211), nchar(8721), nchar(unicode(N''))

Open in new window

0
 

Author Comment

by:vstack
ID: 22769913
I'll check this out.  Thanks
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.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

by Mark Wills PIVOT is a great facility and solves many an EAV (Entity - Attribute - Value) type transformation where we need the information held as data within a column to become columns in their own right. Now, in some cases that is relatively…
So every once in a while at work I am asked to export data from one table and insert it into another on a different server.  I hate doing this.  There's so many different tables and data types.  Some column data needs quoted and some doesn't.  What …
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

828 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question