dbTalk Databases Forums  

[BUGS] INSERT INTO ... SELECT

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


Discuss [BUGS] INSERT INTO ... SELECT in the mailing.database.pgsql-bugs forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Jiang Wei
 
Posts: n/a

Default [BUGS] INSERT INTO ... SELECT - 04-07-2004 , 10:19 AM






=>create table empty();

=>insert into empty default values;
=>insert into empty select * from empty;

server crash.





---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to majordomo (AT) postgresql (DOT) org

Reply With Quote
  #2  
Old   
Tom Lane
 
Posts: n/a

Default Re: [BUGS] INSERT INTO ... SELECT - 04-07-2004 , 01:52 PM






Jiang Wei <sdjiangwei (AT) sina (DOT) com> writes:
Quote:
=>create table empty();
=>insert into empty default values;
=>insert into empty select * from empty;
server crash.
Fixed, thanks for the report.


regards, tom lane


Index: execJunk.c
================================================== =================
RCS file: /cvsroot/pgsql-server/src/backend/executor/execJunk.c,v
retrieving revision 1.36
retrieving revision 1.36.4.1
diff -c -r1.36 -r1.36.4.1
*** execJunk.c 11 Aug 2003 20:46:46 -0000 1.36
--- execJunk.c 7 Apr 2004 18:46:20 -0000 1.36.4.1
***************
*** 262,273 ****
cleanTupType = junkfilter->jf_cleanTupType;
cleanLength = junkfilter->jf_cleanLength;
cleanMap = junkfilter->jf_cleanMap;
-
- /*
- * Handle the trivial case first.
- */
- if (cleanLength == 0)
- return (HeapTuple) NULL;

/*
* Create the arrays that will hold the attribute values and the null
--- 262,267 ----

---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to majordomo (AT) postgresql (DOT) org so that your
message can get through to the mailing list cleanly


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.