Element Input Validation - Table Values
Hi All,
Forum newbie.
Can anyone tell me if its possible to do an Element Input Validation that is using table values?
eg.
This was my thinking -
DEFAULT FOR TableLower IS 0
DEFAULT FOR TableUpper IS 0
INPUTS ARE entry_value (text)
entry = TO_NUM(entry_value)
Lower = TO_NUM(GET_TABLE_VALUE('Table Selected', 'Level', TableLower))
Upper = TO_NUM(GET_TABLE_VALUE('Table Selected', 'Level', TableUpper))
IF entry > Upper OR entry < Lower THEN
formula_status = 'E'
formula_message = 'Entry Value Must Be In The Table Range 1'
ELSE
formula_status = 's'
RETURN formula_status, formula_message
Any help would be very much appreciated.
Dean
Hello,
It is possible to use GET_TABLE_VALUE function in element input validation.
Thanks,
Sudhakar
Similar Messages
-
기존 ELEMENT에 INPUT VALUE를 추가하는 방법
제품 : HR_PER
작성날짜 : 2005-11-23
기존 ELEMENT에 INPUT VALUE를 추가하는 방법
================================
Explanation
기존 Element에 Input Value를 하나 더 생성해서 DB Item으로 값을 읽고 싶은데 Input Value추가가 안되네요. 어떻게
추가하는 방법이 없을까요?
### Steps to Reproduce ###
HRMS Manager > 보상합계 > 기본 > 항목내용 화면에서 입력값버튼을 눌러 입력값을 추가하고 싶음.
### CAUSE DETERMINATION ( Not required for Question-Answer issues) ###
### SOLUTION / ACTION PLAN OR ANSWER ###
Note : 175552.1
"Maintaining Elements
After you have defined and used an element, you can make the
following changes:
-Change a required input value to be not required.
-Alter the sequence in which input values appear in the Element
Entries window.
-Change the input value validation rules for minimum,
maximum, lookup, or formula.
-Change your specification of which input values create Database
Items. Note, however, you cannot remove Database Items if they
are used in any formulas or QuickPaint reports.
-You cannot remove existing input values or add new ones if you have
created any entries for the element."
Note : 334953.1
Symptoms
o Tried to add an Input Value to an existing element.
The links to the element were end-dated on 29-Jul-2005
o Navigation: Total Compensation --> Basic --> Element
Description, Bring up input values form, and try to add a new input value.
Error happens
o Error message:
'FRM-41051: You cannot create records here
o Expect to be able to enter new input values.
o Happening in patch instance
Cause
The Error 'FRM-41051: You cannot create records here' arises because there are existing element entries for this element.
An input value cannot be added to an element if element entries exist for that element or input
value date is greater than the start date of the element.
Internal Bug:710550 : CAN'T MODIFY OR ADD NEW RECORDS INTO THE INPUT VALUES FOR AN ELEMENT
States the following:
"General rule is:
Insert of new IVs is not allowed when any element entries or run results for the element type exist.
I understand this is not the case here as there is no link for the element but can this be verified again.
This functionality is controlled via CONTROL_INPUT_VALUE_INSERTION procedure.
Insert of input values is not allowed when:
element_entries_exist or
no_of_input_values for the element is > 15 or
:ctl_globals.session_date != element_start_date "
Bug 809105 : CANNOT ADD INPUT VALUES TO EXISTING ELEMENT (PAYWSDET)
States:
The business rule quoted in Bug 710550 also states that you cannot add a new
input value if element entries exist for this element - please check that this
is not the case here.
Note 269070.1
Title: Cannot Create A User Defined Input Value For A State
Retirement Plan Deduction Element
Symptoms
In the element description form you cannot add new input values for a deduction element. You get
this error when creating new input value:
FRM-41051 You cannot create records here
The deduction element is a newly created element.
Cause
When adding the input values Datetrack date was not proper.
Fix
Make sure there are no element entries existing for the element.
Make sure to date track to the date when the element was created.
Solution
Because the application looks at three conditions before it will allow you to add an input value
to an element, if one of those conditions are met it will not allow you to create the element entry.
In your case 2 are being met so the system will not allow you to create the element entry.
1- element entries exist
2- state date of the new input value is greater than the element start date
Conditions being looked at:
element_entries_exist or
no_of_input_values for the element is > 15 or
:ctl_globals.session_date != element_start_date
There is no workaround for scenario, you need to create a new element.
결과적으로 말씀드리면, 한번 입력된 Element에 대해서는
아래의 두가지 속성을 모두 충족하지 않는 한,
Input Value를 추가로 입력하실 수 없습니다.
신규로 Element를 지정해주셔야 합니다.
1. Make sure there are no element entries existing for the element.
==> 해당 Element에 대한 Element Entry가 없어야 합니다.
2. Make sure to date track to the date when the element was created.
==> 신규 Input Value를 입력하려는 DateTrack날짜가 Element가 생성된 날짜와 같아야 합니다.
Reference Documents
Note : 334953.1 Paywsdet Error 'FRM-41051: You cannot create records here' when Trying to Add an Input Value to an Existing Element.
Note : 175552.1 How To Add A New Input Value To An Existing Element ? -
How to insert a value in the Validity Table with Report ABAP
Hi,
I should insert in the validity table in the field "To Mode" the value "R" through a report ABAP.
Is possible? Have I seen that the exist FM RSDV_INSERT_VALID_TAB. Is possible to use ? As?
Thanks.Hi, thanks the same to everybody. I have already resolved.
Regards.
Charly1 -
Validation by using Database Table Values
Dear Experts,
Please suggest us how can we validate the user input values with our database table values in ADF.
thanks in advance
Shiv NareshTake a look at Edwin Biemonds blogpost.
Using database tables as authentication provider in WebLogic
http://biemond.blogspot.de/2008/12/using-database-tables-as-authentication.html -
How to bind internal table values with RootUIElement(Table) from select Que
Hello Friends,
In my view Layout,there r two Input fields ,Submit button and Table... My concept is when user posting values in two input fields and clicking submit button means the result(more than one values) should be displayed in Table...
I written coding also but i dont know to bind internal table values with Table... My code as follows,
method onactionsearch .
data:
Node_Node_Flight type ref to If_Wd_Context_Node,
Elem_Node_Flight type ref to If_Wd_Context_Element,
Stru_Node_Flight type If_View1=>Element_Node_Flight ,
itab TYPE STANDARD TABLE OF sflight.
navigate from <CONTEXT> to <NODE_FLIGHT> via lead selection
Node_Node_Flight = wd_Context->get_Child_Node( Name = IF_VIEW1=>wdctx_Node_Flight ).
@TODO handle not set lead selection
if ( Node_Node_Flight is initial ).
endif.
get element via lead selection
Elem_Node_Flight = Node_Node_Flight->get_Element( ).
@TODO handle not set lead selection
if ( Elem_Node_Flight is initial ).
endif.
alternative access via index
Elem_Node_Flight = Node_Node_Flight->get_Element( Index = 1 ).
@TODO handle non existant child
if ( Elem_Node_Flight is initial ).
endif.
get all declared attributes
Elem_Node_Flight->get_Static_Attributes(
importing
Static_Attributes = Stru_Node_Flight ).
select * from sflight into CORRESPONDING FIELDS OF TABLE itab
WHERE carrid = Stru_Node_Flight-carrid and connid = Stru_Node_Flight-connid.
Node_Node_Flight->bind_table( new_items = itab ).
endmethod.
Plz reply me asap...!Hi,
What I understood from your coding is...
* navigate from <CONTEXT> to <NODE_FLIGHT> via lead selection
Node_Node_Flight = wd_Context->get_Child_Node( Name = IF_VIEW1=>wdctx_Node_Flight ).
You are reading values from the above node and binding the values to the same node.Am i right?
Did you take seperate context node for your input fields or binded the above context to the fields.If not then read the context attribute values which are binded to the carrid and connid then pass these values to select query.
One more thing is select cardinality 1..n for node NODE_FLIGHT since you are displaying more than one record.
Go through the some basic tutorials.Search in sdn you will it get.Already there is a tutorial in sdn which explains exactly what do you require.
Go throgh this link
Web Dynpro for ABAP: Tutorials for Beginners
Web Dynpro for ABAP: Tutorials for Beginners [original link is broken]
Edited by: suman kumar chinnam on Mar 26, 2009 10:50 AM -
Passing table values from one webdypro screen to the next in BPM flow
Hi,
I have a BPM scenario where in User 1 will be entering data on a java webdynpro view in the form of a table. The user 1 should be able to edit contents of the table.
These set of values in the table from User 1 needs to be passed to User 2 through BPM. The User 2 should be able to read the values edited by User 1 in the table.
Please could you suggest how we could map the table attribute?
With respect to Context Elements, I have a Node created for the table. But, the data doesnot seem to pass from User 1 to User 2.
Any suggestions on this would be extemely helpful.
Thank You.Hi,
Please follow the below mentioned steps:
Create a Human Activity containing the task(WebDynpro Task) to edit the table values.
Create a data context of type (Context of the table node used in the Webdynpro task).
Map the output of the human activity to the input of the data context.
Create another human activity that contains the task to read the values of task1
Assign this task to User 2
Map the output of data context with the input of the second human activity.
Regards,
Gayathri -
Problem with passing table values to RFC
Hi all,
I am passing values in table in RFC. There are no import/export parameters in RFC. We are passing only tables.
There are two tables in the RFC I_Dept and I_Subdept. Initially RFC is executed for getting the Dept which works fine as for this there is no need to set in input table value. But to get sub department I need to set the dept in I_Dept and after executing RFC I should get values in table I_Subdept. The code is as below:
wdContext.nodeOutput_I_Dept().invalidate();
wdContext.nodeOutput_I_Subdept().invalidate();
Z_Bapi_Dept_Values_Input d_Input = new Z_Bapi_Dept_Values_Input();
wdContext.nodeZ_Bapi_Dept_Values_Input().bind(d_Input);
Zdept dept = new Zdept();
dept.setZname("Sales");
d_Input.addI_Dept(dept);
try
wdContext.nodeZ_Bapi_Dept_Values_Input().currentZ_Bapi_Dept_Values_InputElement().modelObject().execute();
wdContext.nodeZ_Bapi_Dept_Values_Input().nodeOutput().invalidate();
catch (WDDynamicRFCExecuteException e)
msgManager.reportException(e.toString(), true);
Is anything wrong in this code because even after executing the RFC the size of node I_Subdept() is zero. But the RFC works fine in the backend.
Regards,
JaydeepA typical misunderstanding when populating structured input data
via code is the following:
- You have bound a WD context node hierarchy to the model say
N1 > M1
->N2 > ->M2
where N1, N2 are WD Context nodes (N2 is child of N1) and M1, M2 are
model classes bound to the context nodes. Important: M1 has a relation
to M2 on the model side, means there is some method M1.setMyM2(M2)
(assuming the target role of the relation is called "MyM2").
- You create context elements for N1 and N2 which are bound to a model
class instances of M1 and M2 respectively.
Assuming that M1 is the "executable" model class (*_Input) and M2
represents an input structure needed, the M2-input will - using the
above approach - not be available on execution. Why? The relation on the
model side (MyM2) is not available if just maintaining it via the
context, i.e. context and model are not "in sync". As RFC execution is
done via the model the M2 input will not be available.
You best create complex/nested input structures on the model
side and then bind the top-level model object to the resp context node.
In the above sample this would be:
M1 m1ModelObject = new M1();
M2 m2ModelObject = new M2();
m1ModelObject.setMyM2(m2ModelObject);
Hope it helps!
Regards,
Sangeeta -
Submititng the program to another program using internal table values
Hi All,
How to Submit from one program to another program using internal table values minimum 7 int tables without using the seletion screen
thanks
rajHi All,
Thank you very much for your inputs.
i am facing another issue:
For each 10,000 records it should trigger a job (we are trying to call a program) were the validation will be done only through the other program.
please find the code mentioned below :
TABLES : but000.
DATA: int_bp LIKE but000 OCCURS 0 WITH HEADER LINE.
data released like BTCH0000-CHAR1.
DATA: jobnumber LIKE tbtcjob-jobcount, " Job ID and
jobname LIKE tbtcjob-jobname, " job name.
startdate LIKE tbtcjob-sdlstrtdt, " Start-time
starttime LIKE tbtcjob-sdlstrttm, " window specs.
laststartdate LIKE tbtcjob-laststrtdt,
laststarttime LIKE tbtcjob-laststrttm,
job_released LIKE btch0000-char1. " JOB_CLOSE: Was job released?
DATA : l1 TYPE i,
b_size TYPE i,
b_cursor TYPE cursor.
INITIALIZATION.
b_size = 5000.
START-OF-SELECTION.
OPEN CURSOR WITH HOLD b_cursor
FOR
SELECT *
FROM but000
WHERE bpkind = 'AA'.
IF sy-subrc = 0.
DO.
FETCH NEXT CURSOR b_cursor INTO TABLE int_bp
PACKAGE SIZE b_size.
Note : here in this point we are getting a dump for the second job trigger.
IF sy-subrc = 0.
CLEAR jobname.
CONCATENATE sy-repid sy-datum sy-uzeit INTO jobname.
export int_bp to memory id 'ABC'.
CALL FUNCTION 'JOB_OPEN'
EXPORTING
jobname = jobname
IMPORTING
jobcount = jobnumber.
EXCEPTIONS
cant_create_job = 1
invalid_job_data = 2
jobname_missing = 3
OTHERS = 4
CALL FUNCTION 'JOB_SUBMIT'
EXPORTING
authcknam = sy-uname
jobname = jobname
jobcount = jobnumber
report = 'YTEST_RRR'.
variant = lv_variant.
SUBMIT ytest_rrr
VIA JOB jobname NUMBER jobnumber
AND RETURN.
CALL FUNCTION 'JOB_CLOSE'
EXPORTING
event_periodic = 'X'
jobcount = jobnumber
jobname = jobname
strtimmed = 'X'
IMPORTING
job_was_released = released
else.
EXIT.
ENDIF.
ENDDO.
calling program :
REPORT YTEST_RRR .
data itab1 like but000 occurs 0 with header line.
data l type i.
import itab1 from memory id 'ABC' .
describe table itab1 lines l.
free memory id 'ABC'.
write:/ 'total records are:', l.
Please give your suggestion why its going for dump in the second iteration.
thanks in advance. -
Selecting multiple rows a table according to rows passed with a table valued parameter
Ive got a table, which looks like this:
CREATE TABLE MyTable (
MyChars CHAR(3) NOT NULL,
MyId INT NOT NULL,
CONSTRAINT PK__MyTable_MyChars_MyId PRIMARY KEY (MyChars, MyId),
CONSTRAINT FK__MyOtherTable_Id_MyTable_MyId FOREIGN KEY (MyId) REFERENCES MyOtherTable (Id)
Records look like i.e.:
Chars | Id
'AAA' | 1
'BBB' | 1
'CCC' | 1
'AAA' | 2
'BBB' | 2
'CCC' | 2
'DDD' | 2
'EEE' | 3
'FFF' | 3
'AAA' | 4
'DDD' | 4
'FFF' | 4
Now I have a SP, which takes a table valued parameter like:
CREATE TYPE dbo.MyTVP AS TABLE ( MyChars CHAR(3) )
This SP should return a set of Ids, which match all the rows of the parameter.
I.e.:
if the TVP contains 'AAA', 'BBB' & 'CCC', i get as result 1 & 2
if the TVP contains 'AAA' & 'FFF', i get as result 4
if the TVP contains 'BBB' & 'EEE', i get an empty result
What my SP is currently doing, is to build a query with string concatination, which is then executed with the EXEC statement. If we take my first example, the built query would look like this:
SELECT DISTINCT t0.MyId
FROM MyTable t0
INNER JOIN MyTable t1 ON t0.MyId = t1.MyId
INNER JOIN MyTable t2 ON t1.MyId = t2.MyId
WHERE t0.MyChars = 'AAA' AND t1.MyChars = 'BBB' AND t2.MyChars = 'CCC'
It works, but I'm not very fond of building the query. Maintaining such things is always a pain. And it also might not be the most efficient and elegant way to do this.
Since I can't think of any other way of doing this, I wanted to ask, if someone of you got an idea, if there is a better way to accomplish this.Let me give you a "cut and paste" I use in the SQL Server groups:
1) The dangerous, slow kludge is to use dynamic SQL and admit that any random future user is a better programmer than you are. It is used by Newbies who do not understand SQL or even what a compiled language is. A string is a string; it is a scalar value like
any other parameter; it is not code. Again, this is not just an SQL problem; this is a basic misunderstanding of programming principles.
2) Passing a list of parameters to a stored procedure can be done by putting them into a string with a separator. I like to use the traditional comma. Let's assume that you have a whole table full of such parameter lists:
CREATE TABLE InputStrings
(keycol CHAR(10) NOT NULL PRIMARY KEY,
input_string VARCHAR(255) NOT NULL);
INSERT INTO InputStrings
VALUES ('first', '12,34,567,896'),
('second', '312,534,997,896'),
etc.
This will be the table that gets the outputs, in the form of the original key column and one parameter per row.
It makes life easier if the lists in the input strings start and end with a comma. You will need a table of sequential numbers -- a standard SQL programming trick, Now, the query,
CREATE VIEW ParmList (keycol, place, parm)
AS
SELECT keycol,
COUNT(S2.seq), -- reverse order
CAST (SUBSTRING (I1.input_string
FROM S1.seq
FOR MIN(S2.seq) - S1.seq -1)
AS INTEGER)
FROM InputStrings AS I1, Series AS S1, Series AS S2
WHERE SUBSTRING (',' + I1.input_string + ',', S1.seq, 1) = ','
AND SUBSTRING (',' + I1.input_string + ',', S2.seq, 1) = ','
AND S1.seq < S2.seq
GROUP BY I1.keycol, I1.input_string, S1.seq;
The S1 and S2 copies of Series are used to locate bracketing pairs of commas, and the entire set of substrings located between them is extracted and cast as integers in one non-procedural step. The trick is to be sure that the right hand comma of the bracketing
pair is the closest one to the first comma. The relative position of each element in the list is given by the value of "place", but it does a count down so you can plan horizontal placement in columns.
This might be faster now:
WITH Commas(keycol, comma_seq, comma_place)
AS
(SELECT I1.keycol, S1.seq,
ROW_NUMBER() OVER (PARTITION BY I1.keycol ORDER BY S1.seq)
FROM InputStrings AS I1, Series AS S1
WHERE SUBSTRING (',' || I1.input_string || ','
FROM S1.seq
FOR 1) = ','
AND S1.seq <= CHARLENGTH (I1.input_string))
SELECT SUBSTRING(',' || I1.input_string || ','
FROM C1.comma_place +1
FOR C2.comma_place - C1.comma_place - 1)
FROM Commas AS C1, Commas AS C2
WHERE C2.comma_seq = C1.comma_seq + 1
AND C1.keycol = C2.keycol;
The idea is to get all the positions of the commas in the CTE and then use (n, n+1) pairs of positions to locate substrings. The hope is that the ROW_NUMBER() is faster than the GROUP BY in the first attempt. Since it is materialized before the body of
the query (in theory), there are opportunities for parallelism indexing and other things to speed up the works.
Hey, I can write kludges with the best of them, but I don't. You need to at the very least write a routine to clean out blanks, handle double commas and non-numerics in the strings, take care of floating point and decimal notation, etc. Basically, you must
write part of a compiler in SQL. Yeeeech! Or decide that you do not want to have data integrity, which is what most Newbies do in practice altho they do not know it.
A procedural loop is even worse. You have no error checking, no ability to pass local variables or expressions, etc.
CREATE PROCEDURE HomemadeParser(@input_string VARCHAR(8000))
AS
BEGIN
DECLARE @comma_position INTEGER;
CREATE TABLE #Slices
(slice_value INTEGER);
SET @input_string = @input_string + ','; --add sentinel comma
SET @comma_position = CHARINDEX(',', @input_string);
WHILE @comma_position > 1
BEGIN
INSERT INTO #Slices (slice_value)
VALUES(CAST(LEFT(@input_string, (@comma_position - 1)) AS INTEGER));
SET @input_string = RIGHT(@input_string, LEN(@input_string)-@comma_position)
SET @comma_position = CHARINDEX(',', @input_string)
END;
END;
Better answer:
http://www.simple-talk.com/sql/learn-sql-server/values()-and-long-parameter-lists/
http://www.simple-talk.com/sql/learn-sql-server/values()-and-long-parameter-lists---part-ii/
Do this with a long parameter list. You can pass up to 2000+ parameters in T-SQL, which is more than you probably will ever need. The compiler will do all that error checking that the query version and the procedural code simply do not have unless you write
a full parser with the standard error codes. You can now pass local variables to your procedure; you can pass other data types and get automatic conversions, etc. In short, this is just good software engineering.
CREATE PROCEDURE LongList
(@p1 INTEGER = NULL,
@p2 INTEGER = NULL,
@p3 INTEGER = NULL,
@p4 INTEGER = NULL,
@p5 INTEGER = NULL)
x IN (SELECT parm
FROM (VALUES (@p1), (@p2), (@p3), (@p4), (@p5)) AS X(parm)
WHERE parm IS NOT NULL;
You get all the advantages of the real compiler and can do all kinds of things with the values.
--CELKO-- Books in Celko Series for Morgan-Kaufmann Publishing: Analytics and OLAP in SQL / Data and Databases: Concepts in Practice Data / Measurements and Standards in SQL SQL for Smarties / SQL Programming Style / SQL Puzzles and Answers / Thinking
in Sets / Trees and Hierarchies in SQL -
How to do input validation in BDC's?
hai,
I am Rajesh, I want to know how and where to write input validation code in BDC's. Please help me on this.
Thanking youHi and welcome
all key-fields (and fields with a check-table) are checked by SAP-standard in your called transaction in BDC too.
if you want to validate additional:
1)load you data from flat file into itab
2)check fields:
-against checktable
-format (date,currency)
-value
A.
pls reward usful answers
Message was edited by: Andreas Mann -
How to update the table value in the valuechange event?
I have an input field in the datatable with the valueChangeListener
<rich:dataTable id="cart" value="#{cart.cartList}" var="item">
<h:inputText value="#{item.cost}" id="qty" valueChangeListener="#{items.updateCost}" onchange="submit()">
<h:outputText value="#{item.errorMsg}"> </h:outputText>
in the backing bean
Item item = (Item) model.getRowData();
// do some update, if the cost too larger, change to max_cost
item.setCost(max_cost);
item.setErrorMsg("Error Msg");
After calling the valuechange method, the screen output doesn't update the cost.
How to update the table value in the valuechange event?As you're misusing the valueChangeListener to set another input field, you need to skip the update model values phase. Otherwise the value set in the valueChangeListener will be overridden by the submitted value. You can do this by calling the FacesContext#renderResponse() inside the valueChangeListener method. This will shift the current phase immediately to the render response phase, hereby skipping the update model values and invoke application phases.
-
I need to validate Input List Of Values Field when Inserted From Bean
I've two view object EmployeeView and DepartmentsView
In Employee View I've changed Department_Id to Input List OF Values
I've created a bean to inset data into Employee Table
ApplicationModule am = ADFUtils.getApplicationModuleForDataControl("AppModuleDataControl");
ViewObject importedVO = am.findViewObject("EmployeesView");
try {
newEmp.setEmployeeId(new Number("3424));
newEmp.setFirstName("Test Fname");
newEmp.setLastName("Test Lname");
newEmp.setEmail("[email protected]");
newEmp.setPhoneNumber("4643131345");
newEmp.setJobId("AD_VP");
newEmp.setDepartmentId(new oracle.jbo.domain.Number(999));
} catch (Exception e) {
// TODO: Add catch code
System.out.println("inside Catch");
e.printStackTrace();
}I know that ADF validate Input list of values when inserting new value on it
when I've enabled the debugger I've found that
<ViewObjectImpl><buildQuery> [604] SELECT DepartmentsEO.DEPARTMENT_ID, DepartmentsEO.DEPARTMENT_NAME, DepartmentsEO.MANAGER_ID, DepartmentsEO.LOCATION_ID, DepartmentsEO.ISDELETED FROM DEPARTMENTS DepartmentsEO WHERE ( ( (DepartmentsEO.DEPARTMENT_ID = :vc_temp_1 ) ) )
<ViewObjectImpl><bindParametersForCollection> [605] Bind params for ViewObject: [com.test.model.views.DepartmentsEOView]AppModule.__LOCAL_VIEW_USAGE_com_test_model_views_EmployeesEOView_DepartmentsView_findByVC_12_LOV_DepartmentId_lov__filterlist__vcr___
<OracleSQLBuilderImpl><bindParamValue> [606] Binding param "vc_temp_1": 999
<ViewObjectImpl><processViewCriteriaForRowMatch> [607] VCs converted to RowMatch: ( (DepartmentId = :vc_temp_1 ) )
<ViewRowImpl><handleListBindingMismatch> [608] No matching row found for list binding:LOV_DepartmentId for ViewRow:oracle.jbo.Key[34235 ]
<ViewRowImpl><handleListBindingMismatch> [609] --- filterList ValueMap key:DepartmentId, value:999
<DCBindingContainer><internalRefreshControl> [610] **** refreshControl() for BindingContainer :com_test_view_testInsertPageDef
<JUCtrlHierNodeBinding><release> [611] released: ROOT node binding:noCtrl_oracle_adfinternal_view_faces_model_binding_FacesCtrlHierNodeBinding_2, value:EmployeesViewIterator
<JUCtrlHierNodeBinding><release> [612] released: ROOT node binding:noCtrl_oracle_adfinternal_view_faces_model_binding_FacesCtrlHierNodeBinding_2, value:EmployeesViewIterator
<DCIteratorBinding><releaseDataInternal> [613] Releasing iterator binding:EmployeesViewIterator
<ApplicationPoolMessageHandler><doPoolMessage> [614] **** PoolMessage REQ ATTACH LWS
<ApplicationPoolMessageHandler><doPoolMessage> [615] **** PoolMessage REQ DETACH LWS
<DCJboDataControl><initializeApplicationModule> [616] (oracle.adf.model.bc4j.DataControlFactoryImpl.SyncMode = Immediate
<DCBindingContainer><internalRefreshControl> [617] **** refreshControl() for BindingContainer :com_test_view_testInsertPageDef
<DCBindingContainerState><validateToken> [618] Process BindingContainer state token(decompressed state):BCST:=0%V%=NEmployeesViewIterator=-D-,
<this means that ADF tries to validate the input list of values "Department_Id" and didn't found any match
I need to through exception when I try to set Department_ID with invalid value "value not on range" like
newEmp.setDepartmentId(new oracle.jbo.domain.Number(999));I don't want to validate it manually as I've a lot of fields.
I need to through exception when try to
newEmp.setDepartmentId(new oracle.jbo.domain.Number(999));Thanks Timo
this is the code that I use
ApplicationModule am = ADFUtils.getApplicationModuleForDataControl("AppModuleDataControl");
ViewObject importedVO = am.findViewObject("EmployeesView");
EmployeesEOViewRowImpl newEmp = (EmployeesEOViewRowImpl)importedVO .createRow();
importedVO .insertRow(newEmp);
try {
newEmp.setEmployeeId(new Number("3424));
newEmp.setFirstName("Test Fname");
newEmp.setLastName("Test Lname");
newEmp.setEmail("[email protected]");
newEmp.setPhoneNumber("4643131345");
newEmp.setJobId("AD_VP");
newEmp.setDepartmentId(new oracle.jbo.domain.Number(999));
} catch (Exception e) {
// TODO: Add catch code
System.out.println("inside Catch");
e.printStackTrace();
} -
Access af:table values from JavaScript array (for google maps task)
Hi!
I have JSP page with af:table where latitude and longitude for google maps are stored. I am using these tutorial [https://blogs.oracle.com/middleware/entry/integrating_google_maps_with_adf] and I know how to access latitude and longitude from output text (for one point). Now i need to do something similar with loop for all table rows. How can I achieve this?
I have JavaScript code which uses Google Maps API and can display many points on one map. Also I have longitude and latitude data in af:table (bindings), each table row has one point. My task is to take data from af:table and pass it to JavaScript.
May be it is better to use managed bean as you said. Firstly I will access binding data from managed bean. Then I have to pass this data to JavaScript method? Can you suggest some example? I have "Using JavaScript in ADF Faces Rich Client Applications"My table is there :
<af:table value="#{bindings.LocView1.collectionModel}" var="row"
rows="#{bindings.LocView1.rangeSize}"
emptyText="#{bindings.LocView1.viewable ? 'No data to display.' : 'Access Denied.'}"
fetchSize="#{bindings.LocView1.rangeSize}" rowBandingInterval="0"
filterModel="#{bindings.LocView1Query.queryDescriptor}"
queryListener="#{bindings.LocView1Query.processQuery}" filterVisible="true" varStatus="vs"
selectedRowKeys="#{bindings.LocView1.collectionModel.selectedRow}"
selectionListener="#{bindings.LocView1.collectionModel.makeCurrent}" rowSelection="single"
id="t1">
<af:column sortProperty="#{bindings.LocView1.hints.SoffOffCode.name}" filterable="true"
sortable="true" headerText="#{bindings.LocView1.hints.SoffOffCode.label}" id="c1">
<af:outputText value="#{row.SoffOffCode}" clientComponent="true" id="ot1"/>
</af:column>
<af:column sortProperty="#{bindings.LocView1.hints.SoffCode.name}" filterable="true"
sortable="true" headerText="#{bindings.LocView1.hints.SoffCode.label}" id="c2">
<af:outputText value="#{row.SoffCode}" id="ot2"/>
</af:column>
<af:column sortProperty="#{bindings.LocView1.hints.SoffLat.name}" filterable="true"
sortable="true" headerText="#{bindings.LocView1.hints.SoffLat.label}" id="c3">
<af:outputText value="#{row.SoffLat}" clientComponent="true" id="ot3"/>
</af:column>
<af:column clientComponent="true" sortProperty="#{bindings.LocView1.hints.SoffLng.name}" filterable="true"
sortable="true" headerText="#{bindings.LocView1.hints.SoffLng.label}" id="c4">
<af:outputText value="#{row.SoffLng}" clientComponent="true" id="ot4"/>
</af:column>
<af:column sortProperty="#{bindings.LocView1.hints.SoffZoom.name}" filterable="true"
sortable="true" headerText="#{bindings.LocView1.hints.SoffZoom.label}" id="c5">
<af:outputText value="#{row.SoffZoom}" id="ot5"/>
</af:column>
</af:table>
Javascript code:
alert(document.getElementById("t1"));
Result:
[object HTMLDivElement];
And
alert(document.getElementById("t1").innerHTML);
Result:
<div id="t1::ch" style="overflow: hidden; position: relative; width: 366px;" _afrcolcount="5" class="xzg"><table class="xzi" summary="This table contains column headers corresponding to the data body table below" id="t1::ch::t" style="position:relative;table-layout:fixed;width:525px" cellspacing="0"><tbody><tr><th style="padding:0px;padding-left:5px;width:100px;"></th><th style="padding:0px;padding-left:5px;width:100px;"></th><th style="padding:0px;padding-left:5px;width:100px;"></th><th style="padding:0px;padding-left:5px;width:100px;"></th><th style="padding:0px;padding-left:5px;width:100px;"></th></tr><tr><th _d_index="0" _afrfiltercol="true" class="xzr" align="left" nowrap="nowrap"><span id="t1:_afrFltrc1" class="x1u"><input id="t1:_afrFltrc1::content" name="t1:_afrFltrc1" class="x25" type="text"></span></th><th _d_index="1" _afrfiltercol="true" class="xzr" align="left" nowrap="nowrap"><span id="t1:_afrFltrc2" class="x1u"><input id="t1:_afrFltrc2::content" name="t1:_afrFltrc2" class="x25" type="text"></span></th><th _d_index="2" _afrfiltercol="true" class="xzr" align="left" nowrap="nowrap"><span id="t1:_afrFltrc3" class="x1u"><input id="t1:_afrFltrc3::content" name="t1:_afrFltrc3" class="x25" type="text"></span></th><th _d_index="3" _afrfiltercol="true" class="xzr" align="left" nowrap="nowrap"><span id="t1:_afrFltrc4" class="x1u"><input id="t1:_afrFltrc4::content" name="t1:_afrFltrc4" class="x25" type="text"></span></th><th _d_index="4" _afrfiltercol="true" class="xzr" align="left" nowrap="nowrap"><span id="t1:_afrFltrc5" class="x1u"><input id="t1:_afrFltrc5::content" name="t1:_afrFltrc5" class="x25" type="text"></span></th></tr><tr><th id="t1:c1" _d_index="0" _afrleaf="true" _afrroot="true" class="xzj" align="left"><div style="position:relative; float:right"><table id="t1:c1::afrSI" _afrhoverable="true" style="display:none" class="x104" cellpadding="0" cellspacing="0"><tbody><tr><td _afrsortasc="1"><a tabindex="-1" class="xzm" title="Sort Ascending"></a></td><td _afrsortdesc="1"><a tabindex="-1" class="xzn" title="Sort Descending"></a></td></tr></tbody></table></div><div class="x19p">SoffOffCode</div></th><th id="t1:c2" _d_index="1" _afrleaf="true" _afrroot="true" class="xzj" align="left"><div style="position:relative; float:right"><table id="t1:c2::afrSI" _afrhoverable="true" style="display:none" class="x104" cellpadding="0" cellspacing="0"><tbody><tr><td _afrsortasc="1"><a tabindex="-1" class="xzm" title="Sort Ascending"></a></td><td _afrsortdesc="1"><a tabindex="-1" class="xzn" title="Sort Descending"></a></td></tr></tbody></table></div><div class="x19p">SoffCode</div></th><th id="t1:c3" _d_index="2" _afrleaf="true" _afrroot="true" class="xzj" align="left"><div style="position:relative; float:right"><table id="t1:c3::afrSI" _afrhoverable="true" style="display:none" class="x104" cellpadding="0" cellspacing="0"><tbody><tr><td _afrsortasc="1"><a tabindex="-1" class="xzm" title="Sort Ascending"></a></td><td _afrsortdesc="1"><a tabindex="-1" class="xzn" title="Sort Descending"></a></td></tr></tbody></table></div><div class="x19p">SoffLat</div></th><th id="t1:c4" _d_index="3" _afrleaf="true" _afrroot="true" class="xzj" align="left"><div style="position:relative; float:right"><table id="t1:c4::afrSI" _afrhoverable="true" style="display:none" class="x104" cellpadding="0" cellspacing="0"><tbody><tr><td _afrsortasc="1"><a tabindex="-1" class="xzm" title="Sort Ascending"></a></td><td _afrsortdesc="1"><a tabindex="-1" class="xzn" title="Sort Descending"></a></td></tr></tbody></table></div><div class="x19p">SoffLng</div></th><th id="t1:c5" _d_index="4" _afrleaf="true" _afrroot="true" class="xzj" align="left"><div style="position:relative; float:right"><table id="t1:c5::afrSI" _afrhoverable="true" style="display:none" class="x104" cellpadding="0" cellspacing="0"><tbody><tr><td _afrsortasc="1"><a tabindex="-1" class="xzm" title="Sort Ascending"></a></td><td _afrsortdesc="1"><a tabindex="-1" class="xzn" title="Sort Descending"></a></td></tr></tbody></table></div><div class="x19p">SoffZoom</div></th></tr></tbody></table></div><div id="t1::db" class="xz9" style="position: relative; width: 366px; overflow: hidden; height: 521px; z-index: 1;" _afrcolcount="5"><table class="xza x102" style="table-layout:fixed;position:relative;width:525px;" _totalwidth="525" _selstate="{'0':true}" _rowcount="179" _startrow="0" cellspacing="0"><tbody><tr _afrrk="0" class="xzy p_AFSelected"><td style="width:100px;" class="xzv" nowrap="nowrap"><span id="t1:0:ot1">26</span></td><td style="width:100px;" class="xzv" nowrap="nowrap">01</td><td style="width:100px;" class="xzv" nowrap="nowrap"><span id="t1:0:ot3">47.90782714384932</span></td><td style="width:100px;" class="xzv" nowrap="nowrap"><span id="t1:0:ot4">106.88643654861448</span></td><td style="width:100px;" class="xzv" nowrap="nowrap">15</td></tr><tr _afrrk="1" class="xzy"><td class="xzv" nowrap="nowrap"><span id="t1:1:ot1">26</span></td><td class="xzv" nowrap="nowrap">02</td><td class="xzv" nowrap="nowrap"><span id="t1:1:ot3">47.91542113773543</span></td><td class="xzv" nowrap="nowrap"><span id="t1:1:ot4">106.88540658035276</span></td><td class="xzv" nowrap="nowrap">15</td></tr><tr _afrrk="2" class="xzy"><td class="xzv" nowrap="nowrap"><span id="t1:2:ot1">26</span></td><td class="xzv" nowrap="nowrap">03</td><td class="xzv" nowrap="nowrap"><span id="t1:2:ot3">47.90768330745696</span></td><td class="xzv" nowrap="nowrap"><span id="t1:2:ot4">106.89544877090452</span></td><td class="xzv" nowrap="nowrap">15</td></tr><tr _afrrk="3" class="xzy"><td class="xzv" nowrap="nowrap"><span id="t1:3:ot1">26</span></td><td class="xzv" nowrap="nowrap">04</td><td class="xzv" nowrap="nowrap"><span id="t1:3:ot3">47.90716549312801</span></td><td class="xzv" nowrap="nowrap"><span id="t1:3:ot4">106.86879834213255</span></td><td class="xzv" nowrap="nowrap">14</td></tr><tr _afrrk="4" class="xzy"><td class="xzv" nowrap="nowrap"><span id="t1:4:ot1">26</span></td><td class="xzv" nowrap="nowrap">05</td><td class="xzv" nowrap="nowrap"><span id="t1:4:ot3">47.89841940184846</span></td><td class="xzv" nowrap="nowrap"><span id="t1:4:ot4">106.82674130477903</span></td><td class="xzv" nowrap="nowrap">13</td></tr><tr _afrrk="5" class="xzy"><td class="xzv" nowrap="nowrap"><span id="t1:5:ot1">26</span></td><td class="xzv" nowrap="nowrap">06</td><td class="xzv
.etc
Javascript: alert(document.getElementById("t1:121:ot3").innerHTML); this retrieve in value
But only 50 rows in this result. I have many rows. How I can get all??? -
How to use Table valued MSSQL function in OBIEE
Hi all,
Can some one help me to understand how to use table valued function in OBIEE? I want to use a table valued function (MSSQL function, with some input parameter), in the physical layer to pull the data?
I know for MSSQL Stored Procedure we can write as
EXEC SP_NAME @Parameter = 'VLUEOF(NQ_SESSION.Variablename)'
but now I have a table valued function in the query window I can get the data as
select * from myfunction(parametervalue)
In physical layer of OBIEE I have tried as
select * from myfunction('VLUEOF(NQ_SESSION.Variablename)'), but I'm getting error as the NQ_SESSION variable doesn't have a value , but actually I have initialized the variable but still Im getting error.
Can some one help me to solve this.
Thanks,
MithunFollow this link and try yourself. let me know for issues
Substring instr issue in obiee
Appreciate if you mark
Edited by: Srini VEERAVALLI on Feb 20, 2013 8:13 AM -
How to insert a text edit UI element in a table
hi all,
I want a text edit UI element in a table .I do not want input field because text entered can be very long and whole text cant be seen then.Is there any way to increase the width of input field if i insert an input field ? or what can be other solution for this?Hi Govind,
You can't insert Text Edit as a cell variant in table. But you can increase the 'Width' property of Input Field, say to 500px or as per your requirement, so that you can display the full text at one go. Or you can bind the 'Width' property to a context and set the width at run time as per the text length.
Thanks,
Sumit
Maybe you are looking for
-
SCCM 2012 QUERY THAT SHOWS SOFTWARE INSTALLED AND LAST TIME IT WAS USED OR OPENED
Hello I am in need of an SCCM 2012 query that shows PCs that have Visio , Adobe Professional and Visual Studio and the last time each was used or opened. I have the query below which give me the PC name and the product. Any assistance will be very he
-
Table control with wizard in module pool
Hi Gurus!! First I have an ztable for header and ztable for item of the purchase order. We have the requirement of first uploading the data into ztable and then perform bapi or bdc on it. So, before the data goes into the ztable we have to create scr
-
Can i print a string on a panel object?
I have been trying to find a way to print a sring on a panel object but i couldnt manage it. Can this be done? If it can be, how can i do it?
-
Material price based on FIFO basis
Hi SAPERS, In sap material can be valuated by using moving average of Standard price. But my client requires at the time of GI the material cost should be charged on basis of FIFO invoice/ cost. In material master accounting view one FIFO check box i
-
My new iMac cannot detect my canon scanner
I just got a new iMac with the latest Mountain Lion update however, when I tried to install my CanoScan 8800f it cannot be dected in the USB. But when I tried to connect it to my old computer and used scanner sharing, it works well. I tried isolating