dbTalk Databases Forums  

Re: [BUGS] Fault when return strings over 256 characters in PLpgSQL

mailing.database.pgsql-bugs mailing.database.pgsql-bugs


Discuss Re: [BUGS] Fault when return strings over 256 characters in PLpgSQL in the mailing.database.pgsql-bugs forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Neil Conway
 
Posts: n/a

Default Re: [BUGS] Fault when return strings over 256 characters in PLpgSQL - 03-09-2005 , 05:58 AM






cathy.hemsley (AT) powerconv (DOT) alstom.com wrote:
Quote:
I have a PLpgSQL function that returns a string (varchar): if this string
is over 256 characters long then the last three characters are corrupted:
replaced by the string ' (.'
I'm skeptical: there is nothing special about 256 characters as far as
the varchar implementation is concerned, nor is the string ' (.' of any
significance.

Running your function (albeit on Linux) yields:

neilc=# select testconverttousername();

testconverttousername


--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

12345678123456781234567812345678123456781234567812 34567812345678123456781234567812345678123456781234 56781234567812345678123456781234567812345678123456 78123456781234567812345678123456781234567812345678 12345678123456781234567812345678123456781234567812 34567888
(1 row)

i.e. what one would expect.

-Neil

---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faq


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.