This month's discount Comprehensive Database Performance Health Check · Testimonials
SQLAuthority with Pinal Dave
Home
  • Consulting
    • Health Check
  • Free Videos
  • All Articles
    • AI
    • SQL Performance
    • SQL Tips and Tricks
    • Interview Questions and Answers
    • SQL Puzzle
    • SQL Video
    • SQLAuthority News
    • Personal
  • Books
  • Consulting
A woven motif remains intact on a source cloth and a separately framed copy.

PostgreSQL – Storing Unicode Characters is Easy

February 16, 2019
Pinal Dave
SQL Tips and Tricks
PostgreSQL, SQL Function, SQL String, Unicode

PostgreSQL varchar can store Unicode with suitable database and client encodings. My example stores ЯНВАРЬ, the Russian word for January.

Read More
Detailed leaf impression in wax beside smooth wax in a wider saucer

Unicode Lost: Finding Question Marks Left by varchar Conversion

June 22, 2014
Pinal Dave
SQL Tips and Tricks
SQL Collation, SQL String, Unicode

Customer names turn into question marks, and an nvarchar column does not bring them back. Here is how it happens and how to repair it.

Read More
A needle stitching a small red flower in cross stitch on linen stretched in a wooden embroidery hoop.

UNISTR and Unicode Escapes in SQL Server 2025

May 18, 2014
Pinal Dave
SQL Tips and Tricks
SQL Collation, SQL Function, SQL Server, SQL String, Unicode

Build Unicode strings with UNISTR in SQL Server 2025, compare NCHAR, and preserve accented letters, Hindi text, and emoji in storage.

Read More
An extended adjustable crutch stands beside a shorter adjusted crutch with intact supports

Sizing nvarchar Columns: How Long Should a Name Be?

April 19, 2014
Pinal Dave
SQL Tips and Tricks
SQL Datatype, SQL String, Unicode

A name fits the web form but fails in the table. Measure real lengths in characters and bytes before you choose a size.

Read More
A channel zester preserves one curled orange ribbon beside a heap of fine zest

Exporting CSV Files Without Losing Leading Zeros or Dates

December 11, 2013
Pinal Dave
SQL Tips and Tricks
CSV, Excel, SQL DateTime, Unicode

A postal code like 00501 turns into 501 in a spreadsheet. See where the zero is lost, how to build a correct CSV line, and why quotes alone do not help.

Read More
An open pea pod with five peas and an empty stretch at the end beside a red bowl.

LEN vs DATALENGTH: Trailing Spaces, Unicode Bytes and NULL

June 22, 2013
Pinal Dave
SQL Tips and Tricks
SQL Datatype, SQL Function, SQL Server, SQL String, Unicode

Compare LEN vs DATALENGTH for trailing spaces, Unicode, UTF-8, NULL, and MAX values before safely resizing SQL Server string columns.

Read More
Two hands holding a daisy chain of joined flowers, a single loose daisy on the grass beside them

Storing Emoji and Short Messages: nvarchar, UTF-8 and Length

April 9, 2012
Pinal Dave
SQL Tips and Tricks
SQL Collation, SQL Datatype, SQL Server, SQL String, Unicode

Store emoji safely with nvarchar or UTF-8 varchar, compare LEN and DATALENGTH, and choose message limits that fit full Unicode.

Read More
Previous 1 2 3 Next
  • Books
  • Testimonials
  • Privacy Policy

© 2006 – 2026 All rights reserved. pinal @ SQLAuthority.com