[x]
Posted via EE Mobile

Search, ask, and monitor your questions on the go with EE Mobile. Visit Experts Exchange from your mobile device and never be out of touch again.

Question
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

8.5

Can't find the cause of the PL/SQL Compilation Error

Asked by geeta_m9 in PL / SQL, Oracle 10.x

Tags: Oracle PL/SQL

When I compile the following package, I get the following compilation error, but I can't determine what is causing the error. Please help!

Warning: Package Body created with compilation errors.

09:37:34 PPRD> show errors
Errors for PACKAGE BODY EXPORT_TOOL:

LINE/COL ERROR
-------- -----------------------------------------------------------------
32/46    PLS-00103: Encountered the symbol "(" when expecting one of the
         following:
         := . ) , @ % default character
         The symbol ":=" was substituted for "(" to continue.

32/74    PLS-00103: Encountered the symbol "(" when expecting one of the
         following:
         := . ) , @ % default character
         The symbol ":=" was substituted for "(" to continue.

64/45    PLS-00103: Encountered the symbol "(" when expecting one of the

LINE/COL ERROR
-------- -----------------------------------------------------------------
         following:
         := . ) , @ % default character
         The symbol ":=" was substituted for "(" to continue.

64/73    PLS-00103: Encountered the symbol "(" when expecting one of the
         following:
         := . ) , @ % default character
         The symbol ":=" was substituted for "(" to continue.

1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
39:
40:
41:
42:
43:
44:
45:
46:
47:
48:
49:
50:
51:
52:
53:
54:
55:
56:
57:
58:
59:
60:
61:
62:
63:
64:
65:
66:
67:
68:
69:
70:
71:
72:
73:
74:
75:
76:
77:
78:
79:
80:
81:
82:
83:
84:
85:
86:
87:
88:
89:
90:
91:
92:
93:
94:
95:
96:
97:
98:
99:
100:
101:
102:
103:
104:
105:
106:
107:
108:
109:
110:
111:
112:
113:
114:
115:
116:
117:
118:
119:
120:
121:
122:
123:
124:
125:
126:
127:
128:
129:
130:
131:
132:
133:
134:
135:
136:
set scan off
 
CREATE OR REPLACE PACKAGE export_tool AS
 
  FUNCTION get_prereq(p_subj_code in VARCHAR2(20),P_crse_numb in VARCHAR2(20)) RETURN clob;
  FUNCTION get_coreq(p_subj_code in VARCHAR2(20),P_crse_numb in VARCHAR2(20)) RETURN clob;
  PROCEDURE p_print_data;
 
END export_tool;
/
show errors
 
WHENEVER SQLERROR CONTINUE
DROP PUBLIC SYNONYM export_tool;
WHENEVER SQLERROR EXIT ROLLBACK
REM *** BEGINNING OF GURMDBP MODS ***
REM GRANT EXECUTE ON export_tool TO PUBLIC
WHENEVER SQLERROR CONTINUE
REM start gurgrtb export_tool
WHENEVER SQLERROR EXIT ROLLBACK
REM *** END OF GURMDBP MODS ***
create public synonym export_tool for export_tool;
grant execute on export_tool to www_user;
set scan off
 
