GeekInterview.com
  I am new, Sign me up!
 
GeekInterview.com  >  Tech FAQs  >  PL/SQL
Go To First  |  Previous Question  |  Next Question 
 PL/SQL  |  Question 37 of 166    Print  
what are pipelined functions . illustrate by example

  
Total Answers and Comments: 1 Last Update: August 07, 2006     Asked by: navneet 
  
 Sponsored Links

 
 Best Rated Answer

No best answer available. Please pick the good answer available or submit your answer.
August 07, 2006 00:41:07   #1  
Gupta        

RE: what are pipelined functions . illustrate by examp...

A table function is a function that returns an entire set of rows and can be queried directly from the within a SQL statement as if it were true database table. Whereas pipeline function is similar but returns the data as it is constructed rather than all at once.

e.g.

CREATE TYPE MyType AS OBJECT (
field1 Number
field2 Varchar2(50);

CREATE TYPE MyTypeList AS TABLE OF MyType;

CREATE OR REPLACE FUNCTION PipelineMe
RETURN MytypeList PIPELINED AS V_MyType Mytype;
BEGIN
FOR V_count IN 1..20 LOOP
V_Mytype : MyType (V_count ' Row ' || V_count);
PIPE ROW (V_Mytype);
ENDLOOP;
RETURN;
END PipelineMe;


 
Is this answer useful? Yes | No

 Related Questions

Plz clarryfy this.Scinario is whether we can use out mode in functions?.I thought it's not possible. But in interview they are asking this.if i am telling no,they are not accepting me.Plz clarify this anyone.
Read Answers (9) | Asked by : George Suresh

What is the Scalar Data type in PL/SQL?what is the forward decleration in packages?what is the usage of IN,OUT,INOUT parameters in Procedures or functions?
Read Answers (5) | Asked by : chiranjeevi reddy

How to query to know, that dbms_rowid package contains ROWID_OBJECT, rowid_block_number ,etc procedures or functions in it.

Latest Answer : A table function is a function that returns an entire set of rows, and can be queried directly from the within a SQL statement, as if it were true database table. Whereas pipeline function is similar, but returns the data as it is constructed rather than ...
Read Answers (1) | Asked by : navneet

What are analytical functions and how are they used? 
Latest Answer : Analytic functions compute an aggregate value based on a group of rows. They differ from aggregate functions in that they return multiple rows for each group. The group of rows is called a window and is defined by the analytic_clause.for example:SQL> ...
Read Answers (1) | Asked by : Hsingh85

How to return more than one row through functions? Explain with example. 
Latest Answer : create or replace function f1 return sys_refcursor as r1 sys_refcursor; begin open r1 for select * from emp; return(r1); end; call the function as: select f1 from dual; Thanks & Regards RAJIV GUPTA (ORACLE CONSULTANT) YOGIK TECHNOLOGIES ...


 Sponsored Links

 
Related Articles

Microsoft AJAX Library - Anonymous Functions

Anonymous Functions Anonymous functions can be created adhoc and used instead of a named function Although this can hinder readability when the function is more complex you can do this if you don t intend to reuse a function s code In the following example we pass such an anonymous function to Displ
 

Microsoft AJAX Library - Functions as Variables

Functions as Variables In JavaScript functions are first class objects This means that a function is regarded as a data type whose values can be saved in local variables passed as parameters and so on For example when defining a function you can assign it to a variable and then call the function thr
 

Microsoft AJAX Library - JavaScript Functions

JavaScript Functions A simple fact that was highlighted in the previous chapter but that is often overlooked is key to understanding how objects in JavaScript work code that doesn t belong to a function is executed when it s read by the JavaScript interpreter while code that belongs to a function is
 

ERPAdvantages for Management Functions

ERP Advantages for Management Functions ERP management systems provide a technology platform in which organizations can integrate and coordinate their main internal business processes They use this to fight against the problem of the organizational inefficiency brought on by the use of different sys
 

C++ Static Functions

C Static Functions Static member functions have a class scope and they do not have access to the this pointer of the class When a member is declared as static a static member of class it has only one data for the entire class even though there are many objects created for the class The main usage of
 

C++ Virtual Functions

C Virtual Functions What are Virtual Functions Virtual as the name implies is something that exists in effect but not in reality The concept of virtual function is the same as a function but it does not really exist although it appears in needed places in a program The object oriented programming la
 

C++ Inline Functions

C Inline Functions In this C tutorial you will learn about Inline function what is inline function reason for the need of inline function what happens when an inline function is written general format of inline function explained with example mosgoogle center What is Inline Function Inline functions
 

String handling functions

What is the string handling functions present in header file <string.h>? There are number of string handling functions present in string.h. In other words if a programmer uses any of the function present in string.h then they must include the header file as #include <string.h&am
 

SQL Functions

SQL Programming Overview In the article SQL Programming, we discussed creating the “Hello, World!” function in PostgreSQL, MySQL, and Oracle. In this article, we take “Hello, World!” one step farther and introduce the parts of a function and how to pass parame
 

JavaScript Functions

JavaScript Functions In this JavaScript tutorial you will learn about JavaScript functions and how to create them mosgoogle center What is a function Function is a block of code that can be reused as and when needed at various places The function executes whenever it is called JavaScript Functions H
 

About Us -  Privacy Policy -  Terms and Conditions -  Contact -  Ask Question -  Propose Category -  Site Updates 

Copyright © 2005 - 2009 GeekInterview.com. All Rights Reserved

Page copy protected against web site content infringement by Copyscape