Skip to Main Content

IR

ABC
expected: Aexpected: Cexpected: B

Info

Not everybody likes pipelined table functions, but I do - when used in moderation of course, like most things :-)

And although I have been using pipelined table functions for years, it turns out it has a "feature" (illustrated in the example below) that completely caught me by surprise the other day.
When you fill your table of records, Oracle ignores the field/column names completely. Instead, it just fills them in the same order as in the (cursor) select. So if, like me, you happen to swap B and C without noticing, you can spend half an hour debugging something so small it's almost invisible...

Code

Region

Identification
Sequence
Title
Type
Source
Source Type
Region Source

Package

Package
Name
Source

Package Body

Package Body
Name
Source