Re: [HACKERS] Re: [QUESTIONS] impossible insert data into VARCHAR
От | jwieck@debis.com (Jan Wieck) |
---|---|
Тема | Re: [HACKERS] Re: [QUESTIONS] impossible insert data into VARCHAR |
Дата | |
Msg-id | m0y0UZ5-000BFRC@orion.SAPserv.Hamburg.dsh.de обсуждение исходный текст |
Ответ на | Re: [HACKERS] Re: [QUESTIONS] impossible insert data into VARCHAR ("Thomas G. Lockhart" <lockhart@alumni.caltech.edu>) |
Ответы |
Re: [HACKERS] Re: [QUESTIONS] impossible insert data into VARCHAR
|
Список | pgsql-hackers |
> > Jan Wieck wrote: > > > > [... quoting level exceeded ...] > > > > ARRRRG - then next problem with VARSIZE - damn thing. > > > > This time it's during the parser (gdb told me). varcharin() > > is called with a atttypmod of 0 causing a palloc() of 0 > > bytes. How should a VARCHAR type whithout a specified length > > behave? Is this type 1 character or a variable size up to > > 4096? > > It should allow any length (up to the implementation maximum of 4096). The usage is not defined for SQL92, > unlike the case for "char" with no explicit size which defaults to one. > Could be hacked into varcharin(). If the test on atttypmod is changed from "!= -1" into "> 0" it works that way. Don't have the time right now to run a regression test, but some typed queries with select into t values ... and select into t select ... worked O.K. Until later, Jan -- #======================================================================# # It's easier to get forgiveness for being wrong than for being right. # # Let's break this rule - forgive me. # #======================================== jwieck@debis.com (Jan Wieck) #
В списке pgsql-hackers по дате отправления: