Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8596717
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T00:44:46+00:00 2026-06-12T00:44:46+00:00

i am trying to know the data is getting loaded in single byte or

  • 0

i am trying to know the data is getting loaded in single byte or double byte data, please find the column data as pasted below:

حمد بخش مبار

select CTD_BENAC_NAME 
from NAME_TRAN_DETAILS 
where CTD_SEND_INS_REF ='FTSCWOK11074799'

it will gives the arabic data in the result, now i just want to know data is getting loaded in Single byte or double byte in Sqlserver, kindly advice how can i decide?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T00:44:47+00:00Added an answer on June 12, 2026 at 12:44 am

    It depends on the data type of that column. In SQL Server there are two kinds of character data types — regular and Unicode. Regular data types which are CHAR and VARCHAR. Unicode data types like NCHAR and NVARCHAR. For regular characters SQL Server uses one byte of storage for each character, whereas Unicode characters NVARCHAR uses two bytes per character.

    You can also get the number of bytes used by a string using DATALEGNTH or LEN like so:

    SELECT DATALENGTH(inputstring); 
    

    As I explained later, If this inputstring is of type NVARCHAR or N'string' DATALENGTH will give you the number of bytes. Whereas the LEN will give you the nuber of characters in a sting and that length is not necessarily the number of bytes.

    Note that, another difference between LEN and DATALENGTH is that the LEN excludes trailing blanks while the DATALENGTH doesn’t. Also, be careful with theses functions because it would depend in the collation because Varchar = single byte is not always true as pointed out by @MartinSmith comment below.

    Here is a demo for that, you can try it yourself.

    DEMO

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to retrieve data from an Entity in Core Data where I know
I'm trying to display data from a database and I want to know what
i am trying to get some data, but i dont know how can i
Anybody know if it's possible? I'm trying to get the data by using the
I'm trying to find a best practice for getting values for a databound control.
I'm trying to get the min/max for each column in a large data frame,
I'm trying to pull data into flash using JSON but i keep getting this
I tabController app with uitableview getting NSURLconnection data and trying to display it. I
I am trying to know if a user is guest using Yii::app()->user->isGuest but I
I was trying to know how // and can be passed into a macro

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.