Results 1 to 2 of 2

Thread: SQL Dynamic

  1. #1
    Join Date
    Dec 2002
    Location
    Brazil
    Posts
    59

    Unanswered: SQL Dynamic

    Hi,

    Does someone have a dynamic sql script that makes a SELECT with dynamic 'from' clauses?
    I need a script where the table names in from clause are dynamic, I mean the table names come from a cursor using a variable.
    Well, I need this very urgent.
    If someone can help me, I will thank you!!!
    Nadia

  2. #2
    Join Date
    Aug 2003
    Location
    Where the Surf Meets the Turf @Del Mar, CA
    Posts
    7,776
    Provided Answers: 1
    At least two alternatives exist for you.
    1) EXECUTE IMMEDIATE
    http://download-west.oracle.com/docs...ynam.htm#13131
    2) DBMS_SQL
    http://download-west.oracle.com/docs...sql.htm#998100
    You can lead some folks to knowledge, but you can not make them think.
    The average person thinks he's above average!
    For most folks, they don't know, what they don't know.
    Good judgement comes from experience. Experience comes from bad judgement.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •