-
To store m³ in a SQL Server database and print it out, the method is as follows:
1) Set the data type of the corresponding field in the database to nchar or nvarchar type.
2) Get m³ from Excel, copy and paste it into the control that receives the data (TextBox, DataGridView, etc.). Just save it.
Note: 1) The difference between nchar, nvarchar and char, varchar
There is an 'n' in front of nchar and nvarchar, which means that characters of Unicode data type are stored. The Unicode character set was created to solve the problem of different bytes required to store English and Chinese characters (one byte for the former and two bytes for the latter). The Unicode character set all uses two bytes. Both can store up to 4000 characters each, regardless of Chinese characters or English.
Both char and varchar store characters of non-Unicode data types. It can store up to 8000 English characters and 4000 Chinese characters.
Therefore, if it is pure English and numbers, use char/varchar; if there are Chinese characters in the data, you can use nchar/nvarchar.
2) Get m³ from WORD and EXCEL
WORD: Achieved by setting superscript. Enter m, press "shift"+"Ctrl"+"+", enter 3, press "shift"+"Ctrl"+"+" again to return to the normal state. The m³ format obtained by this method will disappear (change to m3) when copied to EXCEL.
EXCEL: small keyboard, ALT+179. Or enter m, insert --> symbol, find superscript 3, and click [Insert]. The m³ format obtained by this method will not disappear when copied to WORD.