Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7868349
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T00:58:22+00:00 2026-06-03T00:58:22+00:00

So I just created this trigger for my tables: CREATE OR REPLACE PROCEDURE POPULATE_ACTOR_QUOTES

  • 0

So I just created this trigger for my tables:

CREATE OR REPLACE 
PROCEDURE POPULATE_ACTOR_QUOTES (id_actor char)
AS
   CURSOR quote_recs IS
      SELECT m.title, 
             m.year, 
             r.roleName,
             q.quotechar 
        from quote q, 
             role r, 
             rolequote rq,  
             actor a, 
             movie m
       where rq.quoteID = q.quoteID
         AND rq.roleID = r.roleID
         AND r.actorID = a.actorID
         AND r.movieID = m.movieID
         AND a.actorID = id_actor;
BEGIN
   FOR row IN quote_recs 
   LOOP
      INSERT INTO table(
      SELECT quotes
        FROM actor_quotes aq
       WHERE aq.actorId = id_actor)
      VALUES(
         ACTOR_QUOTE_TYPE(row.title, row.year, row.roleName, row.quotechar)
      );
   end loop;
END POPULATE_ACTOR_QUOTES;
/

I now want to unest the table QUOTES for any ACTORID by using a query similar that unnests the QUOTES table and lists all four data items inside it.

This was the original table schema

CREATE TABLE ACTOR_QUOTES (
   ACTORID CHAR(5),
   QUOTES  AQ_NT
)  
NESTED TABLE QUOTES STORE AS ACTOR_QUOTES_NT
/
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T00:58:23+00:00Added an answer on June 3, 2026 at 12:58 am

    You can do the same using TABLE function

      SELECT REC.*
    
      FROM ACTOR_QUOTES A,TABLE(A.QUOTES) REC
    

    For reference please check

    http://psoug.org/reference/nested_tab.html

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Just created an acc on SO to ask this :) Assuming this simplified example:
I just created a user control. This control also makes use of my static
I just installed Eclipse. The Eclipse created the workspace folder. In this folder I
I'm just learning MongoDB and MongoMapper. This is on Rails 3. I created a
I just create a new repo https://github.com/tolbard/ember-moving . In this repo I extend the
I am trying to create this tooltip sample for my wordpress it works just
This is driving me wild with frustration. I am just trying to create a
This is just a question is it possible to create a hr tag in
This is just a quick question to understand correctly what happens when you create
I have tow tables concept_access and concept_access_log. I want to create a trigger that

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.