Results 1 to 11 of 11
  1. #1
    Join Date
    Jul 2010
    Posts
    5

    Unanswered: .prc files and how to run them...

    Greetings, I am not a DB guy but I'm going to ask this on behalf of our IT/Dbase person. I have a couple of questions that I'm hoping someone can help me with.

    Here is the scenario, we have recently brought a copy of a database to our own servers (we had previously accessed this database remotely.)

    There is a year end process we must follow in concert with group that holds the database that we formerly accessed remotely. We must follow the exact same steps as them for year end updates so that our two databases match at the end of the year end up date.

    Part of the year end processing is done using the vendor software that is used in conjunction with the database however there are some custom changes made to the database via scripts. These scripts have been provided to us in the form of seven files with the .prc extension. (.prc is called a process file I take it?)

    The people who have provided us with the .prc files have really not given us great documentation as to how these are run to effect the updates of the database. This is essentially my question. How does one run these .prc files against the database? Does one go into an Oracle database administrator and run them there? Something run from a command line?

    (As I said I'm not a database person but I'm just looking for some guidance I can pass along to our dbase admin on this project.)

    Thanks in advance for any help.

  2. #2
    Join Date
    Aug 2003
    Location
    Where the Surf Meets the Turf @Del Mar, CA
    Posts
    7,776
    Provided Answers: 1
    >These scripts have been provided to us in the form of seven files with the .prc extension. (.prc is called a process file I take it?)

    Not Oracle "standard" naming convention.

    Does your Operating System have a name & version?

    post content of 1 of these *prc files
    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.

  3. #3
    Join Date
    Nov 2003
    Posts
    2,935
    Provided Answers: 12
    Quote Originally Posted by TimMcD View Post
    GThese scripts have been provided to us in the form of seven files with the .prc extension. (.prc is called a process file I take it?)
    Could also be a Pro*C file
    Which is essentially a C program that needs to be run through the Pro*C precompiler.

  4. #4
    Join Date
    Feb 2006
    Posts
    173
    Provided Answers: 1
    Sounds like, er, um, reads like its could be a oracle procedure. Does the source member contain SQL statements?

    For example, Is the first non-comment statement something like:
    Code:
    create or replace procedure xxxxxxxxxxxxx
    or
    Is the first non-comment statement:
    Code:
    Declare
    But like anacedent said, post an example.

  5. #5
    Join Date
    Jul 2010
    Posts
    5
    Well if I right click on one of the files and begin to 'open with' it says 'You are attempting to open a file of type 'SQL server replication Snapshot Procedure Script (.prc)' This is to be applied to an Oracle database though.

  6. #6
    Join Date
    Aug 2003
    Location
    Where the Surf Meets the Turf @Del Mar, CA
    Posts
    7,776
    Provided Answers: 1
    >it says 'You are attempting to open a file of type 'SQL server replication Snapshot Procedure Script (.prc)' >This is to be applied to an Oracle database though.
    I don't think so.
    Those files are worthless/useless to Oracle.
    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.

  7. #7
    Join Date
    Jan 2003
    Location
    Massachusetts
    Posts
    5,800
    Provided Answers: 11
    Windows is guessing. If you change the extension to .txt, it would not put up so much of a fuss. My guess is that these are stored procedure scripts. Open one in Notepad. You should see "CREATE OR REPLACE...." in the first few lines, if I am right. If not, well, let's have a look at the first few lines.

  8. #8
    Join Date
    Jul 2010
    Posts
    5
    Quote Originally Posted by anacedent View Post
    >it says 'You are attempting to open a file of type 'SQL server replication Snapshot Procedure Script (.prc)' >This is to be applied to an Oracle database though.
    I don't think so.
    Those files are worthless/useless to Oracle.
    Thus my frustration with the people that have sent me the files and their lack of documentation other than saying 'Run these scripts.'

  9. #9
    Join Date
    Jul 2010
    Posts
    5
    Quote Originally Posted by MCrowley View Post
    Windows is guessing. If you change the extension to .txt, it would not put up so much of a fuss. My guess is that these are stored procedure scripts. Open one in Notepad. You should see "CREATE OR REPLACE...." in the first few lines, if I am right. If not, well, let's have a look at the first few lines.
    Here is the 1st part of one of the prc files.

    CREATE OR REPLACE PROCEDURE RECAPPOWNER."CST_YREND_CALC_AND_STORE_FCI" AS
    /************************************************** ********************
    Find value of new FCI field (to be created by sysadmins) in table TBLDETAILDEF.
    Last year (2006), the field was D290. 2007 , the field is D438 in production.
    D39 is replacement value.

    2008-03-10 LT Replaced reference to VW_RPT_FAC_FCI to excluded completed
    events in the calculation of the FCI
    2008-04-03 LT New FCI field is D451
    2009-04-07 LT New FCI field is D453 - 5 Year FCI (Mar-31-2009)
    2010-04-09 LT New FCI field is D457 - 5 Year FCI (Mar-31-2010)
    TotalCost is summation of NOT APPROVED events only
    ************************************************** ****************************/

    CURSOR crASSET IS
    SELECT T3.TREENODEID,
    TOTALCOST
    FROM TBLDETAILVALUE_3 T3
    JOIN --VW_RPT_FAC_FCI
    (SELECT T3.TREENODEID,
    Sum(D77) AS TOTALCOST
    FROM TBLDETAILVALUE_4 T4,
    TBLTREENODEPARENTLOCAL TP,
    TBLTREENODEPARENTLOCAL TPM,
    TBLTREENODEPARENTLOCAL TP1,
    TBLDETAILVALUE_1 T1,
    TBLTREENODEPARENTLOCAL TPT,
    TBLDETAILVALUE_3 T3
    --WHERE (D6 < GETFISCAL(Sysdate)+4)
    --AND (D6 >= GETFISCAL(Sysdate)-1)

  10. #10
    Join Date
    Jan 2003
    Location
    Massachusetts
    Posts
    5,800
    Provided Answers: 11
    Yep. These are scripts for procedures. You can run these using SQLPLUS, or any of the developer tools. As for how you should log into the Oracle instance in order to run them is going to be a question for your IT/Dbase person.

  11. #11
    Join Date
    Jul 2010
    Posts
    5
    Thanks Mcrowley I'll pass that onto the DB admin person.

Posting Permissions

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