Report problem with PL/sql
function BeforeReport return boolean is
begin
declare
l_sort po_lookup_codes.displayed_field % type;
begin
if :P_orderby is not null then
select displayed_field
into l_sort
from po_lookup_codes
where lookup_code = :P_orderby
and lookup_type = 'SRS ORDER BY';
:P_orderby_displayed := l_sort ;
else
:P_orderby_displayed := '' ;
end if;
SRW.USER_EXIT('FND SRWINIT');
if (get_p_struct_num != TRUE )
then SRW.MESSAGE('1','Init failed');
end if;
if (get_chart_of_accounts_id != TRUE )
then SRW.MESSAGE('1','Init failed');
end if;
SRW.USER_EXIT('FND FLEXSQL CODE ="GL#"
OUTPUT =":P_FLEX_ACC1"
APPL_SHORT_NAME="SQLGL"
MODE ="SELECT"
DISPLAY ="ALL"
NUM =":P_chart_of_accounts_id"
TABLEALIAS ="GCC1"');
SRW.USER_EXIT('FND FLEXSQL CODE ="GL#"
OUTPUT =":P_FLEX_ACC2"
APPL_SHORT_NAME="SQLGL"
MODE ="SELECT"
DISPLAY ="ALL"
NUM =":P_chart_of_accounts_id"
TABLEALIAS ="GCC2"');
SRW.USER_EXIT('FND FLEXSQL CODE ="MCAT"
OUTPUT =":P_FLEX_CAT"
APPL_SHORT_NAME="INV"
MODE ="SELECT"
DISPLAY ="ALL"
NUM =":P_STRUCT_NUM"
TABLEALIAS ="MCA"');
SRW.USER_EXIT('FND FLEXSQL CODE ="MCAT"
OUTPUT =":P_WHERE_CAT"
APPL_SHORT_NAME="INV"
MODE ="WHERE"
DISPLAY ="ALL"
NUM =":P_STRUCT_NUM"
TABLEALIAS ="MCA"
OPERATOR ="BETWEEN"
OPERAND1 =":P_CATEGORY_FROM"
OPERAND2 =":P_CATEGORY_TO"');
SRW.USER_EXIT('FND FLEXSQL CODE ="MCAT"
OUTPUT =":P_ORDERBY_CAT"
APPL_SHORT_NAME="INV"
MODE ="ORDER BY"
DISPLAY ="ALL"
NUM =":P_STRUCT_NUM"
TABLEALIAS ="MCA"');
SRW.USER_EXIT('FND FLEXSQL CODE ="MSTK"
OUTPUT =":P_FLEX_ITEM"
APPL_SHORT_NAME="INV"
MODE ="SELECT"
DISPLAY ="ALL"
NUM =":P_ITEM_STRUCT_NUM"
TABLEALIAS ="MSI"');
/* Assign parameter P_Accrued_receipts to parameter P_yes_no
:P_yes_no := :P_Accrued_Receipts;
return(true);
exception
when others then return(false);
END;
return (TRUE);
end;
I think you should post it -
Forms
Regards.
Satyaki De.
Similar Messages
-
Master Report problem with PL/SQL
Hi Intelligent ones :)
Can anyone help?
I am trying to generate a Master report by generating a report based on a SQL query. The SQL query generates the detail of the report and the Main part of the report is generated using PL/SQL in "after displaying the header". See my PL/SQL below:
DECLARE
v_cloneid Clone.CloneID%TYPE;
BEGIN
htp.p('1: v_cloneid is:');
htp.p(v_cloneid);
SELECT Clone.CloneID
INTO v_cloneid
FROM ClonesDB.Clone;
htp.p(v_cloneid);
EXCEPTION
WHEN NO_DATA_FOUND
THEN
htp.p('No data Error');
WHEN OTHERS
THEN
htp.p('Error Detected');
htp.p('Exception: v_cloneid is:');
htp.p(v_cloneid);
END;
Every time I try to run my report an exception (When others) is generated. In my attempt to debugg my code I have discovered that the correct value is read into the v_cloneid variable. I can print this out within the exception but not before this!!
Also to generate a report for each cloneID entry I assume I will need to use a loop?
Please help...I'm just learning!!
Kirsteen
nullI think you should post it -
Forms
Regards.
Satyaki De. -
Problems with PL/SQL packages
Hello,
I face the following problem with PL/SQL stored procedures. The Oracle
version is 8.0.5 on Windows NT 4. The PL/SQL package has a set of procedures and functions.
The main procedure of the PL/SQL package is triggered from VC++ executable. If for some reason,
an exception is caught in the stored procedure (like no_data_found
exception), then the following problem occurs.
If we try to trigger the stored procedure again through the VC++ executable,
the variables in the stored procedures have the values as in the previous
execution. They are not getting initialised. (The same database connection
is used in VC++ executable).
Currently, only if a new connection to the database is used , the problem is
solved.
Also, change in the input parameters of the procedure is not reflected, once the procedure fails because of any exception. Only the input which was given during the time of execution when the procedure failed,is considered.
What could be the reason for this problem and how can this be corrected?
Please send in your suggestions.
Thanks and Regards,
Ramya Priya
nullHi Keith,
I am connecting to the database as the package owner..
I have noticed earlier that I have problems when capturing triggers also.. The content of one large trigger contains 36371 characters and when capturing it from DB, the content was truncated to 28020 characters in Designer.
Our ideas with capturing the DB packages/procedures were to use the Designer as version control system.
We wanted to have all objects used in a project in Designer.. entities, tables, triggers, packages, procedures, Forms files, etc. in order to make a configuration for a project release.
Thank you,
Claudia -
Reporting problems with iTunes
Does anyone know how to report problems with updates to iTunes to Apple? I cannot find any way to contact them to alert them to bugs and problems.
And if you're an ADC member (the Online membership is free), you can use Apple's Bug Reporter.
-
HT4718 are there any reported problems with safari with the new OS X Mavericks?
My early 2008 iMac running OS X 10.9.2 all of the sudden has problems loading pages in safari. The problem timing is the same as the upgrade to Maverick. The computer is connecting to wifi and other devices such as iPhones and three PCs have no problems. The ISP is Xfinity. Are there any reported problems with Maverick and Safari?
Try searching.
-
For several years now, I have created simple studies (I do psychological stuff) to run online, recruiting participants through Amazon Mechanical Turk (AMT). I have had no problems until recently (last 6 to 9 months). Now, some AMT users are reporting problems with stimuli loading or buttons not responding immediately when clicked (e.g., advancing to a new screen). What is common amongst all the users experiencing problems is that they use Chrome, and they also tend to be Windows NT 6.1 or 6.2 users running Flash Player 12.0. But not a single Firefox, Safari, or MSE user has ever reported an issue. I'm just looking for help in troubleshooting this problem. Again, the studies I run are incredibly simple (e.g., no videos being loaded from server, etc.), mostly word presentation where I record time and x,y coordinates of mouse movements as they respond to questions. Would attempting to publish for another target version of Flash Player help? The default setting is to publish the .swf and .html wrapper for Flash Player version 11.7. Any ideas? I also use version 13.0.1 of Flash Professional CC to create my studies if it helps.
This is helpful. Thanks. So it would be to my advantage to play around with something like SWFObject 2?
http://www.adobe.com/mena_fr/devnet/flashplayer/articles/swfobject.html
Or is there something else you would recommend?
What I've been doing is a far cry from actual web development, but quite interested in learning more. This swfobject seems to get at what you are suggesting (I think). -
XL Reporter problem with SQL 2005
Hi,
We just migrated our SQL Server from 2000 to 2005. Everything seemed OK, until we tried to run XL Reporter addon. Our SQL 2005 is 64bit edition, and I heard the 64bit version has some problem with transferring data to Excel, for example.
has anybody had the some problem? How can we solve this?
Thanks.
AndreHi Andre,
Check this thread: Re: XLR - Terminal Server
It should be a problem if your PL is upgrade to new.
Thanks,
Gordon -
EA 2.1: Some problems with PL/SQL objects
SQL Developer 2.1
JDK 1.6_0.16
Windows XP
Some features for PL/SQL objects (packages, functions, procedures) do not work in EA 2.1.
*1. User defined editor extensions*
My user defined extensions for PL/SQL objects are not loaded. These extensions are migrated from 1.5, where I added some tab pages to the editor.
*2. Go to <object name> does not work for PL/SQL objects*
From Reports the context menu shows the menu option "Go to ....".
This doesn't work for PL/SQL objects.
For example All Reports > Data Dictionary Reports > PLSQL > Progam Unit Arguments
*3. Open declaration for PL/SQL objects*
Selecting an objectname in the PL/SQL editor and select "Open declaration" from context menu opens the selected object. This works for tables, bu tnot for PL/SQL objects.Vadim,
In version 2.1 RC1 (2.1.0.63.41) I still have problems with the PL/SQL editor.
Will these be solved in the final version?
I was searching bug no. 8967961 in My Oracle Support, but was not able to find it. Where can I find this bug?
Problems in RC1:
*1. User defined extensions are not shown in PL/SQL editor.*
This problem is introduced in 2.1 EA1 and still exists in RC1.
*2. Pop-up describe for a pl/sql object shows only the user defined tab pages*
Select the name of a PL/SQL object in the editor, right click and choose "Popup describe". The default tab pages are not shown, only the tab pages added by User Defined Extensions.
*3. "Go to ...." option does not go to specific line number*
Use Report Data Dictionary Reports > PLSQL > Search Source Code. In the results, right click on an object and choose the "Go to .... " option. The editor doesn't go to the correct line. The pseudo column sdev_link_line has no effect. -
Problem with "PL/SQL Dynamic Content" and displaying rows
hi,
im new to APEX, and pl/sql [but not web dev or sql].
ive found the bit in APEX that lets you add data from your DB using the 'CREATE' > 'PL/SQL Dynamic Content'.
maybe there's a better option for people who dont know pl/sql? i dont know?
however, i think i can getting working with a little bit of help but im stumbling around in the dark a bit here.
ok so this is the pl/sql ive come up with to show three example values on page 23 of my aplplication:
BEGIN
SELECT ID, NAME, OWNER
FROM COM_MAILSHOTS
INTO :P23_ID, :P23_NAME, :P23_OWNER;
END;
im getting the error:
1 error has occurred
ORA-06550: line 5, column 21: PL/SQL: ORA-00933: SQL command not properly ended ORA-06550: line 4, column 1: PL/SQL: SQL Statement ignored
thanks for reading!Metabaron wrote:
hi,
im new to APEX, and pl/sql [but not web dev or sql].
ive found the bit in APEX that lets you add data from your DB using the 'CREATE' > 'PL/SQL Dynamic Content'.
maybe there's a better option for people who dont know pl/sql? i dont know?
The easiest (and best) way to "display rows" is using a report. Dynamic PL/SQL regions are more complex and are required much less frequently.
The Oracle® Database 2 Day + Application Express Developer's Guide tutorial explains how to create reports and other basic APEX techniques. -
Problem with java.sql.Clob and oracle.sql.CLOB
Hi,
I am using oracle9i and SAP web application server. I am getClob method and storing that in java.sql.Clob and using the getClass().getName() I am getting the class name as oracle.sql.CLOB. But when I am trying to cast this to oracle.sql.CLOB i am getting ClassCastException. The code is given below
java.sql.Clob lOracleClob = lResultSet.getClob(lColIndex + 1);
lPrintWriter = new PrintWriter(new BufferedWriter (((oracle.sql.CLOB) lOracleClob).getCharacterOutputStream()));
lResourceStatus = true;
can anybody please tell me the what is the problem with this and solution.
thanks,
Ashok.Hi Ashok
You can get a "ClassCastException" when the JVM doesn't have access to the specific class (in your case, "oracle.sql.CLOB").
Just check your classpath and see if you are referring to the correct jar files.
cheers
Sameer
PS: Please award points if you find the answer useful -
I am having a parent program which fires the child process.
I want the parent program to wait until all the child program are completed.
for this i have written this code.
from the curosr c1 i am taking all the child processes.
Now when i am putting the exit condition(EXIT WHEN J = V_COUNT1) in the for loop then
everything is working fine and parent program completes only after all
the child processes are completed.
but when i am not putting this condition the parent program does not complete it remains in the loop
i dont understand why?
declare
cursor c1 is
SELECT fcr.request_id
FROM
fnd_concurrent_programs fcp,
fnd_concurrent_requests fcr
WHERE
fcp.concurrent_program_id = fcr.concurrent_program_id
AND fcp.concurrent_program_name LIKE 'WSHRDPIK' -- name of the pick slip report
AND fcr.request_id > (SELECT max(fcr.request_id)
FROM fnd_concurrent_requests fcr,
fnd_concurrent_programs fcp
WHERE fcp.concurrent_program_id = fcr.concurrent_program_id
AND fcp.concurrent_program_name LIKE 'OAI_PROCESS_SHIPMENTS')
AND phase_code NOT LIKE 'C'
AND requested_by IN (SELECT user_id
FROM fnd_user
WHERE user_name LIKE 'MAKANIV');
BEGIN
open c1;
FETCH c1 Bulk Collect into v_count;
close c1;
v_count1 := v_count.count;
for i in v_count.first..v_count.last loop
v_success := FND_CONCURRENT.GET_REQUEST_STATUS(v_count(i)
,NULL
,NULL
,v_phase
,v_status
,v_dev_phase
,v_dev_status
,v_message);
WHILE v_dev_phase != 'COMPLETE'
LOOP
v_success:= FND_CONCURRENT.WAIT_FOR_REQUEST(v_count(i)
,2
,10
,v_phase
,v_status
,v_dev_phase
,v_dev_status
,v_message);
EXIT WHEN v_dev_phase = 'COMPLETE';
END LOOP;
-- J:= J + 1;
-- EXIT WHEN J = V_COUNT1;
END loop;
END;Dear Salvatore,
Have you opened the CURSOR ??
Try the following :
=============================================
declare
cursor C1 (INPUT_VAR in number) is select column1 from table where column2 =INPUT_VAR ;
begin
for I in C1 (1111) Loop --- you can try any number
dbms_output.put_line(I.ID) ;
end loop;
end ;
=============================================
Bst Rgds ,
Franco Lin
I am new to this forum, and new to PL/SQL. I am writing my first larger project that will be in part implemented with PL/SQL. I have a simple cursor that sound like that:
CURSOR name
IS
SELECT column1
FROM table
WHERE column2 = PL/SQL-variable;
When I run this Function the SELECT returns nothing. When I make the same SELECT from SQL*PLUS I receive 1 row.
I have checked the variable via dbms_output.put_line, and make the mentioned SELECT with it.
Has anyone a solution for this?
Thanks in advance for any help.
Regards
Salvatore Cagliari
null -
Problem with Oracle SQL Developer 3.0.04
1. Performing a "SELECT *" on an Oracle table with a SDO_GEOMETRY column locks up the tool and I have to use Task Manager to can it.
2. Clicking the Data tab on a table with an SDO_GEOM col either locks up the tool, or taked forever to return.
3. Performing a "SELECT" of a SDO_GEOM col either locks up the tool or takes forever to return.
None of these issues occur in Toad.If you have a problem with SQL Developer, you'd be best off posting in the SQL Developer!
-
Compile problem with javax.sql
I have upgraded to sdk 1.4.2 and tried to compile my code. I am getting an error on import javax.sql.* where I am getting the message "Package does not exist" error. As the result of this any class that is in this package gets an error as well. I am using ant to do the build. It does not seem to have a problem with the other import files and some of my code do compile fine except for this one that contains javax.sql.*. Thanks for your help.
Are you sure that the javax.sql.* stuff exists in your javac classpath? It seems not to be there. Look for j2ee.jar (from Sun J2EE SDK), or something like that (something like it probably came with your app server).
Mike -
Cannot "Report problem" with recent purchase.
I am using Windows 7 Pro w/ Internet Explorer 11 and iTunes v11.1.3.8. Both these are latest versions as far as I know. Despite this, when I go to report a problem with a recent download, IE shows a message I must be using the latest versions of these two applications in order report the problem.
What to do about this?If it is an issue with a song not playing correctly, you may be able to re-download it with iTunes in the cloud beta. Log in to your account, click on "Purchased" in the Quicklinks section, and re-download the song.
-
Problem with native SQL cursor in generic data source
Hi, All!
I am implementing generic data source based on FM.
Because of complicated SQL I canu2019t use Open SQL and RSAX_BIW_GET_DATA_SIMPLE-example u201Cas isu201D.
So, I have to use Native SQL. But Iu2019ve got a problem with a cursor. When I test my data source in RSA3, everything is Ok. But, if I start appropriate info-package, I get error u201CABAP/4 processor: DBIF_DSQL2_INVALID_CURSORu201D. It happens after selecting of 1st data package in line u201CFETCH NEXT S1 INTOu2026u201D. It seems to me that when system performs the second call of my FM the opened cursor has already been disappeared.
Did anyone do things like this and what is incorrect?
Is it real to make generic data source based on FM with using Native SQL open, fetch, closeu2026Hi Jason,
I don't think this SQL is very valuable It is just an aggregation with some custom rules. This aggregation is performing on info-provider which consists of two info-cubes. Here we have about 2 billion records in info-provider and about 30 million records in custom db-table Z_TMP (certainly, it has indexes). I have to do this operation on 21 info-providers like this and I have to do this 20 times for each info-provider (with different values of host-variable p_GROUP)
SELECT T.T1, SUM( T.T2 ), SUM( T.T3 ), SUM( T.T4 )
FROM (
SELECT F."KEY_EVENT06088" AS T1,
F."/BIC/EV_COST" + F."/BIC/EV_A_COST" AS T2,
DECODE( D.SID_EVENTTYPE, 23147, 0,
23148, 0,
23151, 0,
23153, 0,
23157, 0,
23159, 0,
24896734, 0,
695032768, 0,
695029006, 0,
695029007, 0,
695036746, 0, F."/BIC/EV_COST") +
DECODE( D.SID_EVENTTYPE, 23147, 0,
23148, 0,
23151, 0,
23153, 0,
23157, 0,
23159, 0,
24896734, 0,
695032768, 0,
695029006, 0,
695029007, 0,
695036746, 0, F."/BIC/EV_A_COST") AS T3,
DECODE( D.SID_EVENTTYPE, 23147, F."/BIC/EV_DURAT",
23148, F."/BIC/EV_DURAT",
23151, F."/BIC/EV_DURAT",
23153, F."/BIC/EV_DURAT",
23157, F."/BIC/EV_DURAT",
23159, F."/BIC/EV_DURAT",
24896734, F."/BIC/EV_DURAT",
695032768, F."/BIC/EV_DURAT",
695029006, F."/BIC/EV_DURAT",
695029007, F."/BIC/EV_DURAT",
695036746, F."/BIC/EV_DURAT", 0) AS T4
FROM "/BIC/VEVENT0608F" F,
Z_TMP G,
"/BIC/DEVENT06085" D
WHERE F."KEY_EVENT06088" = G.ID
AND F."KEY_EVENT06085" = D.DIMID
AND G.GROUP_NO = :p_GROUP
AND ( F."/BIC/EV_COST" < 0 OR F."/BIC/EV_A_COST" < 0 )
AND D.SID_EVENTTYPE <> 695030676 AND D.SID_EVENTTYPE <> 695030678
UNION
SELECT F."KEY_EVNA06088" AS T1,
F."/BIC/EV_COST" + F."/BIC/EV_A_COST" AS T2,
DECODE( D.SID_EVENTTYPE, 23147, 0,
23148, 0,
23151, 0,
23153, 0,
23157, 0,
23159, 0,
24896734, 0,
695032768, 0,
695029006, 0,
695029007, 0,
695036746, 0, F."/BIC/EV_COST") +
DECODE( D.SID_EVENTTYPE, 23147, 0,
23148, 0,
23151, 0,
23153, 0,
23157, 0,
23159, 0,
24896734, 0,
695032768, 0,
695029006, 0,
695029007, 0,
695036746, 0, F."/BIC/EV_A_COST") AS T3,
DECODE( D.SID_EVENTTYPE, 23147, F."/BIC/EV_DURAT",
23148, F."/BIC/EV_DURAT",
23151, F."/BIC/EV_DURAT",
23153, F."/BIC/EV_DURAT",
23157, F."/BIC/EV_DURAT",
23159, F."/BIC/EV_DURAT",
24896734, F."/BIC/EV_DURAT",
695032768, F."/BIC/EV_DURAT",
695029006, F."/BIC/EV_DURAT",
695029007, F."/BIC/EV_DURAT",
695036746, F."/BIC/EV_DURAT", 0) AS T4
FROM "/BIC/VEVNA0608F" F,
Z_TMP G,
"/BIC/DEVNA06085" D
WHERE F."KEY_EVNA06088" = G.ID
AND F."KEY_EVNA06085" = D.DIMID
AND G.GROUP_NO = :p_GROUP
AND ( F."/BIC/EV_COST" < 0 OR F."/BIC/EV_A_COST" < 0 )
AND D.SID_EVENTTYPE <> 695030676 AND D.SID_EVENTTYPE <> 695030678
) T
GROUP BY T.T1
Maybe you are looking for
-
How do my GF and I share our iTunes library across our user profiles?
I'm sure this question has been asked a million times but here goes. My GF and I both have a user profile on our Mac Mini. She is just now setting up her new iPhone and wants to be able to get music on it and such from her own profile. All of the iTu
-
How to use Progressive video in aggregated file
I'm using Captivate 5 and have several .swf modules to publish along with their supporting video files (progressive download). How can I package these into an executable or aggregated output so the videos play? I can't load the videos into the aggr
-
How to print from pantech element via Bluetooth?
how to print from my pantech element tablet via bluetooth
-
How to check MWA session details in Oracle Apps R12
I am an Oracle Apps DBA. Current Issue is that sometimes users working with the RF Guns(Scanners) through telnet in MWA servers got hanged. They ask to kill their sessions. I do not know how to find the MWA loged in users sessions details. What I am
-
Is there an audible loss of quality when converting from WMA to MP3/AAC?
Just wondering when I convert my WMA files to MP3 or AAC using EasyWMA, iTunes for WIndows, Switch or whatever, will there be an audible loss of quality in the conversion? Thanks.