当前位置:网站首页>The difference between nvarchar and varchar
The difference between nvarchar and varchar
2022-06-22 15:57:00 【Let it be~】
1、varchar yes Not Unicode Variable length type ,nvarchar yes Unicode Variable length type .
2、varchar and nvarchar The maximum length of is different ,nvarchar The length of must be set to 1 and 4000 Between .varchar The length setting of must be 1 and 8000 Between .
3、varchar The number of bytes that can be stored is its length .nvarchar The number of bytes that can be stored is of its length 2 times .
difference :
① From the storage mode ,nvarchar Is in accordance with the character Stored ,varchar Is in accordance with the byte Stored .
② In terms of storage ,varchar It saves space , Because the size of storage is the actual length of bytes , and nvarchar Double byte storage .
③ On use , If the stored content is English characters without Chinese characters or other languages , It is recommended to use varchar, The use of Chinese characters nvarchar, because nvarchar The use of Unicode code , Uniform coding , It will reduce the probability of garbled code .
summary :
Today's devices , The size of storage space has been unlimited . Regardless of the scope of the language , And the range of storage space ,nvarchar Have a great advantage .
It is recommended to select..., as the database for the project nvarchar.
Link to the original text :https://blog.csdn.net/Sunshineoe/article/details/111715231
边栏推荐
- Promouvoir l'adaptation compatible et permettre le développement collaboratif du Service Express adaptatif gbase en mai
- 快速排序quick_sort
- 问一下想获取到sqlserver的start_lsn有好的办法吗?
- Wechat applet avatar pendant production
- 小程序开发----自定义有效期缓存
- C语言学习-17-函数作为参数传入函数
- Community article | mosn building subset optimization ideas sharing
- pymssql模块使用指南
- 建议自查!MySQL驱动Bug引发的事务不回滚问题,也许你正面临该风险!
- mysql的concat()函数如何用
猜你喜欢

Devsecops: best practices for ci/cd pipeline security

(pytorch advanced path 2) word embedding and position embedding

pymssql模块使用指南

C language learning -17- function is passed in as a parameter

百行代码实现基于Redis的可靠延迟队列

Runmaide medical passed the hearing: Ping An capital was a shareholder with a loss of 630million during the year

Uni develops wechat applet to customize automatic camera detection (portrait + ID card)

标准化、最值归一化、均值归一化应用场景的进阶思考

【LeetCode】9、回文数

快速玩转CI/CD图形化编排
随机推荐
Discover the number of media new users can insert
基于最小化三维NDT距离的快速精确点云配准
[Newman] postman generates beautiful test reports
再次认识 WebAssembly
Advanced thinking on application scenarios of standardization, maximum normalization and mean normalization
Sdvo:ldso+ semantics, direct French Slam (RAL 2022)
Hello, big guys. Error reporting when using MySQL CDC for the first time
Scala语言学习-04-函数作为参数传入函数-函数作为返回值
MongoDB在腾讯零售优码中的应用
New load balancing webclient CRUD
Ultimate efficiency is the foundation for the cloud native database tdsql-c to settle down
FPGA collects DHT11 temperature and humidity
壹连科技冲刺深交所:年营收14亿 65%收入来自宁德时代
Luogu p2466 [sdoi2008] Sue's small ball solution
得物App数据模拟平台的探索和实践
How can ordinary people make 1million yuan a year?
FPGA采集DHT11温湿度
小程序开发----自定义有效期缓存
C # implements insertion sorting
信创研究:国产数据库聚焦信创市场,华为Gauss有望成为最强