Normally refers to a variable length string data type.

learn more… | top users | synonyms

1
vote
1answer
15 views

Storage size for varchar length in Redshift

So, a lot of databases will store the length prefix for a varchar field in 1 byte if the length is less than 255, and 2 bytes if it is more. For example, the MySQL docs say: In contrast to CHAR, ...
1
vote
1answer
53 views

Rich text: VARCHAR, TEXT or BLOB in MySQL

Question: In my web application (php/MySQL) I will be saving rich text. This may be anything from a couple words to several pages length essay. I’m sure I could get away with using VARCHAR, TEXT or ...
1
vote
1answer
40 views

Shrinking VARCHAR with MODIFY: data alignment and potential for data loss

I'm using MODIFY to change (shrink) a number of VARCHAR fields of various lengths in various tables. In each case, the field is called ip and is a textual representation of an IPv4 or IPv6 address. To ...
0
votes
1answer
49 views

Does PostgreSQL have a variable character storage layer that optimizes storage space by automatic dedupe?

My application has a Product and a Purchased table. The Purchased table includes a full copy of the Product row at time of purchase, so that, even if a product name or description was changed, the ...
0
votes
1answer
120 views

Implicitly (or proxy) convert to Nvarchar on incoming queries from legacy or 3rd party applications

We have a 3rd party application of which we don't have the source code. This application executes queries on our database without using the "N" prefix before literal strings. It does this in inserts ...
0
votes
0answers
51 views

Null in Varchar datatype

I am using a SQL Server database. If NULL value is inserted to a VARCHAR datatype column, what will be the memory size used for the column?
0
votes
0answers
25 views

Ascii Symbols are Shown In varchar and Datetime Column Values of Mysql

Some rows in my database are shown in binary format. DateTime values are shown as below in Sqlyog. DC1203-68-58 51:18:72 Æ420-94-57 38:13:76 \722-49-30 63:17:35 ETB801-61-42 37:69:60 When i ...
0
votes
0answers
49 views

Performance implications of mixing VARCHAR and CHAR fields in MySQL Table

I read the following answers in this forum: What is the performance impact of using CHAR vs VARCHAR on a fixed-size field? MySQL: Does the order of the fields in a table make a difference in ...