Results 1 to 4 of 4

Thread: Passing Table Name Dynamically in reports

  1. #1
    Expert Member
    Join Date
    Sep 2007
    Answers
    697

    Passing Table Name Dynamically in reports

    1)In a transaction file we have large volume of data. Is it advisable to split that table data year wise then copying it into diiferent tables?
    For example Loans2006, loans2007 likewise.
    2)If we split the table, based on that table there are number of reports. How to chage tablename in procedure dynamically based on the year taken as parameter?


  2. #2
    Moderator
    Join Date
    Jun 2007
    Answers
    2,074

    Re: Passing Table Name Dynamically in reports

    What do you mean by split the table. do you want to create partition.

    If you want to pass tablename dynamically then have to use EXECUTE IMMEDIATE.


  3. #3
    Expert Member
    Join Date
    Sep 2007
    Answers
    697

    Re: Passing Table Name Dynamically in reports

    Creating a new table for each year, tablename ends with year for example loans2006, loans2007 etc.


  4. #4
    Moderator
    Join Date
    Jun 2007
    Answers
    2,074

    Re: Passing Table Name Dynamically in reports

    Why not create index on date field and pass date range to the procedure. It iwill be easier to maintain the database.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
About us
Applying for a job can be a stressful and frustrating experience, especially for someone who has never done it before. Considering that you are competing for the position with a at least a dozen other applicants, it is imperative that you thoroughly prepare for the job interview, in order to stand a good chance of getting hired. That's where GeekInterview can help.
Interact