Value Help in WD Table
Hi to all!
I have a problem with value help in a Web dynpro Table.
In my WD I have a Table with a field that had a free Value help, if I press F4 the Value help is opening
If I select an item the value of the Help, the popup is closing but the selected value is not in the table cell.
Have someone an idea, how I can solve this problem?
Thanks for the answers
greetings
Hermann
Hi Herrmann,
for free value help you have to implement the data setting by your own.
Though the following thread covers ALV, Regina's answers will cover you request, I guess:
Value Help for ALV
Cheers,
Sascha
Similar Messages
-
Dynamic value help for a table field to fill two fields, how to?
Hi all gurus,
In SRM 7 I defined a dynamic value help for a single field (ZZ_PROLE_R3) of my header custom table.
That's the code from WDDOMODIFYVIEW in the webdynpro /SAPSRM/WDC_DODC_CT, view V_DODC_CT:
DATA: lo_tabnode TYPE REF TO IF_WD_CONTEXT_NODE.
DATA: lo_tabnode_info TYPE REF TO IF_WD_CONTEXT_NODE_INFO.
DATA: tab_value TYPE WDR_CONTEXT_ATTR_VALUE_LIST,
wa_value TYPE WDR_CONTEXT_ATTR_VALUE.
lo_tabnode = wd_context->GET_CHILD_NODE( name = 'THCUS' ). "the custom table node
lo_tabnode_info = lo_tabnode->get_node_info( ).
wd_this->GET_VALHELP_ZZ_PROLE_R3( EXPORTING iv_guid = lv_guid
IMPORTING ZZ_PROLE_R3_VALHELP = tab_value ). "this method returns the dyn value table
lo_tabnode_info->set_attribute_value_set( name = 'ZZ_PROLE_R3'
value_set = tab_value ).
The method GET_VALHELP_ZZ_PROLE_R3 dynamically builds the value help table tab_value; such table is made up by two fields:
value : contains the value of the field
text : contains a description of the value
The above solution works; now I'd like to enhance it. The custom table THCUS contains also a field called ZZ_PROLE_R3_DESC, which represents the description of ZZ_PROLE_R3. It is, exactly, the TEXT field in tab_value.
So I'd like to do as follows:
- the user clicks on the search help for ZZ_PROLE_R3 field of the table;
- the above described value help appears;
- after the selection, both ZZ_PROLE_R3 and ZZ_PROLE_R3_DESC are filled with the selected couple value - text chosen from the value help.
Could anyone help me achieving such a behaviour?
Again, a little request... when I open the above value help dialog box, the window itself has a label "Floorplan Manager application for OIF.." that obviously I'd like to redefine (e.g. "Role selection value help"). Is there any way to do that?
Thanks in advanceChris Paine wrote:
It seems to me - given that your code is in wddomodifyview that you are trying to have different dropdowns per row
- I'm not sure where you are populating lv_guid - but I'd guess it is an attribute of the row selected? If it isn't then I can't see any reason that you would do this code in wddomodifyview and not wddoinit.
Hi Chris and thanks for your help,
lv_guid is the GUID of the document's header; I need to pass it to the method that populates my value help table because the values in it are derived from some fields on the document. (the situation actually is more complex; there's an RFC call on the backend for which the document is intended for to retrieve the data that populate the value help...).
I'm quite unexperienced on webdynpro and terminology; if dropdown menus are fixed selection option that appears on a field, I guess this is not my case. I did a pair of screenshot to provide an idea of what the solution by now is, and what "I would like to have":
[Pre-selection (F4 icon on the field in table)|http://imagebin.ca/view/npIsaqF.html]
[Value Help popup for the field ZZ_PROLE_R3|http://imagebin.ca/view/8fZUh3T.html]
[Result by now |http://imagebin.ca/view/3PaqdvE.html]
[Result I'd like to have.|http://imagebin.ca/view/dExR0J.html]
Chris Paine wrote:
However - by your comment on the "value help dialog box" I am guessing you are using an input field? If this is the case then I would strongly suggest that you change/enhance the structure of the context node THCUS (btw, better coding practise to refer to it as wd_this->wdctx_thcus when using the get child node construct) so that you refer to an actual SAP ddic search help, if you then associate in the structure the value and text fields then populating the text field should happen automatically. Also you'd have the nice side effect that your value help dialog would be named after the associated ddic search help.
Thanks for the code suggestion, I'll apply that. For what concerns the context node THCUS... It is, by standard, a node which I can't explictly find in the context for the view V_DODC_CT. The problem is that ZZ_PROLE_R3 and the corresponding description field ZZ_PROLE_R3_DESC of the table must be filled with data retrieved dynamically @ runtime from the backend. So I guess I can't populate a val help referring to a dictionary table/field; I'd rather do as follows:
- retrieve what's the target backend for the document (to do so, I have to process the document .. that's why the header guid passed to my method);
- RFC call to a custom method that extracts possible values for the specific backend;
- bind the ammissible values to the value help.
Chris Paine wrote:
I realise that this is rather a lot - so if you have any specific question please do respond - hopefully I or someone else will be able to clarify.
Thanks again for your help; additional info as well as code examples would be highly appreciated -
Action for click in table like in value help design since SP11
Hi everybody,
since SP11 with the new value helps (F4) design, you can click everywhere in the table of the search result table, to select and use one hit.
Now I want to create a table with this behaviour and layout, too.
Is it possible in a table, normal table or with a ALV, to set an action for a event "clicking in the table"?
I know Is it possible in use of celleditors like button or link. But than you see the link or a button I dont want to have.
So maybe someone know how it could be realized.
Many thanks and
best regards
ChristianHi Neha,
thanks for your answer. With setting the type, die text is underlined when the mouse is over the text.
But in the value helps, the whole cell is activ to click in. So you don't have to click on the text, a click in the cell is enough.
So the question is, if this functionality only programmed only for the DDIC value helps or can I set a table to this "layout".
Best regards
Christian -
Please help - Joining three tables and get row values into Column. Please help!
Hi,
There is a SourceTable1 (Employee) with Columns like EmployeeID,Name,DOB.
There is a sourcetable2 (EmployeeCode) with columns like EmployeeID,Code,Order.
There is a source table 3 #EmployeeRegioncode and its columns are (EmployeeID , RegionCode , [Order]
The target table 'EmployeeDetails' has the following details. EmployeeID,Name,DOB,Code1,Code2,Code3,Code4,regioncode1
regioncode2 ,regioncode3 ,regioncode4
The requirement is , the value of the target table columns the Code1,code2,code3 ,code4,code5 values should
be column 'Code' from Sourcetable2 where its 'Order' column is accordingly. ie) Code1 value should be the 'Code' value where [Order] column =1, and Code2 value should be the 'Code' value where [Order] =2, and so on.
Same is the case for Source table 3- 'Region code' column also for the columns regioncode1
regioncode2 ,regioncode3 ,regioncode4
Here is the DDL and Sample date for your ref.
IF OBJECT_ID('TEMPDB..#Employee') IS NOT NULL DROP TABLE #Employee;
IF OBJECT_ID('TEMPDB..#EmployeeCode') IS NOT NULL DROP TABLE #EmployeeCode;
IF OBJECT_ID('TEMPDB..#EmployeeDetails') IS NOT NULL DROP TABLE #EmployeeDetails;
---Source1
CREATE table #Employee
(EmployeeID int, Empname varchar(20), DOB date )
insert into #Employee VALUES (1000,'Sachin','1975-12-12')
insert into #Employee VALUES (1001,'Sara','1996-12-10')
insert into #Employee VALUES (1002,'Arjun','2000-12-12')
---Source2
CREATE table #EmployeeCode
(EmployeeID int, Code varchar(10), [Order] int)
insert into #EmployeeCode VALUES (1000,'AA',1)
insert into #EmployeeCode VALUES (1000,'BB',2)
insert into #EmployeeCode VALUES (1000,'CC',3)
insert into #EmployeeCode VALUES (1001,'AAA',1)
insert into #EmployeeCode VALUES (1001,'BBB',2)
insert into #EmployeeCode VALUES (1001,'CCC',3)
insert into #EmployeeCode VALUES (1001,'DDD',4)
insert into #EmployeeCode VALUES (1002,'AAAA',1)
insert into #EmployeeCode VALUES (1002,'BBBB',2)
insert into #EmployeeCode VALUES (1002,'CCCC',3)
insert into #EmployeeCode VALUES (1002,'DDDD',4)
insert into #EmployeeCode VALUES (1002,'EEEE',5)
---Source tbl 3
CREATE table #EmployeeRegioncode
(EmployeeID int, RegionCode varchar(10), [Order] int)
insert into #EmployeeRegioncode VALUES (1000,'xx',1)
insert into #EmployeeRegioncode VALUES (1000,'yy',2)
insert into #EmployeeRegioncode VALUES (1000,'zz',3)
insert into #EmployeeRegioncode VALUES (1001,'xx',1)
insert into #EmployeeRegioncode VALUES (1001,'yy',2)
insert into #EmployeeRegioncode VALUES (1001,'zz',3)
insert into #EmployeeRegioncode VALUES (1001,'xy',4)
insert into #EmployeeRegioncode VALUES (1002,'qq',1)
insert into #EmployeeRegioncode VALUES (1002,'rr',2)
insert into #EmployeeRegioncode VALUES (1002,'ss',3)
---Target
Create table #EmployeeDetails
(EmployeeID int, Code1 varchar(10), Code2 varchar(10),Code3 varchar(10),Code4 varchar(10),Code5 varchar(10) , regioncode1 varchar(10),
regioncode2 varchar(10),regioncode3 varchar(10),regioncode4 varchar(10))
insert into #EmployeeDetails VALUES (1000,'AA','BB','CC','','','xx','yy','zz','')
insert into #EmployeeDetails VALUES (1001,'AAA','BBB','CCC','DDD','','xx','yy','zz','xy')
insert into #EmployeeDetails VALUES (1002,'AAAA','BBBB','CCCC','DDDD','EEEE','qq','rr','ss','')
SELECT * FROM #Employee
SELECT * FROM #EmployeeCode
SELECT * FROM #EmployeeRegioncode
SELECT * FROM #EmployeeDetails
Can you please help me to get the desired /targetoutput? I have sql server 2008.
Your help is greatly appreciated.select a.EmployeeID,b.code1,b.code2,b.code3,b.code4,b.code5,c.Reg1,c.Reg2,c.Reg3,c.Reg4 from
#Employee a
left outer join
(select EmployeeID,max(case when [Order] =1 then Code else '' end) code1,
max(case when [Order] =2 then Code else '' end)code2,
max(case when [Order] =3 then Code else '' end)code3,
max(case when [Order] =4 then Code else '' end)code4,
max(case when [Order] =5 then Code else '' end)code5 from #EmployeeCode group by EmployeeID) b
on a.EmployeeID=b.EmployeeID
left outer join
(select EmployeeID,max(case when [Order] =1 then RegionCode else '' end) Reg1,
max(case when [Order] =2 then RegionCode else '' end)Reg2,
max(case when [Order] =3 then RegionCode else '' end)Reg3,
max(case when [Order] =4 then RegionCode else '' end)Reg4 from #EmployeeRegioncode group by EmployeeID) c
on a.EmployeeID=c.EmployeeID
Thanks
Saravana Kumar C -
Value Help for a field from custom table in BSP
Please let me know, the procedure to create value help for a field from a custom table in BSP using HTMLB.
Thankshi prodigy,
check this code using drop down list.
<b>layout for first page</b>
<htmlb:dropdownListBox id = "ddlist"
table = "<%=t_mara%>"
nameOfKeyColumn = "matnr"
nameOfValueColumn = "matnr"></htmlb:dropdownListBox>
<b>event Oninitialization event of first page</b>
SELECT MATNR UP TO 10 ROWS
INTO TABLE T_MARA
FROM MARA.
<b> event Oninputprocessing event</b>
**Load the manager class
CLASS CL_HTMLB_MANAGER DEFINITION LOAD.
DATA: V_EVENT TYPE REF TO CL_HTMLB_EVENT.
DATA: DATA TYPE REF TO OBJECT.
DATA: V_DATA TYPE REF TO CL_HTMLB_DROPDOWNLISTBOX.
CALL METHOD CL_HTMLB_MANAGER=>GET_EVENT
EXPORTING
REQUEST = RUNTIME->SERVER->REQUEST
RECEIVING
EVENT = V_EVENT
IF V_EVENT->NAME = 'button' AND
V_EVENT->EVENT_TYPE = 'click'.
DATA ?= CL_HTMLB_MANAGER=>GET_DATA( REQUEST =
RUNTIME->SERVER->REQUEST
NAME = 'inputField'
ID = 'matnr'
V_DATA ?= DATA.
IF V_DATA IS NOT INITIAL.
V_MATNR = V_DATA->SELECTION.
ENDIF.
NAVIGATION->SET_PARAMETER( NAME = 'v_matnr' VALUE = V_MATNR ).
NAVIGATION->GOTO_PAGE( 'detail.htm' ).
ENDIF.
<b>in the onInitialization event for detail page</b>SELECT MATNR
ERSDA
ERNAM
LAEDA
AENAM
VPSTA
PSTAT
LVORM
MTART
FROM MARA
INTO TABLE T_MARA
WHERE MATNR = V_MATNR. -
Extended Value Help Selector (EVS): Manually open Value-table
Hello,
i have implemented the Extended Value Help Selector as shown in the tutorial.
Possible values are for example: Lufthansa, AmericanAirlines, Italia, and so on.
Now if somebody manually (without using the help selector) enters "luf" and hits enter, an error message comes up with the text key not found in list.
Now i want to modify the Value Help selector: If the user enters a text in the textfield which does not exist in the list of allowed values, the value help selector-table should come up automatically with the entered value as search / filter criteria.
Is this possible?
Kind Regards,
ThomasHi Thomas,
Sorry to say but its not possible with EVS. I think for ur requirement ,OVS is better option.
regards
Sumit -
Retrieve values from a HTML table !!!
Hi.
How can i retrieve values from a HTML table using javascript ?
I´m trying to use the command "document.getElementsByTagName" without success.
Thanks in advance.
EduardoHi, Deepu.
I´m still with trouble in retrieving the value in HTML.
In debug the C_CELL_ID seems to be correctly updated but
when using the command "document.getElementById" the value is always "null".
I implemented in the method DATA_CELL the code :
if i_x = 3 and i_y = 2.
C_CELL_ID = 'zs'.
C_CELL_CONTENT = 10.
endif.
And in HTML :
var ztest = document.getElementById('zs');
alert(ztest);
Could you help me please.
Many regards
Eduardo S.
Message was edited by: Eduardo Silberberg -
Distinct values from dynamic internal tabls
Hi All,
I have a dynamic internal tables like <dy_table> , i want to get distinct values from this internal tables,
how to do that, structure of dynamic internal tables is dynamic acc. to user conditions.
regards,
AnujHi Anuj
Just try this,
CALL METHOD cl_alv_table_create=>create_dynamic_table
EXPORTING
it_fieldcatalog = tb_fields_for_it
IMPORTING
ep_table = gp_dyn_table.
ASSIGN gp_dyn_table->* TO <gt_table>.
ASSIGN LOCAL COPY OF INITIAL LINE OF <gt_table> TO <fs_table>.
LOOP AT tb_output.
*To assign value for serial number.
ASSIGN COMPONENT 1 OF STRUCTURE <fs_table> TO <ls_field>.
<ls_field> = tb_output-sno.
UNASSIGN <ls_field>.
*To assign value for Sales Organization.
ASSIGN COMPONENT 2 OF STRUCTURE <fs_table> TO <ls_field>.
<ls_field> = tb_output-vkorg.
UNASSIGN <ls_field>.
*To assign Rate for its respective Condition type.
LOOP AT tb_konp WHERE knumh = tb_output-knumh.
READ TABLE tb_fieldcat1 WITH KEY fieldname = tb_output-kschl.
IF sy-subrc EQ 0.
lv_count = tb_fieldcat1-col_pos.
ASSIGN COMPONENT lv_count OF STRUCTURE <fs_table> TO <ls_field>.
IF tb_konp-konwa EQ '%'.
tb_konp-kbetr = tb_konp-kbetr / co_10.
<ls_field> = tb_konp-kbetr.
ELSE.
<ls_field> = tb_konp-kbetr.
ENDIF.
ENDIF.
ENDLOOP.
lv_count = lv_count + 1.
APPEND <fs_table> TO <gt_table>.
CLEAR <fs_table>.
ENDLOOP.
Hope this proves helpful to you. -
How to retrieve the values from PL/SQL table types.
Hi Every one,
I have the following procedure:
DECLARE
TYPE t1 IS TABLE OF emp%ROWTYPE
INDEX BY BINARY_INTEGER;
t t1;
BEGIN
SELECT *
BULK COLLECT INTO t
FROM emp;
END;
This procedure works perfectly fine to store the rows of employee in a table type. I am not able to retrieve the values from Pl/SQL table and display it using dbms_output.put_line command.
Can anybody help me please!!!!!
Thanks
Ahmed.You mean, you can't add this
for i in t.first..t.last loop
dbms_output.put_line(t(i).empno||' '||t(i).ename||' '||t(i).job);
end loop;or you can't add this
set serveroutput onor maybe, you are working in third party application where dbms_output is not applicable at all?
You see, not able like very similar it is not working - both are too vague...
Best regards
Maxim -
Some fields from R/3 have automatic value help for input field on WD
Hello,
we have imported a Model from RFC/JCo (ABAP) with several fields. One of them is "IWAER" of SimpleType Iwaer and "Built-In-Type" string in J2EE. Though the enumeration of this type is empty, WebDynpro mystically generates a value help if the type is assignet to an ImputField. On the ABAP-side component type is IWAER with data type CUKY and in domain WAERS which has a value table TCURC (instead of fixed values in a value range).
Where/why does WD find out that this is a currency-field and where do the values in the value selector come from?
Best regards,
ManuelHi,
at least for the ModelData-Connection (BAPI-Call) there is no data being transferred besides one value for each field.
I don't know if the MetaData-Connection of JCo is able to get more information (e.g. key-value-pairs for the domain or type the field belongs to,..) than just the structure of the interface.
-> Where and how do these EVS-values come from without doing something?
Best regards,
Manuel -
Insert an HTML Table tag as a value in a Tree Table
Hi helper,
Can I insert an HTML Table tag inside a TreeTable (Hierarchical data) using AdvancedDataGrid as a value?
I need to create a Tree table in flex and I have beside normal int values some cells that need to show a certain images in an HTML Table I will create.
Is it possible?
Please advice
Thanks
Jo<div class=Section1><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'>It depends on where you get the list of images<o:p></o:p></span></p><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'><o:p> </o:p></span></p><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'>Alex Harui<o:p></o:p></span></p><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'>Flex SDK Developer<o:p></o:p></span></p><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'><a href="http://www.adobe.com/"><span style='color:blue'>Adobe<br />Systems Inc.</span></a><o:p></o:p></span></p><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'>Blog: <a href="http://blogs.adobe.com/aharui"><span<br />style='color:blue'>http://blogs.adobe.com/aharui</span></a><o:p></o:p></span></p><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'><o:p> </o:p></span></p><br /><br /><div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in'><br /><br /><p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span<br />style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> Yossi Bar<br />[mailto:[email protected]] <br><br /><b>Sent:</b> Monday, February 09, 2009 1:14 AM<br><br /><b>To:</b> [email protected]<br><br /><b>Subject:</b> Re: Insert an HTML Table tag as a value in a Tree Table<o:p></o:p></span></p><br /><br /></div><br /><br /><p class=MsoNormal><o:p> </o:p></p><br /><br /><p class=MsoNormal style='margin-bottom:12.0pt'>A new message was posted by<br />Yossi Bar in <br><br /><br><br /><b>Developers</b> --<br><br /> Insert an HTML Table tag as a value in a Tree Table<br><br /><br><br />Thanks Alex, <br><br />What is the way to implement HorizontalLIst of images for<br />AdvancedDataGridColumn? <br><br /><br><br />In the code here I create a tree table and in Actual column I show an image: <br><br /><br><br /><mx:AdvancedDataGrid width="100%" height="100%"<br />folderClosedIcon="{null}" folderOpenIcon="{null}"<br />defaultLeafIcon="{null}"> <br><br /><br><br /><mx:dataProvider> <br><br /> <mx:HierarchicalData<br />source="{dpHierarchy}"/> <br><br /> </mx:dataProvider> <br><br /> <mx:groupedColumns> <br><br /> <mx:AdvancedDataGridColumn<br />headerText="" width="50"/> <br><br /> <mx:AdvancedDataGridColumn<br />dataField="Region" backgroundColor="haloSilver"<br />headerText="Region title"<br />headerRenderer="mx.controls.Label"/> <br><br /> <mx:AdvancedDataGridColumnGroup<br />headerText="Group Header"<br />headerRenderer="mx.controls.Label"> <br><br /><mx:AdvancedDataGridColumn dataField="Territory_Rep"<br />headerText="Territory Rep"<br />headerRenderer="mx.controls.Label"/> <br><br /><mx:AdvancedDataGridColumn dataField="Actual"<br />headerText="Actual title"<br />headerRenderer="mx.controls.Label"> <br><br /><mx:itemRenderer> <br><br /><mx:Component> <br><br /><mx:VBox horizontalAlign="center"> <br><br /><mx:Image width="50" source="{data.Actual}"/> <br><br /></mx:VBox> <br><br /></mx:Component> <br><br /></mx:itemRenderer> <br><br /></mx:AdvancedDataGridColumn> <br><br /><br><br /><mx:AdvancedDataGridColumn dataField="Estimate"<br />headerText="Estimate title" headerRenderer="mx.controls.Label"/><br /><br><br /> </mx:AdvancedDataGridColumnGroup><br /><br><br /> </mx:groupedColumns> <br><br /> </mx:AdvancedDataGrid> <br><br /><br><br />Please advise, <br><br /><br><br />Thanks <br><br /><br><br />Jo <o:p></o:p></p><br /><br /><div class=MsoNormal><br /><br /><hr size=2 width=200 style='width:150.0pt' align=left><br /><br /></div><br /><br /><p class=MsoNormal style='margin-bottom:12.0pt'>View/reply at <a<br />href="http://www.adobeforums.com/webx?13@@.59b7d1ae/2">Insert an HTML Table tag<br />as a value in a Tree Table</a><br><br />Replies by email are OK.<br><br />Use the <a<br />href="http://www.adobeforums.com/webx?280@@.59b7d1ae!folder=.3c060fa3">unsubscribe</a>< br />form to cancel your email subscription.<o:p></o:p></p><br /><br /></div>
-
Using two cursors, one for updating salary values in the emp table
Using COPIES of the employee and department tables provided by Oracle or using similar taples that provide employee, salary, job and dept in one table and dept number and department name in another table, write the following program. Use the dept table to step through sequentially and bring up the records with the same department from the employee table. Using an IF statement calcuate a new salary based on the job (you decide on the criteria). Update each record on the employee file (this is why you should use copies) with the new salary. In addition, calculate the total salary for each department and create a new table with the department number, the department name and the salary.
I'm able to update the salary values, but I'm not sure how to insert those updated values into an empty table the way this problem is asking me to.
Here's my script so far: any help would be greatly appreciated: )
declare
v_deptno emp.deptno%type;
v_job emp.job%type;
v_sal emp.sal%type;
v_dname dept.dname%type;
v_deptsal totalsal.deptsal%type;
cursor salup_c is
select job,sal
from emp,dept
where emp.deptno = dept.deptno
for update of sal;
cursor totdeptsal_c is
select dname,sal
from emp,dept
where emp.deptno = dept.deptno;
Begin
open salup_c;
loop
fetch salup_c into v_job,v_sal;
exit when salup_c%notfound;
if v_job = 'CLERK' then
v_sal := v_sal + 10;
else
if v_job = 'ANALYST' then
v_sal := v_sal + 20;
else
if v_job = 'MANAGER' then
v_sal := v_sal + 30;
else
if v_job = 'PRESIDENT' then
v_sal := v_sal + 40;
else v_sal := v_sal + 50;
end if;
end if;
end if;
end if;
update emp
set sal = v_sal
where current of salup_c;
open totdeptsal_c;
v_deptsal := 0;
loop
fetch totdeptsal_c into v_dname, v_deptsal;
exit when totdeptsal_c%notfound;
v_deptsal := v_deptsal + v_sal;
insert into totalsal
values(v_deptno,v_dname,v_deptsal);
end loop;
close totdeptsal_c;
end loop;
close salup_c;
end;
/The script is actually inserting some values into the new table but look at what I'm getting
Here it is: i only want the dept number ,the dept name, and total salary for each department.
SQL> @ sndprob;
PL/SQL procedure successfully completed.
SQL> select * from totalsal;
DEPTNO DNAME DEPTSAL
RESEARCH 1620
SALES 2410
SALES 2060
RESEARCH 3785
SALES 2060
SALES 3660
ACCOUNTING 3260
RESEARCH 3810
ACCOUNTING 5810
SALES 2310
RESEARCH 1910
DEPTNO DNAME DEPTSAL
SALES 1760
RESEARCH 3810
ACCOUNTING 2110
RESEARCH 2460
SALES 3300
SALES 2900
RESEARCH 4625
SALES 2900
SALES 4500
ACCOUNTING 4100
RESEARCH 4650
DEPTNO DNAME DEPTSAL
ACCOUNTING 6650
SALES 3150
RESEARCH 2750
SALES 2600
RESEARCH 4650
ACCOUNTING 2950
RESEARCH 2110
SALES 2950
SALES 2600
RESEARCH 4275
SALES 2550
DEPTNO DNAME DEPTSAL
SALES 4150
ACCOUNTING 3750
RESEARCH 4300
ACCOUNTING 6300
SALES 2800
RESEARCH 2400
SALES 2250
RESEARCH 4300
ACCOUNTING 2600
RESEARCH 3815
SALES 4655
DEPTNO DNAME DEPTSAL
SALES 4305
RESEARCH 6010
SALES 4255
SALES 5855
ACCOUNTING 5455
RESEARCH 6005
ACCOUNTING 8005
SALES 4505
RESEARCH 4105
SALES 3955
RESEARCH 6005
DEPTNO DNAME DEPTSAL
ACCOUNTING 4305
RESEARCH 2110
SALES 2950
SALES 2600
RESEARCH 4305
SALES 2600
SALES 4150
ACCOUNTING 3750
RESEARCH 4300
ACCOUNTING 6300
SALES 2800
DEPTNO DNAME DEPTSAL
RESEARCH 2400
SALES 2250
RESEARCH 4300
ACCOUNTING 2600
RESEARCH 3690
SALES 4530
SALES 4180
RESEARCH 5885
SALES 4180
SALES 5760
ACCOUNTING 5330
DEPTNO DNAME DEPTSAL
RESEARCH 5880
ACCOUNTING 7880
SALES 4380
RESEARCH 3980
SALES 3830
RESEARCH 5880
ACCOUNTING 4180
RESEARCH 3290
SALES 4130
SALES 3780
RESEARCH 5485
DEPTNO DNAME DEPTSAL
SALES 3780
SALES 5360
ACCOUNTING 4960
RESEARCH 5480
ACCOUNTING 7480
SALES 3980
RESEARCH 3580
SALES 3430
RESEARCH 5480
ACCOUNTING 3780
RESEARCH 3830
DEPTNO DNAME DEPTSAL
SALES 4670
SALES 4320
RESEARCH 6025
SALES 4320
SALES 5900
ACCOUNTING 5500
RESEARCH 6040
ACCOUNTING 8020
SALES 4520
RESEARCH 4120
SALES 3970
DEPTNO DNAME DEPTSAL
RESEARCH 6020
ACCOUNTING 4320
RESEARCH 5850
SALES 6690
SALES 6340
RESEARCH 8045
SALES 6340
SALES 7920
ACCOUNTING 7520
RESEARCH 8060
ACCOUNTING 10080
DEPTNO DNAME DEPTSAL
SALES 6540
RESEARCH 6140
SALES 5990
RESEARCH 8040
ACCOUNTING 6340
RESEARCH 2360
SALES 3200
SALES 2850
RESEARCH 4555
SALES 2850
SALES 4430
DEPTNO DNAME DEPTSAL
ACCOUNTING 4030
RESEARCH 4570
ACCOUNTING 6590
SALES 3100
RESEARCH 2650
SALES 2500
RESEARCH 4550
ACCOUNTING 2850
RESEARCH 1920
SALES 2760
SALES 2410
DEPTNO DNAME DEPTSAL
RESEARCH 4115
SALES 2410
SALES 3990
ACCOUNTING 3590
RESEARCH 4130
ACCOUNTING 6150
SALES 2660
RESEARCH 2220
SALES 2060
RESEARCH 4110
ACCOUNTING 2410
DEPTNO DNAME DEPTSAL
RESEARCH 1770
SALES 2610
SALES 2260
RESEARCH 3965
SALES 2260
SALES 3840
ACCOUNTING 3440
RESEARCH 3980
ACCOUNTING 6000
SALES 2510
RESEARCH 2070
DEPTNO DNAME DEPTSAL
SALES 1920
RESEARCH 3960
ACCOUNTING 2260
RESEARCH 3830
SALES 4670
SALES 4320
RESEARCH 6025
SALES 4320
SALES 5900
ACCOUNTING 5500
RESEARCH 6040
DEPTNO DNAME DEPTSAL
ACCOUNTING 8060
SALES 4570
RESEARCH 4130
SALES 3980
RESEARCH 6040
ACCOUNTING 4320
RESEARCH 2120
SALES 2960
SALES 2610
RESEARCH 4315
SALES 2610
DEPTNO DNAME DEPTSAL
SALES 4190
ACCOUNTING 3790
RESEARCH 4330
ACCOUNTING 6350
SALES 2860
RESEARCH 2420
SALES 2270
RESEARCH 4330
ACCOUNTING 2620
196 rows selected. -
How to change the Destination URI value of a item table at run time
I'd like to change the Destination URI of item of a table region when a column X of my view is not NULL. Where should I set the new Destination URI value for the item table region for specific row? Is in the RowImpl for the view object or in the Controler of the page?
I'd really appreciate any suggestion.
Thanks in advance.Hi,
Thanks for the help, but I still dont know where I should to use setAttributeValue(DESTINATION_ATTR,OADataBoundValueViewObject());
All examples that I saw till now here, suggestes to change something in the page in Controller but based on something entered in the page. In my case is IN to OUT, I will render some item table with a specific value parameter based what is in the database. Being more specific, I have a html table and one column Col1 has a value and it will have a DESTINATION URL if another column Col2 is Null. I believe I would have to check somewhere if the Col2 is null or not and change the DESTINATION URL property.
Thanks again.. -
Value help dropdown list not showing up other values
Dear all,
I'm new to Adobe and Java WD. I managed to go through all the tutorials and developed a WDJ and embedded an interactive form in the view. I also used an RFC Model to pull some values from n R/3 table and populate in a context node element.
These values are appearing perfectly fine in the WDJ if I'm using a table or a drop down list index field.
But in the Adobe form, when i bind this context node to a WebDynpro native Value help drop down list box, only the first value of the table appears. On clicking on it, nothing happens. I'm not sure what is the problem.
Can anyone please help me in this? Should i write some code to bring the other values too? (the tutorial doesn't say this!)
If so, then please give some sample java codings and step by step process for populating the field values with the table values.
My node structure is like below
Context
Ysam_Get_Values_Input(Node-RFC)
Output (Node-RFC O/P)
Values(Node-table from the RFC)
Slno (attribute that has the values to be populated with)
Any help is greatly appreciated.
Thanks,
SamHi Raja,
In the view:
<htmlb:gridLayoutCell id = "AddedProfileNameIF"
columnIndex = "2"
rowIndex = "2"
horizontalAlignment = "LEFT"
verticalAlignment = "MIDDLE" >
<htmlb:dropdownListBox id = "added_profile1"
helpValues = "//model/ust10st.profn"
/>
</htmlb:gridLayoutCell>
In the Model:
method MODEL_INIT .
select profn from ust10s into table UST10ss.
read table UST10ss index 1 into UST10st.
endmethod.
In controller:
METHOD do_init .
m_model ?= create_model( model_id = 'm'
class_name = 'zcl_model_zsox1' ).
m_model->model_init( ).
ENDMETHOD. -
Want to read Field value set by Value help
Hello,
I have BSP View which is using Value help extensions for one of the input. The search help is based on the Elementary Search Help which is further based on Z-Table. In my BSP view [IE] I am able to popup the Search help and able to select the Value from list of choice. The selected value gets reflected in the Input field of browser. The problem is I am not able to capture the selected value in Event handler. I need to capture this value and get the related data in other input fields [which are display only]. How to do this?
I even tried getting the value in the Javascript, but unable to assign the Javascript variable to my BSP View attribute or Controller attribute.
Thanks in advance.>Do I have to trap it in DO_HANDLE_Event by doing Get_Form_Fields??
If you are using MVC and data binding you don't have to do anything. The field values will be brought in automatically for you.
However in any MVC application, the highest level controller should always contain a small block of code in the redefinition of the DO_REQUEST method. It is:
if input is available, dispatch this input to subcomponent.
* this call is only necessary for toplevel controllers.
* ( if this is not a toplevel controller or no input is present,
* this call returns without any action)
dispatch_input( ).
* if any of the controllers has requested a navigation,
* do not try to display, but leave current processing
IF is_navigation_requested( ) IS NOT INITIAL.
RETURN.
ENDIF.
This code is critical for properly dispatching events through the controllers. It is also the code that triggers the MVC runtime to restore input values into the model.
Also to eliminate the possibility with a problem in the implementation of the value help, why don't you temporarily switch out this element with just a plain htmlb:inputField. This way you test to make sure that data binding works correctly with the standard field.
Maybe you are looking for
-
We have deployed printers from the Print Manager MMC to our computers. However, two new Windows 8.1 computers don't get the printers. GPResult shows the policy has not applied after many logins. Is there some change for printers under 8.1? Jim Hay
-
Can't open EPS from PhotoShop CS4 in PS CS6 (or much of anything else)
I have some EPS files that I just can't open - I'm trying to get the creator to send them in another format but they're not responding to any of my emails so I need to try and get the data out of them. The start of the header looks like so: %!PS-Ad
-
Detailed Documentation on APIs in Oracle HRMS
Hi, I'm interfacing data into Oracle HRMS. Once the data from the flat files is put into the Intermedeate tables, the API and Data pump need to be run. Could anybody tell me where I could find detailed documentation about 1)the HRMS API's, 2)the Data
-
SAP B1 System Evaluation Tools
Dear. Does anyone by any chance know where to get SAP B1 System Evaluation Tools. We would like to use these to check the functionality of the system we just implemented. I believe in SAP My Business Suite and SAP All-in-one they are there. May you p
-
WebDynpro - How to pass a single field value to BAPI table?
Hello, I have just come from WebDynpro ABAP training and being a novice hit my first issue right away. I need to use BAPI - BAPI_CONTRACT_CREATEFROMDATA to create SD contract (I have used this BAPI to create a service call inside Webdynpro). I have t