Tabular form validation
Apex 4.2
Problems with the validation of the form in a table and not sure what type of validation to use:
My tabular presentation is based on a table SURVEY_JOB_TASKS:
Survey_Job_Task_ID PK
Percentage
Task_Id FK
Bundle_Id FK
I also have a TASK table that contains all the tasks
Task_Id
TaskName
In the validation form, the Survey_Job_task_Id is managed by a trigger. The percentage is an entrable field. The Task_Id is a selection list. The Bundle_Id is passed to the page; It is hidden.
The Task_Id / select list is created with the following query
Select task_name, task_id From TASKS
I want a validation so that a user cannot enter the same task_id. If the selection list should look like:
TaskName Task_Id
Apples 1
2 oranges
Bananas 3
Pears 4
If a user accesses the page, enters an information line and select bananas in the selection list. The user saves / submits and leaves the page. The user returns to the page and they seek to enter another line, if they choose bananas once again, then validation strikes by saying that they cannot enter a double task identifier. There is an already established constriant in place which does not allow to do so. It gives an error ORA, but I wanted to make the error message a bit more friendly user.
I tried some queries of variation of validation with type Exists or not exists but I may be missing it completely.
Any help on this would be greatly appreciated. Thanks in advance
plus extra extra extra... the logic should be a little different because otherwise it will always return false
IF (( APEX_APPLICATION.G_F03(I) = APEX_APPLICATION.G_F03(j)) AND I<>J ) THEN RETURN false; end if;
Tags: Database
Similar Questions
-
Hello
I added a tabular presentation on my shape of the APEX. It has two columns, year and budget (to be seized of the user).
In addition, the total budget is spent in the URL and stored in a variable in the form of the APEX.
Now the required validation is the sum of the contribution of the individual budgets of the user for each year must be less than or equal to the budget total (stored in the variable in the form of the APEX.
If this is not the case, an error message should be displayed.
I am new to the development of the APEX and need help on that.
Hi David,
Just right click on the field and click on inspect element, you will get the details of the field.
If your issue is resolved, then close this thread by ticking the correct answer on the post that solved the problem.
That helps other users in the forum to solve their problem, if they have a similar question.
Kind regards
Jitendra
-
Tabular form validation - save the correct values
I use the example of the Dene of validation in the form of table. It detects errors and displays the error messages, but I lose all the values that have been entered correctly. Do I need to use a collection to save? I was looking through older posts and comment, it's that you need only one collection if you want to show the user the values that they entered incorrectly. With the logic of the Dene, she tells them what line the error and what is the initial value was.
Thank youDECLARE l_error VARCHAR2 (4000); BEGIN FOR i IN 1 .. apex_application.g_f02.COUNT LOOP IF NOT TO_DATE (apex_application.g_f05 (i), 'YYYY') BETWEEN TRUNC (TO_DATE (apex_application.g_f04 (i),'YYYY')) AND TO_DATE ('2008','YYYY') THEN l_error := l_error || '</br>' || 'Row ' || i || ': Photo Inspection Year has to be greater than Date On Map and less than 2008 for ' || ' Map: ' || apex_application.g_f02 (i) || '<br> Requested date: ' || apex_application.g_f05 (i); END IF; IF NOT TO_DATE (apex_application.g_f04 (i), 'YYYY') BETWEEN TO_DATE ('1890','YYYY') AND TO_DATE ('2008','YYYY') THEN l_error := l_error || '</br>' || 'Row ' || i || ': Date on map has to be between 1890 and 2008 for ' || ' Map: ' || apex_application.g_f02 (i) || ' <br>Requested date: ' || apex_application.g_f04 (i); END IF; END LOOP; RETURN LTRIM (l_error, '</br>');
SusanThis is a parameter in the validation - display message error location.
Denes Kubicek
-------------------------------------------------------------------
http://deneskubicek.blogspot.com/
http://www.Opal-consulting.de/training
http://Apex.Oracle.com/pls/OTN/f?p=31517:1
------------------------------------------------------------------- -
Error ORA-01445 tabular form on a Collection in APEX 5
When I load a page with a tabular presentation built on a display of a collection to the APEX 5, I'm getting an ORA-01445: cannot select ROWID, or the sample, a view of joining without an error table preserved key.
I create a view
CREATE or REPLACE FORCE VIEWS test_coll_vw
(
C001,
C002,
C003,
C004,
seq_id
)
AS
SELECT TO_NUMBER (c001),
C002,
TO_NUMBER (c003),
TO_NUMBER (c004),
seq_id
Of apex_collections
WHERE collection_name = 'TEST '.
Then create a tabular presentation on the view with the primary key of the source SEQ_ID and primary key of the trigger existing through the wizard.
Debug information shows the statement which is a failure:
Select NULL NULL "CHECK$ 01", "SEQ_ID,' NULL 'C001', NULL"C002', 'C003', 'C004', NULL NULL NULL "APEX$ ROWID ' sys.dual union all select ' CHECK$ 01", 'SEQ_ID', 'C001', 'C002', 'C003', "C004", "APEX$ ROWID" in (select NULL "CHECK$ 01", "SEQ_ID", "C001", "C002", "C003", "C004", "ROWID" "APEX$ ROWID" (select).
"SEQ_ID."
"C001."
"C002."
"C003."
"C004.
of 'WPCAMS_APP '. "" TEST_COLL_VW ".
) APEX$ RPTSRC
order of 1, 7
).
These tabular forms worked up to 4.2, but they seem to fail at 5 APEX for upgrade or newly created pages one. The generated query is identical between versions, but it seems that the underlying apex_collections view has changed between versions and the origin of the problem.
Does anyone have a solution or workaround?
Thank you
Hi Phil,
APEX 5.0 the definition of the view of apex_collection had to be changed for security reasons. This change introduced a regression with tabular form validations, when the table refers to this view. Tabular form declarative validations require the ROWID in order to restore your changed data after a validation failed, and for this reason, APEX is insert the IDENTIFIER in the query in a table. It is currently not possible when tables refers to the sight of apex_collections. We are looking at a solution to this problem, but for now the only way to get around this is not, in this case, use the declarative validation and use some custom validations or process.
Kind regards
Marc -
Validation of tabular form regarding the item master detail
Hi guys,.
I have installation master detail on my page with a layout table below.
The master record has a field called RCV_QTY.
The tabular presentation has a column called box_qty.
What I'm trying to do is to validate it against the user to add lines in the table form which when added, is more than the amount of heading RCV_QTY.
I tried the following function returns the validation text error but it's not enough work.
As the line in the custom of tabular form be seen by the following SELECT INTO statements on submit, I guess I need more of a process of dynamic action type?
DECLARE
v_hdr NUMBER;
v_line NUMBER;
BEGIN
SELECT hdr.rcv_qty
IN v_hdr
OF XXMEL_VMI_RCV_HDR_TMP hdr
WHERE the hdr. VMI_RCV_HEADER_ID =: P2_VMI_RCV_HEADER_ID;
SELECT SUM (line. BOX_QTY)
IN v_line
OF XXMEL_VMI_RCV_HDR_TMP hdr
Online XXMEL_VMI_RCV_LINE_TMP
WHERE the hdr. VMI_RCV_HEADER_ID = line. VMI_RCV_HEADER_ID
AND hdr. VMI_RCV_HEADER_ID =: P2_VMI_RCV_HEADER_ID;
IF (NVL(v_line,0) - NVL(v_hdr,0)) < 0
THEN
RETURN (' ERROR: the sum of the quantities of tag is greater than the quantity of the received header ');
ON THE OTHER
RETURNS A NULL VALUE.
END IF;
END;
Any help would be great.
I use Apex V4.0.Hello
You must use the API APEX_APPLICATION total up to the Box_Qty of detail in Validation, and compare with the RCV_QTY. something like
DECLARE V_BOX_TOT NUMBER := 0; BEGIN FOR I IN 1..APEX_APPLICATION.G_F01.COUNT LOOP V_BOX_TOT := V_BOX_TOT + TO_NUMBER( NVL(APEX_APPLICATION.G_F01(I),'0')); END LOOP; IF V_BOX_TOT > :P1_RCV_QTY THEN RETURN FALSE; ELSE RETURN TRUE; END IF; EXCEPTION ..... END;
Kind regards
-
Validation of a column in a query SQL-tabular form (updated report)
Hello
I have a tabular form on a table of type SQL Query (editable report). Users can modify/add lines to the table through the form. I would like to have some sort of validation on each column of the report form. Is there a way I can do it by their SUMMIT. Please note that I did not manually create this form... just use the tools in the APEX. Thank you.
SihemIn the same way.
Denes Kubicek
-------------------------------------------------------------------
http://deneskubicek.blogspot.com/
http://www.Opal-consulting.de/training
http://Apex.Oracle.com/pls/OTN/f?p=31517:1
------------------------------------------------------------------- -
Adding line by submitting the manual tabular form while adding lines
Hi all
I'm a newbie in the Apex.
I created a manual tabular form based on Apex_Collection. In addition, created the buttons ADD, DELETE and APPLY the CHANGES .
The data below are the steps that I did.
1 initialize the Collections
Process: When loading - before header
Enforcement process: once a Page visit
Source:
DECLARE l_collection_name APEX_COLLECTIONS.COLLECTION_NAME%TYPE; l_bind_names APEX_APPLICATION_GLOBAL.VC_ARR2; l_bind_values APEX_APPLICATION_GLOBAL.VC_ARR2; l_query VARCHAR2(32767); BEGIN l_collection_name := 'EMAILDETAILS'; IF apex_collection.collection_exists(l_collection_name) THEN apex_collection.delete_collection(p_collection_name => l_collection_name); END IF; l_query := ' SELECT cmp_cd, ' --c001 => f01 || ' email, ' --c002 => f02 || ' tab_seq_id, ' --c003 => f03 || ' NULL, ' --c004 => f04 || ' NULL, ' --c005 => f05 || ' NULL, ' --c006 => f06 || ' NULL, ' --c007 => f07 || ' NULL, ' --c008 => f08 || ' NULL, ' --c009 => f09 || ' NULL, ' --c010 => f10 || ' NULL, ' --c011 => f11 || ' NULL, ' --c012 => f12 || ' NULL, ' --c013 => f13 || ' NULL, ' --c014 => f14 || ' NULL, ' --c015 => f15 || ' NULL, ' --c016 => f16 || ' NULL, ' --c017 => f17 || ' NULL, ' --c018 => f18 || ' NULL, ' --c019 => f19 || ' NULL, ' --c020 => f20 || ' NULL, ' --c021 => f21 || ' NULL, ' --c022 => f22 || ' NULL, ' --c023 => f23 || ' NULL, ' --c024 => f24 || ' NULL, ' --c025 => f25 || ' NULL, ' --c026 => f26 || ' NULL, ' --c027 => f27 || ' NULL, ' --c028 => f28 || ' NULL, ' --c029 => f29 || ' NULL, ' --c030 => f30 || ' NULL, ' --c031 => f31 || ' NULL, ' --c032 => f32 || ' NULL, ' --c033 => f33 || ' NULL, ' --c034 => f34 || ' NULL, ' --c035 => f35 || ' NULL, ' --c036 => f36 || ' NULL, ' --c037 => f37 || ' NULL, ' --c038 => f38 || ' NULL, ' --c039 => f39 || ' NULL, ' --c040 => f40 || ' NULL, ' --c041 => f41 || ' NULL, ' --c042 => f42 || ' NULL, ' --c043 => f43 || ' NULL, ' --c044 => f44 || ' NULL, ' --c045 => f45 || ' NULL, ' --c046 => f46 || ' ''O'', ' --c047 (for record status) || ' wwv_flow_item.md5(cmp_cd, email, tab_seq_id) ' --c048 (for optimistic locking) --c049 for (not used in collection/reserevered for seq_id array) --c050 (not used in collection/reservered for delete checkbox array) || ' FROM Cmp_Email ' || ' WHERE cmp_cd= v(''P9_CMP_CD'') '; apex_collection.create_collection_from_query_b ( p_collection_name => l_collection_name, p_query => l_query ); IF :REQUEST = 'ADD' THEN APEX_COLLECTION.ADD_MEMBER(p_collection_name => l_collection_name); END IF; END;
2. tabular Guide
Type: SQL query
Source:
SELECT apex_item.hidden(4,c047,NULL,'f04_'|| '#ROWNUM#') || apex_item.hidden(5,c048,NULL,'f05_'|| '#ROWNUM#') || apex_item.hidden(6,seq_id,NULL,'f06_'|| '#ROWNUM#') || apex_item.hidden(3,c003,NULL,'f03_'|| '#ROWNUM#') || apex_item.hidden(1,c001,NULL,'f01_'|| '#ROWNUM#') || apex_item.checkbox( 7, seq_id, NULL, CASE WHEN c047 = 'D' THEN seq_id END, ':', 'f07_' || '#ROWNUM#' ) AS delete_checkbox, apex_item.text( 2, c002, 20, 50, NULL, 'f02_' || '#ROWNUM#' ) AS email_id FROM apex_collections WHERE collection_name ='EMAILDETAILS' ORDER BY c002
The buttons used:
1. name button: ADD
Action: send the Page
2 button name: DELETE
Action: send the Page
3 Collection page
Point process: present now - before the calculations and Validations
Enforcement process: once a Page visit
Source:
DECLARE l_collection_name APEX_COLLECTIONS.COLLECTION_NAME%TYPE; l_original_md5 VARCHAR2(32); l_latest_md5 VARCHAR2(32); BEGIN l_collection_name := 'EMAILDETAILS'; FOR x IN 1 .. apex_application.g_f06.count LOOP IF apex_application.g_f01(x) IS NOT NULL --ID exists, check to see if record was updated THEN SELECT c048 INTO l_original_md5 FROM apex_collections WHERE collection_name = l_collection_name AND seq_id = apex_application.g_f06(x); l_latest_md5 := wwv_flow_item.md5( apex_application.g_f01(x), apex_application.g_f02(x), apex_application.g_f03(x) ); IF l_original_md5 != l_latest_md5 THEN apex_collection.update_member( p_collection_name => l_collection_name, p_seq => apex_application.g_f06(x), p_c001 => apex_application.g_f01(x), p_c002 => apex_application.g_f02(x), p_c003 => apex_application.g_f03(x), p_c047 => 'U', p_c048 => apex_application.g_f05(x) ); END IF; ELSE --ID does not exist, must be new record apex_collection.update_member( p_collection_name => l_collection_name, p_seq => apex_application.g_f06(x), p_c001 => apex_application.g_f01(x), p_c002 => apex_application.g_f02(x), p_c003 => apex_application.g_f03(x), p_c047 => 'N', p_c048 => apex_application.g_f05(x) ); END IF; END LOOP; IF :REQUEST = 'DELETE' THEN FOR x IN 1 .. apex_application.g_f07.count LOOP apex_collection.update_member_attribute( p_collection_name => l_collection_name, p_seq => apex_application.g_f07(x), p_attr_number => '47', p_attr_value => 'D' ); END LOOP; END IF; END;
4. table collection
Point process: submit now - after calculations and Validations
Enforcement process: once a Page visit
Source:
DECLARE l_table_md5 VARCHAR2(32); l_collection_name APEX_COLLECTIONS.COLLECTION_NAME%TYPE; l_del_count PLS_INTEGER := 0; l_upd_count PLS_INTEGER := 0; l_ins_count PLS_INTEGER := 0; l_success_message VARCHAR2(32767); CURSOR op_lock_check_cur (p_id IN NUMBER) IS SELECT wwv_flow_item.md5(cmp_cd, email, tab_seq_id) FROM Cmp_Email WHERE tab_seq_id = op_lock_check_cur.p_id FOR UPDATE; BEGIN l_collection_name := 'EMAILDETAILS'; FOR x IN ( SELECT * FROM apex_collections WHERE collection_name = l_collection_name AND c047 IN ('N','U','D')) LOOP IF x.c047 = 'N' THEN INSERT INTO Cmp_Email(tab_seq_id,cmp_cd,email) VALUES (cmp_email_seq.nextval, :P5_CMP_CD_HIDN, x.c002 ); l_ins_count := l_ins_count + 1; ELSIF x.c047 = 'U' THEN OPEN op_lock_check_cur(x.c003); FETCH op_lock_check_cur INTO l_table_md5; IF l_table_md5 != x.c048 THEN raise_application_error(-20001,'Current version of data in database has changed since user initiated update process.'); END IF; UPDATE Cmp_Email SET cmp_cd=:P5_CMP_CD_HIDN ,email = x.c002 WHERE CURRENT OF op_lock_check_cur; CLOSE op_lock_check_cur; l_upd_count := l_upd_count + 1; ELSIF x.c047 = 'D' THEN DELETE FROM Cmp_Email WHERE tab_seq_id = x.c003; l_del_count := l_del_count + 1; END IF; END LOOP; apex_collection.delete_collection(p_collection_name => l_collection_name); l_success_message := l_ins_count || ' rows inserted, ' || l_upd_count || ' rows updated, ' || l_del_count || ' rows deleted'; :P5_SUCCESS_MESSAGE:= l_success_message; END;
When I press the ADD button, a new line must be added to the shape of the table and the data should be saved to the collection. , But currently, the page is being submitted to the database table when adding new lines in the form of tables. The data should only be saved in the database when the user clicks on the APPLY CHANGES button
I searched the Forum about this issue and have found many discussions which suggested to use JavaScript to add new lines. As I have no knowledge of JavaScript, these solutions have been strange for me.
Please help me solve this problem.
Thanks in advance.
Kind regards
Aravind
Hi Christophe,
Follow the changes mentioned below
1. remove this your Collections initialize
IF :REQUEST = 'ADD' THEN APEX_COLLECTION.ADD_MEMBER(p_collection_name => l_collection_name); END IF;
2 condition your collection process initialize
Modify your process-> conditions-> PLSQL Expressions->: REQUEST IS NULL
3. create a process more onload I say Add new line to the collection
DECLARE l_collection_name APEX_COLLECTIONS.COLLECTION_NAME%TYPE; BEGIN l_collection_name := 'EMAILDETAILS'; IF apex_collection.collection_exists(l_collection_name) THEN APEX_COLLECTION.ADD_MEMBER(p_collection_name => l_collection_name); END IF; END;
4 condition your Add new line to the collection
Modify your process-> conditions-> request = Expression1-> ADD (this should be request ADD button)
5. change your button-> Action addition-> redirect to this application page :-> page no (same page)->-> ADD APPLICATION
6. check your through the process conditional Page collection
Modify your process-> conditions-> PLSQL Expressions->: ASK IN ('ADD', 'APPLY_CHANGES', 'DELETE')
7. check your subject to the process of Collection to Table under condition
Modify your process-> conditions-> PLSQL Expressions->: ASK IN ('APPLY_CHANGES')
8. for the whole process to remove the conditions when the button is pressed.
If the problems persists, create a sample on apex.oracle.com and share the connection information with the name of workspace.
Hope this helps you,
Kind regards
Jitendra
-
How to refer to the primary key column of newly inserted rows of tabular form
Hello
I use APEX 4.2.0.00.27 with Oracle DB 11.2.0.3.0.
I work with a tabular presentation wizard-created for insert and update a table using the integrated SRM process (sequence 10). I'm trying to use a process of anonymous block of PL/SQL (sequence 30) to make another manipulation of table after the records were inserted or updated. The manual process is associated with my tabular form and I use the variables of name of column binding in my program block.
My (rsn_test) table has 3 columns: test_id (number), test_nbr (number), test_id2 (number). Test_id column is identified as the primary key and the type of the source already exists a sequence rsn_test_seq. Column test_id2 gets its default value 0 to a hidden page element.
I would use my manual process for updating the value of the test_id2 column. If it's 0 then I want to put the value of the column test_id. If it is any other value, then it must remain at this value. My logic works very well for an existing line, but I'm running into a problem with the newly added lines. The new lines get inserted, but the test_id2 column remains the default value 0. I can tell the debugger that the SRM process is triggered first and inserts the line, then my manual dealing with fires. The problem seems to be that the connection variable: TEST_ID for the primary key column remains NULL after insertion. I don't know how to get the value of the column test_id of my newly created line to use in my PL/SQL block to my update.
Process of PL/SQL:
DECLARE BEGIN :P7_SHOW := NULL; :P7_SHOW := NVL(:TEST_ID2,555) || ' and ' || NVL(:TEST_ID,787) || ' and ' || NVL(:TEST_NBR,9999); IF :TEST_ID2 = 0 AND :TEST_ID IS NOT NULL THEN UPDATE rsn_test SET test_id2 = :TEST_ID WHERE test_id = :TEST_ID; ELSE :TEST_ID2 := :TEST_ID2; END IF; END;
Excerpt from the debugger:
0.01625 0.00010 Processes - point: ON_SUBMIT_BEFORE_COMPUTATION 0.01635 0.00008 Branch point: Before Computation 0.01643 0.00003 Process point: AFTER_SUBMIT 0.01646 0.00022 Tabs: Perform Branching for Tab Requests 0.01668 0.00008 Branch point: Before Validation 0.01676 0.00024 Validations: 0.01700 0.00135 Perform basic and predefined validations: 0.01835 0.00020 Perform custom validations: 0.01855 0.00049 ...Validation "TEST_NBR must be numeric" - Type: ITEM_IS_NUMERIC 0.01904 0.00007 ......Skip for row 1 because row hasn't changed 0.01911 0.00016 ......Skip for row 2 because row hasn't changed 0.01927 0.00012 ...Validation "TEST_ID2 must be numeric" - Type: ITEM_IS_NUMERIC 0.01939 0.00007 ......Skip for row 1 because row hasn't changed 0.01945 0.00018 ......Skip for row 2 because row hasn't changed 0.01964 0.00005 Branch point: Before Processing 0.01968 0.00004 Processes - point: AFTER_SUBMIT 0.01972 0.00588 ...Process "ApplyMRU" - Type: MULTI_ROW_UPDATE 0.02560 0.00154 ...Execute Statement: declare function x return varchar2 is begin begin for c1 in ( select "RSN_TEST_SEQ".nextval pk from sys.dual ) loop return c1.pk; end loop; end; return null; end; begin wwv_flow.g_value := x; end; 0.02714 0.00140 ......Row 3: insert into "APPPCSRSN"."RSN_TEST" ( "TEST_ID", "TEST_NBR", "TEST_ID2") values ( :b1, :b2, :b3) 0.02854 0.00011 ...Process "ApplyMRD" - Type: MULTI_ROW_DELETE 0.02865 0.00004 ......Skip because condition or authorization evaluates to FALSE 0.02869 0.00015 ...Process "Process Submit" - Type: PLSQL 0.02884 0.00007 ......Skip for row 1 because row hasn't changed 0.02891 0.00012 ......Skip for row 2 because row hasn't changed 0.02903 0.00012 ......Process row 3 0.02915 0.00429 ...Execute Statement: begin DECLARE BEGIN :P7_SHOW := NULL; :P7_SHOW := NVL(:TEST_ID2,555) || ' and ' || NVL(:TEST_ID,787) || ' and ' || NVL(:TEST_NBR,9999); IF :TEST_ID2 = 0 AND :TEST_ID IS NOT NULL THEN UPDATE rsn_test SET test_id2 = :TEST_NBR WHERE test_id = :TEST_ID; ELSE :TEST_ID2 := :TEST_ID2; END IF; END; end; 0.03344 0.00013 ...Session State: Saved Item "P7_SHOW" New Value="0 and 787 and 1300" 0.03356 0.00004 Branch point: After Processing 0.03360 0.00048 ...Evaluating Branch: "AFTER_PROCESSING" Type: REDIRECT_URL Button: (No Button Pressed) Condition: (Unconditional) 0.03407 0.00013 Redirecting to f?p=290:7:8717971109610:::::&success_msg=0%20row(s)%20updated%2C%201%20row(s)%20inserted.Success%2FEBD244168556408CBA714E3974918C09%2F 0.03420 0.00012 Stop APEX Engine detected 0.03432 0.00007 Stop APEX Engine detected 0.03439 - Final commit
Any suggestions?
I have run tests on
https://apex.Oracle.com/pls/apex/f?p=83488:1 demo/demo
to see your problem.
I have 2 solution for your problem.
I add trial NOT tabular just usual block of PL/SQLBEGIN I'm IN (SELECT TEST_ID FROM RSN_TEST WHERE TEST_ID2 = 0) LOOP UPDATE RSN_TEST SET test_id2 = TEST_ID WHERE test_id = i.TEST_ID; END LOOP; END; and works very well, you can see in the sample.
The other solution is to show new generated TEST_ID
Adding a sequence as a default value for a column in a table field
And to execute your procedure.
I get how is with the good luck of time.
By
-
Hello
Is it possible to add an apex_item to an existing query in tabular form, such as the one below?
SELECT APEX_ITEM. SELECT_LIST_FROM_QUERY (3, job, 'Employment SELECT DISTINCT FROM emp') job
WCP
It is an example that can be found at APEX_ITEM.
My actual query is as follows:
Select
"ROWID",.
"REF."
"DESCR",.
APEX_ITEM. SELECT_LIST_FROM_QUERY (10, code, 'SELECT code FROM lov') 'CODE '.
of ' #OWNER # '. " LOVREF ".
The report definition, I put the element 'Code' as 'List of selection (query based LOV)' and I get the following error when I run the report:
report error: ORA-20001: Error fetching column value: ORA-20001: Query must begin with SELECT or WITH
Code Can someone please say if the use of APEX_ITEM. SELECT_LIST_FROM_QUERY is valid in tabular form?
Thanks in advance
Yes, but your column definition must use "column of report Standard", if you want to use apex_item.
-
Button to apply tabular form - can I just update region c. send this page?
Hi all -
I have a tabular form of base with a button apply. After the button is clicked the MRU is done properly, but it then triggers a sending of full page. I would rather just refresh the region like nothing else on the page requires a refresh. If I create a dynamic action, I think that I need the pl/sql to do the update and I hope I can find an easier way around this.
The only action the button options are send page, redirect to a page or the url and "defined by the dynamic action. I'm on request Express 4.1.0.00.32.
I hope it's something really basic but I have ideas or suggestions,
JohnHi John,.
If you want to stay with the built-in feature in a table, as the process of page MRU, optimistic locking, etc., then you need send a page and the full reload. You can easily navigate the game following lines using partial page refresh and also make sort. But for writing data in the database, you must send the page. Especially if you have extra in the form of validations and related processes. Of course, you could go entirely manual, write your own JavaScript to collect the data from all the tables in table form and submit this via an AJAX request and initiate an update of only the region in table form. But you loose some features in doing so.
We are looking for in this, addressing a new component to edit grid several rows before us for inclusion in the APEX 5.0:
http://www.Oracle.com/technetwork/developer-tools/Apex/application-express/Apex-sod-087560.html
... However for the moment, I would strongly recommend to stick to submit to full page and reload in this case.
Kind regards
Marc -
How to validate the columns in tabular form date?
Hello
I have two columns in tabular form date
1.start_date 2.End_date so here I need validate the end_date shouldn't be less than column start_date
so any solution for this?Hello
use a validation of type "Function returning a Boolean" and the following code:
IF to_date(:YOUR_END_DATE,'YYYY-MM-DD') < to_date(:YOUR_START_DATE,'YYYY-MM-DD') THEN RETURN FALSE; ELSE RETURN TRUE; END IF;
The date format is of course your choice.
I hope this helps...
Thank you
Sandro -
Upgrade to 4.0 shows no data found on tabular forms
Hello
After the upgrade from 3.x and 4.0, an application that had many tabular forms does now show "no data found" in their respective regions. A few pages work, while others do not.
Curiously, if I take the same sql in the source box and create a new page from scratch, the new tabular form displays data correctly. It seems to be a problem with the upgrade. In one case, it's a very simple "select col1, col2 sample_table etc"type of syntax. " Nothing complex here.
I wanted to see if others have experienced.
Flipping through the Setup log, I can't find any errors. The validation stage shows also all own compiled objects.
Thank you!
ErikErik,
We have listed this problem on our questions about page:
http://www.Oracle.com/technology/products/database/application_express/HTML/4.0_known_issues.html
Search bug 9879227. We are working on this resolution in the APEX 4.0.1.
Kind regards
Marc -
Hi people
Couple of Qs:
1 special session of collections, or is it to me to give them unique names?
2 collections can be used as a source for a tabular form can be updated by simply replacing the source of the region with something in the sense of
SELECT c001,..., cnnn
OF htmldb_collections
WHERE collection_name = MY_COLLECTION'
or I have to be a little smarter?
TiA
Steve(1) Yes. The collections are specific to the session. They are only available for this session. If you need to see data outside the session, store it in a table.
(2) Yes. The collections are a great way to create tabular forms, that control you. They take a bit of effort, but can be very powerful. If you choose to use a collection for a tabular presentation, I recommend to create three procedures to manage them. The first is a process of page (PL/SQL) that fires when the page is loaded and fills your collection. The second is a page (PL/SQL) process that updates your collection with user values and lights BEFORE validation. The last is a process page that fires AFTER validations and writes the changes to your database.If you want a quick explanation, let me know and I'll walk you through an example.
-
Form Validation failure: "value is not a date and time in the format"
Hello world
I am facing a weird problem in my custom OAF page. I'm displaying the records of a particular table through dynamic VO and dynamic array. All records appear correctly. But when I try to click on NEXT 10 records in a table, I get the error like "FAILED FORM VALIDATION: 1000 ORG CUST BO VERSION is not a date and time in the format. Just like in the screenshot below.
Strange part of the question, if I select the columns to display not related to this day, so I only am not facing problems. If I select only dates to display and also am not facing this problem. If I use the mixture of this type varchar2 and data, I get this error.
I tried to change the type of data but no use.
If we close, look at the PARTY_ID error message trying to copy its data to ORG_CUST_BO_VERSION the last column. Why what's happening clue me less. Can anyone guide me on this please?
The problem is that you use the same name for the creation of the MessageTextInputBean inside the Table.
The name of MessageTextInputBean make it dynamic.
ex: -.
OAMessageTextInputBean oamessage = (OAMessageTextInputBean) createWebBean (pageContext,
MESSAGE_TEXT_INPUT_BEAN,
NULL,
'text' + columnNo);
See you soon
AJ
-
Call skillbuilder tabular form modal plugin
Hello
I have a tabular presentation, which I try to call the modal skillbuilders one of the columns page.
The field I want to use to pass the modal page ID can be null, so I put a bit of functionality in the display only the link, if the ID is filled.
I used the modal plugin before, but don't ever use this kind of functionality (from link on status of tabular form) as I have always previously used a button and assigned the id.
Can someone advise how to assign the field WIP_TRACKING ID please that I can use to go to modal page?
The tables SQL code is below:
SELECT COMMENT_ID, COMMENT_ID COMMENT_ID_DISPLAY, APPLY_COMMENT_TIMING, CUSTOMER_NUMBER, ITEM_NUMBER, SAP_NSC_NAME, SAP_CUSTOMER, SET_STOP_INFLATING_ODR_SSD, COMMENT_TEXT, DISABLED_FLAG, CASE WHEN NVL(APPLY_COMMENT_TIMING,-1) =3 THEN '<a href="' || 'f?p=&APP_ID.:2:&SESSION.::&DEBUG.::' || 'P2_COMMENT_ID:' || COMMENT_ID || '">' || '<img src="#IMAGE_PREFIX#edit_big.gif" alt="">' || '</a>' ELSE 'Not Tracked' END WIP_Tracking FROM #OWNER#.XXMEL_CPE_COMMENTS
Cashy,
You didn't say if your Apex 4 or 5. So better idea is now under the HTML code, or add custom attributes id = "
". Laurent
Maybe you are looking for
-
I have Norton Security Suite provided by Comcast. Norton Toolbar does not work with Firefox 17.0.1 on my Win 7 machine. I lived all the questions on this topic and did all the steps and when I click on "Add-ons", he always says that the toolbar is no
-
Adding pictures and links to the email signature
This has been a problem for years, and many people complained to this topic. There are thousands of messages. Why Apple does not take care of this? I am trying to create a professional signature with our Facebook, Twitter and Instagram links. But I w
-
-Original Message- De : Germano To: Microsoft community Envoy: Thursday, April 25, 2013 20:00 Topic: punto di ripristino -Original Message- De : Microsoft community To: * E-mail address is removed from the privacy * Envoy: Monday, April 22, 2013 17:0
-
Update: change of hard - ssd drive
Product: computer hp laptop dv4 1220 USI'm lucky my HARD for one SSD drive, but I can not found in bios setup how to change sata ahci mode.
-
Help: XP drivers for computer laptop dv6950ep
Hello. I recently downgraded to XP from Vista on my laptop dv6700, model No. dv6950ep. I managed to install most of the hardware, but I can't find the drivers work for the sound card or the card wired ethernet. Help, please.