Displaying subtypes on a single form
I'll preface by saying I'm a student and am still very new to forms builder, so please bare with my lack of knowledge.
The database I'm working with has a table with four subtypes. I've created a form that displays records from the supertype table. I would like to be able to display the correct subtype records on the same form, but I don't really know how to approach doing this without having five data blocks displayed on the form at all times.
I'm using a radio button group to show which subtype the current record belongs to. Would there be a way for me to use the when-radio-changed trigger to hide the text items for the subtypes that don't need to be displayed for that record, or is there a better way to accomplish my goal?
Ok, last time I'm going to post in this thread because I'm starting to feel guilty for asking so much.
This was working great, but I found that the subtype record would get locked if I did the following:
-changed the subtype for an existing record (old subtype gets deleted)
-clicked the next or previous record button on the default toolbar without committing
-answered no to the 'do you want to save' message
I got around this (I think) by making custom next / previous buttons that check the system.record_status property of each displayed data block, and forces a choice of commit or rollback before changing records if the status is 'changed' or 'insert'.
Now, assume I have a button that calls another form. will the same problem (the record locking) happen if I don't perform the same check prior to the CALL_FORM() on that button?
Similar Messages
-
REg: HCM forms with Mutiple subtypes in a single form
Hi,
i am working with Address change form scenario. i would like to know if there is a possibility to change the subtype at runtime, like choose either permanent address or mailing address or temporary address to be changed in the form.SAP_PA backend service EXPECTS either a hardcoded/configured subtype OR a "*" for all available subtypes (which won't work in your case). What you "could" do is get creative with "rules" and check if values are entered, and then if so, do the operation for your subtype.
What you will need to do, which is what I do a LOT because of issues with SAP_PA is to actually make you update/changes in a backend function module (triggered in workflow). Now, things get a bit more complicated.....
Priod to EhP3, you could just call the ol' infotype operations function module in your own FM to do the change. However, from EhP3 and onward, you will need to do this via classes (same used by decoupled infotype framework.
Soooooo......time to get creative with your solution. -
Displaying items in a single line in ALV grid using ALV_TOP_OF_PAGE.
Hello Guys,
I am having a problem in displaying items in a single line in the ALV Grid using event ALV_TOP_OF_PAGE.
My requirement is to group items on a single line i.e. in the example below, Vendor code and posting date are on the same line. The next line the prints Vendor Name and Document no.
Vendor Code: 123123 Posting Date : 01.01.2011
Vendor Name: ABCD Document No: 152246598.
Here is my code in subroutine 'ALV_TOP_OF_PAGE',
wa_list_comments-typ = 'S'.
wa_list_comments-key = ''.
wa_list_comments-info = 'Vendor Code'.
APPEND wa_list_comments TO it_list_comments.
wa_list_comments-typ = 'S'.
wa_list_comments-key = ''.
wa_list_comments-info = 'Posting Date'.
APPEND wa_list_comments TO it_list_comments.
The above code prints in the following format i.e one below the other,
Vendor Code: 123123
Posting Date : 01.01.2011.
I also tried using HTML_TOP_OF_PAGE, but it didn't work.
Can anybody please help me out with this.
Regards,
Danish.Hi Danish,
Your problem is with the alignment and you need some fix positions .
The solution i feel is u can use as below :
In CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
use
i_callback_html_top_of_page = 'HTML_TOP_OF_PAGE'.
Now on calling routine call use cl_dd_document class :
FORM html_top_of_page USING document TYPE REF TO cl_dd_document .
data : doctable TYPE REF TO cl_dd_table_element,
col1_t1 TYPE REF TO cl_dd_area,
col2_t1 TYPE REF TO cl_dd_area,
col1_t2 TYPE REF TO cl_dd_area,
col2_t2 TYPE REF TO cl_dd_area.
add quick table with five columns
CALL METHOD lw_document->add_table
EXPORTING
no_of_columns = 2
border = '0'
cell_background_transparent = ' '
width = '100%'
IMPORTING
table = doctable.
Filling columns in row
CALL METHOD doctable->add_column
EXPORTING
width = '40%'
IMPORTING
column = col1_t1.
Filling columns in row
CALL METHOD doctable->add_column
EXPORTING
width = '60%'
IMPORTING
column = col2_t1.* Filling columns in row
Call method doctable->new_row.
CALL METHOD doctable->add_column
EXPORTING
width = '40%'
IMPORTING
column = col1_t2.
Filling columns in row
CALL METHOD doctable->add_column
EXPORTING
width = '60%'
IMPORTING
column = col2_t2.
*Now adding the texts
lw_text1 = 'your first text'
CALL METHOD col1_t1->add_text
EXPORTING
text = lw_text.
*Similarly add text for other columns
*Adujust % in width to adjust the column as required
Endform.
Hope this will solve your problem . -
Insert Multiple records in single form
Hi all,
I have already come across inserting multiple rows into a table using ADF BC. The solution to this is in the following thread
Re: How to create multiple new rows in ADF Table?
However,
The above solution is useful when we want to enter new values along with all the table entries getting displayed.
What can I do If I dont want all the table values but just an 'AddEntries' page where I can only add new rows without having the entries in table getting displayed.
Like,
Say, a form has 5 rows
Each row has empId, eMailSlNo ,eMail attributes
EmpId is same for all 5 records but emailId is different.
EmpId and eMailSlNo make the PK.
empId generated using sequence.
Now on submitting the form, I want all five records to be inserted.
(can i use ADF form instead of ADF table for the ViewObject in this case. I tried ADF form but i could only insert 1 record at a time).
I'm using 10.1.3.4
Please help.
Thanks in advance,
Shri
Edited by: newtoOTN on Dec 29, 2009 6:02 PMHi Shri,
ADF Form is meant for single insert/update. For multiple insert/update/delete using collection UI like table is preferred. I guess that either your db table or the UI table design has flaw (In my opinion but i don't know your usecase fully, so my guess might b wrong).
I would suggest,
- make EmpId as PK
- have another table to store EmpId(foreign key),emailSiNo, email
- Have master-detail relationship between both the db tables in ADF BC.
- Create master-detail table UI and on selection of master, display detail and if no records found add records and commit.
check these examples:
http://www.oracle.com/technology/products/jdev/tips/mills/MasterDetailSync/Master_Detail_Synchronization_in_ADF_Faces.html
http://andrejusb.blogspot.com/2007/06/create-edit-and-delete-operations-in.html
Hope this makes sense.
~K -
Replicating MS Access single form record selectors functionality
I am very new to APEX.
I would like to rebuild and improve on all our departments MS Access userforms using APEX.
At the moment I am trying to replicate the standard MS Access "single form" view of a record in a database table, with the record selector navigation buttons (prev, next, new record).
I have scoured the internet and this forum but have not successfully found the solution.
I need to be able to select a subset of records from a view/table and present them on a page one at a time, so the user can scroll through them (prev, next) and make edits. Because of the amount of info in each record, the whole screen will be taken up by each record (hence the single form view).
I have created a form pagination process that is supposed to get the next/previous primary key value, however I can't seem to get the buttons displayed on the form that should be firing off these processes.
What combination of features should I be using to replicate this functionality? I am using the "Form on a table/view" style page at the moment.
Cheers,
Richard.Hi
Even if you created a form pagination process, you need to "initialise" the PK field(s) -- by default, they are null and the pagination buttons will not show (this is very different from how access works).
You can do it using a conditional computation (e.g. selecting the min PK value when the PK field is null).
I hope this helps.
Luis -
How to run a specific LOVs within a single form? [SOLVED]
Hi people,
I am new to forms.I have two LOVs in a single form LOV7 and LOV25.one is created through wizard and other is created manually.while i execute the form automatic lov(LOV7) gets displayed.but what i should do to run the manually created LOV25?.am using forms 6i with oracle 9i.thanku
With Regards
VIDS
Edited by: vidusnat on Apr 25, 2009 2:39 AMHai vidusnat,
In forms, set the control property List Of Values.
In this case the property will be set by the LOV name which u have created through wizard(LOV7).
select the LOV name(LOV25) which u created manually.
Or U can set this property by code also.
SET_ITEM_PROPERTY('control NAME', LOV_NAME, 'lov name');
or in the KEY-LISTVAL Procedure, u can call the desired LOV.
DECLARE
Bln_Temp BOOLEAN;
BEGIN
IF condition1 THEN
Bln_Temp := SHOW_LOV('lov 1 name');
ELSE
Bln_Temp := SHOW_LOV('lov 2 name');
END IF;
END;
Regards,
Manu. -
Multiple Selects in a single form
I have six select boxes and I want them in a single form.
Below are the outputs for the select boxes.
<cfform
action="Resolution_History.cfm?year=#year#&sessiontype=#sessiontype#&btype=res"
name="form">
<select name="SRINPUT">
<option value="">SR
<CFOUTPUT Query="findSR"><Option
Value="#BILLNUMBER#">#BILLNUMBER#</cfoutput>
</select>
<select name="HRINPUT">
<option value="">HR
<CFOUTPUT Query="findHR"><Option
Value="#BILLNUMBER#">#BILLNUMBER#</cfoutput>
</select>
<select name="SCRINPUT">
<option value="">SCR
<CFOUTPUT Query="findSCR"><Option
Value="#BILLNUMBER#">#BILLNUMBER#</cfoutput>
</select>
<br>
<select name="HCRINPUT">
<option value="">HCR
<CFOUTPUT Query="findHCR"><Option
Value="#BILLNUMBER#">#BILLNUMBER#</cfoutput>
</select>
<select name="SJRINPUT">
<option value="">SJR
<CFOUTPUT Query="findSJR"><Option
Value="#BILLNUMBER#">#BILLNUMBER#</cfoutput>
</select>
<select name="HJRINPUT">
<option value="">HJR
<CFOUTPUT Query="findHJR"><Option
Value="#BILLNUMBER#">#BILLNUMBER#</cfoutput>
</select>
<INPUT TYPE="Submit" VALUE="Submit" alt="submit
button">
</cfform>
Once a user selects a number it will send them to an action
page. On the action page I need the below IF statement to work so
it will set the variables. It isn't working at this time. Its not
bringing the values of billnumber, houseorig or the billtype.
Does anyone have any thoughts? I know it is close to working
and I need to set all of the inputs to input4 to generate my
queries so I don't have to duplicate them.
<cfif form.srinput gt "0">
<cfset s = '#houseorig#'>
<cfset r = '#billtype#'>
<cfset input4 = '#srinput#'>
<cfelseif form.hrinput gt "0">
<cfset h = '#houseorig#'>
<cfset r = '#billtype#'>
<cfset input4 = '#hrinput#'>
<cfelseif form.scrinput gt "0">
<cfset s = '#houseorig#'>
<cfset cr = '#billtype#'>
<cfset input4 = '#scrinput#'>
<cfelseif form.hcrinput gt "0">
<cfset h = '#houseorig#'>
<cfset cr = '#billtype#'>
<cfset input4 = '#hcrinput#'>
<cfelseif form.sjrinput gt "0">
<cfset s = '#houseorig#'>
<cfset jr = '#billtype#'>
<cfset input4 = '#sjrinput#'>
<cfelse>
<cfset h = '#houseorig#'>
<cfset jr = '#billtype#'>
<cfset input4 = '#hjrinput#'>
</cfif>give'em a break. he is probably under pressure (like we all
have been). in response, i do not even see some of the variables
you are checking in the second script in the first. get this one
straight and i think it'll work. -
Multiple DataBase Connection in a Single Form
hi all
Is it Possible to have Multiple Database Connection With a Single Form
Block a : Retriving data from a database Service a/Schema A.
Block b : Retriving data from a Remote Database Service b / Schema B.
If yes how to do this.
regards
jai
email:[email protected]Sure you can access a database this way,
but can you base a block on this database connect? No you can't.
Frank -
How do I insert multiple rows from a single form ...
How do I insert multiple rows from a single form?
This form is organised by a table. (just as in an excel format)
I have 20 items on a form each row item has five field
+++++++++++ FORM AREA+++++++++++++++++++++++++++++++++++++++++++++++++++++
+Product| qty In | Qty Out | Balance | Date +
+------------------------------------------------------------------------+
+Item1 | textbox1 | textbox2 | textbox3 | date +
+ |value = $qty_in1|value= &qty_out1|value=$balance1|value=$date1 +
+------------------------------------------------------------------------+
+Item 2 | textbox1 | textbox2 | textbox4 | date +
+ |value = $qty_in2|value= $qty_out1|value=$balance2|value=$date2 +
+------------------------------------------------------------------------+
+ Item3 | textbox1 | textbox2 | textbox3 | date +
+------------------------------------------------------------------------+
+ contd | | | +
+------------------------------------------------------------------------+
+ item20| | | | +
+------------------------------------------------------------------------+
+ + + SUBMIT + ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Database Structure
+++++++++++++++++
+ Stock_tabe +
+---------------+
+ refid +
+---------------+
+ item +
+---------------+
+ Qty In +
+---------------+
+ Qty Out +
+---------------+
+ Balance +
+---------------+
+ Date +
+++++++++++++++++
Let's say for example user have to the use the form to enter all 10 items or few like 5 on their stock form into 4 different textbox field each lines of your form, however these items go into a "Stock_table" under Single insert transaction query when submit button is pressed.
Please anyone help me out, on how to get this concept started.Hello,
I have a way to do this, but it would take some hand coding on your part. If you feel comfortable hand writing php code and doing manual database calls, specificaly database INSERT calls you should be fine.
Create a custom form using the ADDT Custom Form Wizard that has all the rows and fields you need. This may take a bit if you are adding the ability for up to 20 rows, as per your diagram of the form area. The nice thing about using ADDT to create the form is that you can setup the form validation at the same time. Leave the last step in the Custom Form Wizard blank. You can add a custom database call here, but I would leave it blank.
Next, under ADDT's Forms Server Behaviors, select Custom Trigger. At the Basic tab, you enter your custom php code that will be executed. Here you are going to want to put your code that will check if a value has been entered in the form and then do a database INSERT operation on the Stock_table with that row. The advanced tab lets you set the order of operations and the name of the Custom Trigger. By default, it is set to AFTER. This means that the Custom Trigger will get executed AFTER the form data is processed by the Custom Form Transaction.
I usually just enter TEST into the "Basic" tab of the Custom Trigger. Then set my order of operations in the "Advanced" tab and close the Custom Trigger. Then I go to the code view for that page in Dreamweaver and find the Custom Trigger function and edit the code manually. It's much easier this way because the Custom Trigger wizard does not show you formatting on the code, and you don't have to keep opening the Wizard to edit and test your code.
Your going to have to have the Custom Trigger fuction do a test on the submitted form data. If data is present, then INSERT into database. Here's a basic example of what you need to do:
In your code view, the Custom Trigger will look something like this:
function Trigger_Custom(&$tNG) {
if($tNG->getColumnValue("Item_1")) {
$item1 = $tNG->getColumnValue("Item_1");
$textbox1_1 = $tNG->getColumnValue("Textbox_1");
$textbox1_2 = $tNG->getColumnValue("Textbox_2");
$textbox1_3 = $tNG->getColumnValue("Textbox_3");
$date1 = $tNG->getColumnValue("Textbox_3");
$queryAdd = "INSERT INTO Stock_table
(item, Qty_In, Qty_Out, Balance, Date) VALUES($item1, $textbox1_1, $textbox1_2, $textbox1_3, $date1)"
$result = mysql_query($queryAdd) or die(mysql_error());
This code checks to see if the form input field named Item_1 is set. If so, then get the rest of the values for the first item and insert them into the database. You would need to do this for each row in your form. So the if you let the customer add 20 rows, you would need to check 20 times to see if the data is there or write the code so that it stops once it encounters an empty Item field. To exit a Custom Trigger, you can return NULL; and it will jump out of the function. You can also throw custom error message out of triggers, but this post is already way to long to get into that.
$tNG->getColumnValue("Item_1") is used to retrieve the value that was set by the form input field named Item_1. This field is named by the Custom Form Wizard when you create your form. You can see what all the input filed names are by looking in the code view for something like:
// Add columns
$customTransaction->addColumn("Item_1", "STRING_TYPE", "POST", "Item_1");
There will be one for each field you created with the Custom Form Wizard.
Unfortunately, I don't have an easy way to do what you need. Maybe there is a way, but since none of the experts have responded, I thought I would point you in a direction. You should read all you can about Custom Triggers in the ADDT documentation/help pdf to give you more detailed information about how Custom Triggers work.
Hope this helps.
Shane -
Display values of a single field in a multiple rows in a table region
Hi Tech-Gurus,
I want to display values of a single field ( which is in a table region) in multiple rows and also need to restrict the values from decimal number. If i click save, then it will throw exception "Decimal not allowed".
xxxxxx
yyyyyy
Reg.No
1234
5678
7654
I need to display the values of REG.NO in different rows like,
1234
5678
7654
and also need to validate as well against Decimal values.
Please help me with the code how i will iterate ?Hi,
I am assuming you are talking about displaying substrings from the Reg No in different rows. For this you would need to write a query which identifies the substrings and creates a separate row for each (ensure you choose values for all other columns in the table row). Kindly let me know if the understanding is incorrect.
To validate against decimal value you can use the java code by checking the difference of the number and the number on which modulus has been applied. Hope that helps.
Regards
Sumit -
How to running a single form on the browser
Hi below is the link for deployment of our application on app server.
http://100.180.127.225:7779/forms90/f90servlet?config=abc
and this is the entries in formsweb.cfg file.
[abc]
form=G:\Oracle10gBinaries\abc\FMX\test.fmx
otherparams=prm_init_file=G:\abc.INI prm_itype=0 prm_impli_type=9W prm_debug_mode=NO
pageTitle=Heading
envFile=abc.env
separateFrame=TRUE
lookAndFeel=generic
archive_jini=f90all_jinit.jar
imagebase=codebase
Now i want to run a form named test2.fmx directly by passing the value as *test2.fmx on the browser.
what change i needs make in the formsweb file to achieve this.Hi all thanks for ur help.
i am able to run the .fmx directly .this i have achieved by putting the .fmx in the forms90 folder and using the link.
http://100.180.127.225:7779/forms90/f90servlet?form=test2.fmx
it is working fine and showing the single form but now i want to pass a parameter
from the link to the test2.fmx directly/
when launched from the link ,test2.fmx shows all the records. as this form contains customer information so it list all the customer no.
i want to launch this form with only the customer id passed thro the link.
i am trying something like
http://100.180.127.225:7779/forms90/f90servlet?.fmx&PRM_CUST_NO=000000014
where 000000014 is the customer no.
when launch the forms it still gives all records and not this customer record.
prm_cust_no is the oracle form parameter which is defined in the form.
please suggest? -
How to display pie chart in smart forms
hii experts,
my requirement is to display pi chart in smart forms . i have googled but could not get any meaning full results. If any one knows this pls share ..
Thanks and Regards
Aditya ShrivastavaHi
I really doubt If you did search at all in the first place. Anyhow, check this:
https://www.sdn.sap.com/irj/scn/advancedsearch?query=piechartin+smartforms&cat=sdn_all
Vishwa. -
How to Display an Image on my FORM
Good Day!
I would like to ask some help from you guys with my problem on how to display an image on my form. I would like to display my uploaded image on my form but instead of an image, the get_blob_file is showing. By the way, I'm using Apex 4.1
I downloaded the Order Entry Sample Application and followed the Page 6, the Product Details. I even made snapshots of each details from Page Rendering to Page Processing in order not to miss a thing.
At the moment, I was able to upload or store the image on my created Oracle table and also able to retrieve it on the Download Link Text with Content Disposition value of Inline, provided by APEX Settings. If I invoke the Download link beside the file browser, a page with the image will be shown, below is the address:
http://127.0.0.1:8080/apex/apex_util.get_blob_file?a=200&s=339877802936975&p=230&d=7107921433296839&i=7107601420296838&p_pk1=54&p_pk2=&p_ck=7D6512D967336C4B94258EEA3CDF1BE6&p_content_disposition=inline
However, instead of showing the image on a region, below is the one showing on my Form:
<img src="apex_util.get_blob_file?a=200&s=339877802936975&p=230&d=7107921433296839&i=7107601420296838&p_pk1=54&p_pk2=&p_ck=7D6512D967336C4B94258EEA3CDF1BE6" />
As you can see the parameter values are the same but I know I missed something that's why I'm here :)
I would highly appreciate all the help you can provide and many thanks in advance.
I tried to change gear by making an html region of type PL/SQL (anonymous block) and a procedure but still no image :(
Below are the scripts.
declare
cursor cur is
select *
from wsemployee
where empid = :P230_EMPID;
begin
for rec in cur
loop
IF rec.mime_type is not null or rec.mime_type != '' THEN
htp.p( '<img src="my_image_display?p_image_id='||NVL(rec.empid,0)||'" height="'||100||'"/>' );
else
htp.p( 'No Image ');
END IF;
htp.p( ' ');
end loop;
end;
PROCEDURE
create or replace PROCEDURE my_image_display( p_image_id IN NUMBER)
AS
l_mime VARCHAR2 (255);
l_length NUMBER;
l_file_name VARCHAR2 (2000);
lob_loc BLOB;
BEGIN
SELECT MIME_TYPE, PHOTO_BLOB_CONTENT, PHOTO_FILENAME,DBMS_LOB.GETLENGTH(photo_blob_content)
INTO l_mime,lob_loc,l_file_name,l_length
FROM wsemployee
WHERE empid = p_image_id;
-- set up HTTP header
-- use an NVL around the mime type and
-- if it is a null set it to application/octect
-- application/octect may launch a download window from windows
owa_util.mime_header( nvl(l_mime,'application/octet'), FALSE );
-- set the size so the browser knows how much to download
htp.p('Content-length: ' || l_length);
-- the filename will be used by the browser if the users does a save as
htp.p('Content-Disposition: attachment; filename="'||replace(replace(substr(l_file_name,instr(l_file_name,'/')+1),chr(10),null),chr(13),null)|| '"');
-- close the headers
owa_util.http_header_close;
-- download the BLOB
wpg_docload.download_file( Lob_loc );
END my_image_display;
Edited by: user13831927 on Dec 22, 2012 3:24 PMHi Ying,
you can add a UDF to the table spp2 with a programm
but the table is not yet listed in the 'Manage User Fields' form.
there's no way to "enable" it - sorry -
Hi,
I'm facing a problem of having multiple canvases(3) in single form.
I've two Data blocks(Master & Detail). Master having one canvas. But details have two different canvases.
I've created 3 different menus for 3 canvases.
say Master,Detail1,Detail2. Now the problem is when i try to open detail1 or detail2 from oracle apps menu it opens master canvas only.
i've created functions in apps & in NEW_FORM_INSTANCE trigger coded like
If (fnd_function.current_form_function = 'CRM_FC_PPC') then
GO_BLOCK('CRM_CUSTO_FORCAST_DET');
SHOW_VIEW('PPC');
HIDE_VIEW('CUST_FORECAST');
HIDE_VIEW('SHIPPING');
Elsif (fnd_function.current_form_function = 'CRM_FC_SHIP') then
SHOW_VIEW('SHIPPING');
HIDE_VIEW('PPC');
HIDE_VIEW('CUST_FORECAST');
Else
SHOW_VIEW('CUST_FORECAST');
HIDE_VIEW('PPC');
HIDE_VIEW('SHIPPING');
Go_item('CRM_CUST_FORCAST_HDR.CUSTOMER_ID');also my master canvas is Content & details are stacked. should i create different windows for details canvases ? i also did that but failed.
what could be the solution here ?
Forms 6i
DB 9.2
RegardsHi,
Sorry for delayed reply.
Francois,
I've tried with go_item but it doesn't worked. i knew it & tried it before asking here. but thanks anyway.
Ahmed,
i've only one window show all these canvases.I'm now trying with multiple windows.
The code is as follow
If (fnd_function.current_form_function = 'IRS_CRM_FC_PPC') then
GO_ITEM('IRS_CRM_CUSTO_FORCAST_DET.CUSTOMER_ID');
Set_window_property('CF_PPC',VISIBLE,PROPERTY_TRUE);
Set_window_property('MAIN',VISIBLE,PROPERTY_FALSE);
Set_window_property('CF_PPC',TITLE,'IRS CRM PPC Details'||:global.div);
GO_BLOCK('IRS_CRM_CUSTO_FORCAST_DET');
SHOW_VIEW('PPC');
HIDE_VIEW('CUST_FORECAST');
HIDE_VIEW('SHIPPING');
Elsif (fnd_function.current_form_function = 'IRS_CRM_FC_SHIP') then
SHOW_VIEW('SHIPPING');
HIDE_VIEW('PPC');
HIDE_VIEW('CUST_FORECAST');
Else
SHOW_VIEW('CUST_FORECAST');
HIDE_VIEW('PPC');
HIDE_VIEW('SHIPPING');
Go_item('IRS_CRM_CUST_FORCAST_HDR.CUSTOMER_ID');Regards
PS. Master is Content & details are stacked.
Edited by: user10569054 on Apr 5, 2010 3:10 PM edited for canvas details -
Displaying a trigger error in forms
In a before inserting table trigger, if inserted values are not correct, I raise an error :
RAISE_APPLICATION_ERROR(-20001,'Error message !');
What I want is to display this error message in forms instead of the error 40508 - ORACLE error: unable to INSERT record.
How can I ?look at Dbms_Error_Code and Dbms_Error_Text.
You'll have to parse them, but you can grab the error messages off them.
Here's a similar question I asked on Metalink... I never received an error there, but the solution was to write an on-error trigger for the block and capture the form errors related to inserts, updates, and deletes. Here's the question though:
Oracle Forms/Web Forms Technical Forum
From: ERIC GIVLER 18-Nov-00 15:16
Subject: "Clean" capture of DBMS Error messages on raise_application_error
"Clean" capture of DBMS Error messages on raise_application_error
This is with Forms 4.5 Developer 1.3.2 (32bit)
Has anyone written forms level triggers, I guess ON-ERROR triggers to properly capture the error messages raised from a database trigger or procedure that uses a RAISE_APPLICATION_ERROR?
I'd like to display the SAME message that I'm passing to RAISE application error, the message only, without all the other garbage.
I was thinking of capturing the dbms_error_code and dbms_error_text, and then based on the form error code - kind of like in the example code in the Forms Help. Then, I'd parse these strings and strip off my error message, because the dbms_error_text contains the entire "error stack", ie:
ORA-20100: SEASON DATES ERROR! Reservations exist in this date range
ORA-06512: at "SUNTRACK.SEASON_DATES_BR_D", line 19
ORA-04088: error during execution of trigger 'SUNTRACK.SEASON_DATES_BR_D'
So... I'd like to just get "SEASON DATES ERROR! Reservations exist in this date range" message
Questions:
1. Is there an easy way to do this that I'm missing, or do I have to brute force, look for 'ORA'| |dbms_error_code| |': ' in my dbms_error_text, strip that off the front, and then grab the error text up to the first LINEFEED, chr(10), found in the dbms_error_text - that just seems a little "kludgy"
2. Anyone have a nice solution? IT seems like there should be a "standard" on-error trigger that handles this type of situation.
3. What would be all the form errors that I should look for that could have been the result of an error raised in a trigger???
ie. frm-40509 (unable to update), frm-40510 (unable to delete
null
Maybe you are looking for
-
Problem trying to update a table cell
Hello all, I'm trying to implement a setValueAt method using an arrayList.....no success. Could anyone help? When trying to change the a value in the table I get these errors: "Exception occurred during event dispatching: java.lang.ClassCastException
-
Share Printer with WiFi XP Laptop
I have a Mac-Mini w/AirPort Extreme built in, and I have my Lexmark X5150 connected to the USB Port on my AirPort Express, and I want to setup my wifes Dell Laptop running XP to connect and print wirelessly using her built in wireless addapter so we
-
Is anyone else still having there iMessages fail to send on iPhone 4?
Ever since the iOS 7 started I've had nothing but problems with my iMessage. I have to sign out of iMessage restart my phone and then sign back in. Even then it only works for a few hours, and then I start the whole process over again. My software i
-
Hi people, Is there any way to generate xml stack for a ERP6.0 which you will be installing the EHP4 and there is no solution manager? More thanks
-
Hello Everybody, I am new to JDeveloper IDE. I wanted to know why the JDeveloper versions 10.1.3.3 and 10.1.3.5 do not create a settings folder named 'JDeveloper' under "C:\Documents and Settings\<username>\Application Data" path? In JDeveloper 11g p