CREATE OR REPLACE PACKAGE BODY export_tool AS
 
    CURSOR cv_cursor_data IS
          SELECT distinct CONCAT(a.SCBCRSE_SUBJ_CODE,a.SCBCRSE_CRSE_NUMB) AS ID, a.SCBCRSE_TITLE, a.SCBCRSE_CREDIT_HR_LOW, f.stvdept_desc, get_prereq(a.SCBCRSE_SUBJ_CODE,a.SCBCRSE_CRSE_NUMB), get_coreq(a.SCBCRSE_SUBJ_CODE,a.SCBCRSE_CRSE_NUMB)
          FROM  SCBCRSE a, SCBCRKY, STVDEPT f
          WHERE a.SCBCRSE_EFF_TERM = (SELECT MAX(b.SCBCRSE_EFF_TERM)
                                     FROM SCBCRSE b
                                     WHERE b.SCBCRSE_CRSE_NUMB = a.SCBCRSE_CRSE_NUMB
                                     AND b.SCBCRSE_SUBJ_CODE = a.SCBCRSE_SUBJ_CODE
                                     AND b.SCBCRSE_EFF_TERM <= 200910)
          AND   a.SCBCRSE_SUBJ_CODE = SCBCRKY_SUBJ_CODE
          AND   a.SCBCRSE_CRSE_NUMB = SCBCRKY_CRSE_NUMB
          AND   a.SCBCRSE_CSTA_CODE = 'A'
          AND   a.SCBCRSE_CRSE_NUMB <> '000'
          AND   a.SCBCRSE_CRSE_NUMB <> '001'
          AND   a.SCBCRSE_CRSE_NUMB <> '002'
          AND   a.SCBCRSE_CRSE_NUMB <> '998'
          AND   a.SCBCRSE_CRSE_NUMB <> '999'
          AND   a.SCBCRSE_DEPT_CODE = f.stvdept_code
          AND   SCBCRKY_TERM_CODE_START <= 200910
          AND   SCBCRKY_TERM_CODE_END >= 200910
          ORDER BY ID;
          
   v_id VARCHAR2;
   v_title VARCHAR2;
   v_credit VARCHAR2;
   v_dept VARCHAR2;
   v_prereq VARCHAR2(4000);
   v_coreq VARCHAR2(4000);
   
  -- Function to get course PRE-REQS
  FUNCTION get_prereq(p_subj_code in VARCHAR2(20),p_crse_numb in VARCHAR2(20)) 
  RETURN clob IS
      
       CURSOR p_cursor IS
             SELECT CONCAT(b.SCRRTST_SUBJ_CODE_PREQ,b.SCRRTST_CRSE_NUMB_PREQ)
             FROM SCRRTST b
             WHERE p_subj_code    = b.SCRRTST_SUBJ_CODE
             AND p_crse_numb        = b.SCRRTST_CRSE_NUMB
             AND b.SCRRTST_CONCURRENCY_IND <> 'Y';
             
       l_value   p_cursor%ROWTYPE;
       l_result  clob;
       p_del varchar2 := ' ';
       
  BEGIN
      OPEN p_cursor;
      
      IF l_result IS NOT NULL THEN
              l_result := l_result || p_del;
      END IF;
      
      LOOP
          FETCH p_cursor INTO l_value;
          EXIT WHEN p_cursor%NOTFOUND;
          
          l_result := l_result || l_value;
      END LOOP;
      CLOSE p_cursor;
      RETURN l_result;
  END get_prereq;
 
  -- Function to get courses CO-REQS
  FUNCTION get_coreq(p_subj_code in VARCHAR2(20),p_crse_numb in VARCHAR2(20))
  RETURN clob IS
       
       CURSOR p_cursor2 IS
             SELECT CONCAT(d.SCRRTST_SUBJ_CODE_PREQ,d.SCRRTST_CRSE_NUMB_PREQ)
             FROM SCRRTST d
             WHERE p_subj_code = d.SCRRTST_SUBJ_CODE
             AND p_crse_numb = d.SCRRTST_CRSE_NUMB
             AND d.SCRRTST_CONCURRENCY_IND = 'Y';
             
       l_value2   p_cursor2%ROWTYPE;
       l_result2  clob;
       p_del2 VARCHAR2 := ' ';
             
  BEGIN
      
      IF l_result2 IS NOT NULL THEN
              l_result2 := l_result2 || p_del2;
      END IF;
          
      OPEN p_cursor2;
      LOOP
          FETCH p_cursor2 into l_value2;
          EXIT WHEN p_cursor2%NOTFOUND;
          
          l_result2 := l_result2 || l_value2;
      END LOOP;
      CLOSE p_cursor2;
      RETURN l_result2;
  END get_coreq;
  
  -- Output data
  PROCEDURE p_print_data 
  AS      
  BEGIN  
      OPEN cv_cursor_data;
      LOOP
        FETCH cv_cursor_data INTO v_id, v_title, v_credit, v_dept, v_prereq, v_coreq;
        EXIT WHEN cv_cursor_data%NOTFOUND;
        DBMS_OUTPUT.PUT_LINE(v_id||','||v_title||','||v_credit||','||v_dept||','||v_prereq||','||v_coreq);
      END LOOP;
      CLOSE cv_cursor_data;  
  END p_print_data;
  
END export_tool;
/
show errors
set scan on
 
Related Solutions
 
Loading Advertisement...
 
[+][-]10/28/09 11:46 AM, ID: 25686789Accepted Solution

View this solution now by starting your 30-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

About this solution

Zones: PL / SQL, Oracle 10.x
Tags: Oracle PL/SQL
Sign Up Now!
Solution Provided By: sdstuber
Participating Experts: 1
Solution Grade: A
 
[+][-]10/28/09 09:53 AM, ID: 25685371Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]10/28/09 10:08 AM, ID: 25685547Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]10/28/09 10:11 AM, ID: 25685591Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]10/28/09 10:21 AM, ID: 25685725Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]10/28/09 10:32 AM, ID: 25685933Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]10/28/09 10:33 AM, ID: 25685941Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]10/28/09 10:48 AM, ID: 25686102Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]10/28/09 10:52 AM, ID: 25686144Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]10/28/09 10:54 AM, ID: 25686177Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]10/28/09 11:00 AM, ID: 25686249Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]10/28/09 11:13 AM, ID: 25686417Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]10/28/09 11:16 AM, ID: 25686452Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]10/28/09 11:34 AM, ID: 25686662Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]10/28/09 11:54 AM, ID: 25686873Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]10/28/09 11:57 AM, ID: 25686902Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
 
Loading Advertisement...
20091111-EE-VQP-92 - Hierarchy / EE_QW_3_20080625