Firebird 2.0
PSQL Reference



Use the VARCHAR and NCHAR VARYING datatypes to hold text values of a variable length.


<varchar_type> ::=
     <varchar_keyword> ( <psql_integer> ) [ <char_set> ]
   | <nvarchar_keyword> ( <psql_integer> )

<varchar_keyword> ::=

<nvarchar_keyword> ::=

<char_set> ::=
   CHARACTER SET <identifier>


The VARCHAR(n) datatype contains text of varying length, up to a maximum of n characters. The maximum size is 32,767 bytes, which can be 10,992 to 32,767 characters, depending on the character size (1..3 bytes). You must supply n; there is no default to 1.

Firebird converts from variable-length character data to fixed-length character data by adding spaces to the value in the varying column until the column reaches its maximum length n. In the reverse conversion, trailing blanks are removed from the text.

The main advantage of using the VARCHAR(n) datatype are that it saves memory space during the execution of PSQL programs.


The below examples define a type to hold 32 characters in Unicode and a type to hold 128 characters in the ISO8859_1 character set (a.k.a. “latin1”):


See also

Character sets and collation orders in the SQL Reference Manual

previous page goto index next page

Legal information

User comments:

Contributed by WicBPPmchCIQFxCSFIS on 1 June 2008 09:45 AM


Contributed by Affinity on 1 June 2011 02:33 PM

I\'m not easily impressed. . . but that\'s imperssing me! :)

Contributed by crorkservice on 19 July 2014 06:49 AM

lEt2n0 Thank you ever so for you post. Much obliged.

Contributed by cheap backlinks on 19 July 2014 12:58 PM

354tRx Im obliged for the blog.Really looking forward to read more. Great.

Contributed by crorkz matz on 1 August 2014 11:10 AM

BlkKRV Very good post.Really looking forward to read more. Awesome.

Contributed by matz crorkz on 23 November 2014 07:37 PM

PFYzxZ It is best to take part in a contest for among the finest blogs on the web. I\'ll advocate this site!

Contributed by diamond crorkz on 17 December 2014 02:11 PM

CVSYKh Very informative post.Much thanks again. Really Great.

Contributed by crorkz on 16 January 2015 03:26 AM

waDsTS F*ckin\' tremendous things here. I am very glad to see your article. Thank you so much and i am taking a look forward to touch you. Will you kindly drop me a mail?

Contributed by crorkz on 16 January 2015 03:44 AM

6ylBsI Nice blog here! Also your web site loads up very fast! What web host are you using? Can I get your affiliate link to your host? I wish my site loaded up as fast as yours lol

Contributed by crork matt on 7 March 2015 10:00 AM

di1WzL Thanks - Enjoyed this update, how can I make is so that I get an email whenever there is a fresh update?

Contributed by matt daemon on 7 March 2015 10:37 AM

G9fVvt You made some respectable factors there. I looked on the internet for the problem and found most people will go along with together with your website.

Contributed by crorkz mattz on 7 April 2015 03:47 AM

LR3BCz Great write-up, I\'m regular visitor of one\'s site, maintain up the excellent operate, and It\'s going to be a regular visitor for a long time.

Contributed by crorkz mattz on 7 April 2015 04:54 PM

YoTOB6 Wow! This could be one particular of the most useful blogs We\'ve ever arrive across on this subject. Basically Wonderful. I am also an expert in this topic therefore I can understand your effort.

Contributed by crorkservice on fiverr on 5 May 2015 10:38 AM

C5RiL6 whoah this weblog is wonderful i love reading your posts. Keep up the great work! You already know, many persons are searching around for this information, you could help them greatly.

Contributed by crorkservice on 30 May 2015 03:57 PM

AjuWSb I have recently started a website, the information you provide on this website has helped me greatly. Thanks for all of your time & work.

Contributed by crorkz backlinks on 30 June 2015 12:17 PM

oJvesF I cannot thank you enough for the blog article.Thanks Again. Really Great.

Contributed by seo service on 1 July 2015 04:00 AM

JZ2COc wow, awesome blog article.Thanks Again. Will read on...

Contributed by matt crorkzz on 3 August 2015 06:10 PM

F14EJm Thanks again for the blog. Really Great.

Contributed by crork backlinks on 28 September 2015 01:32 AM

dlu9HK Spenz, by far the fastest inputs for cash. Free but iPhone/web only

Contributed by here on 28 September 2015 09:01 AM

p97dTm Normally I do not read post on blogs, however I would like to say that this write-up very pressured me to check out and do so! Your writing taste has been surprised me. Thank you, quite nice post.

Contributed by crorkservice on 16 October 2015 04:29 AM

UdkA2B Thanks-a-mundo for the blog article. Great.

Contributed by crorkservice fiverr on 16 October 2015 06:51 AM

T4vCcu I think this is a real great blog post.Really looking forward to read more. Great.

Contributed by fiverr seo on 16 October 2015 03:13 PM

LPkEGH That is a great tip especially to those fresh to the blogosphere. Simple but very accurate information Thanks for sharing this one. A must read post!

Contributed by fiverr crorkservice on 10 November 2015 12:29 AM

kpfZOJ Your style is unique in comparison to other people I ave

Contributed by crork seo on 10 November 2015 04:47 AM

LJjxb1 Way cool! Some extremely valid points! I appreciate you writing this write-up and the rest of the website is also very good.

Contributed by crork fiverr on 28 November 2015 10:43 AM

CKkEU4 You completed a few nice points there. I did a search on the subject and found nearly all persons will go along with with your blog.

Contributed by crorkservice fiverr on 28 November 2015 01:45 PM

1geZ73 you ave gotten an excellent weblog here! would you wish to make some invite posts on my weblog?

Contributed by Ezgi on 21 December 2015 09:31 AM

10 strategies On the way to Make Money Over the inretnet I\'m frequently requested by persons what\'s the greatest way to earn cash online? and there isn\'t truly one transparent solution .

Contributed by Tomy on 21 December 2015 12:41 PM

10 approaches To Churn out Cash Using the net I\'m releatedpy asked by persons what\'s the greatest method to make money on the internet? however there isn\'t rightly one transparent answer .

Contributed by hUqfHvNBU on 31 December 2015 01:43 PM


Contributed by XLVEfrtXb on 1 January 2016 06:32 PM


Contributed by cocoservice on 1 March 2016 04:08 PM

5OzNRf Whispering Misty So sorry you all miss the workshop!

Contributed by sophie fiverr on 5 April 2016 09:25 PM

pdBn9p There is definately a great deal to learn about this issue. I really like all the points you ave made.

Contributed by porn videos on 13 May 2016 09:06 PM

Thank you ever so for you blog post.Much thanks again. Really Great.

Contributed by big dildos on 16 May 2016 04:20 AM

i5XQZF Really enjoyed this article post.Much thanks again. Will read on

Contributed by huba buba on 4 August 2016 06:52 AM

px6ARK Im obliged for the blog post.Much thanks again. Will read on

Contributed by best nala pron on 10 October 2016 10:52 AM

zcDqAi This is one awesome blog article. Great.

Contributed by suba bob on 27 November 2016 07:54 AM

8FZLGD It is best to participate in a contest for one of the best blogs on the web. I will recommend this website!

Extend this topic - Post a comment

Your name:
Your comment:
This post is plain text
This post is html formatted