Help for trigger
i have two tables asset and feature.whenever i insert data into feature the trigger should automatically retrieve the asset_id from asset table and insert it.
these are the tables.
SQL> desc feature;
Name Null? Type
ASSET_ID NOT NULL NUMBER(11)
SITE_SECTION NOT NULL VARCHAR2(50)
HED NOT NULL VARCHAR2(256)
CONTENT_FORMAT NOT NULL VARCHAR2(256)
DEK VARCHAR2(256)
TOUT NOT NULL VARCHAR2(1024)
PUBLISH_DATE NOT NULL DATE
IMAGE_URL VARCHAR2(512)
FRAGMENT_PATH NOT NULL VARCHAR2(1024)
VPATH VARCHAR2(1024)
SQL> desc asset;
Name Null? Type
ASSET_ID NOT NULL NUMBER(11)
ASSET_TYPE_ID NOT NULL NUMBER(11)
CREATE_DT NOT NULL DATE
UPDATE_DT DATE
EXPR_DT DATE
TITLE VARCHAR2(256)
SR_SUMMARY VARCHAR2(1024)
CODEWORD VARCHAR2(1024)
VPATH NOT NULL VARCHAR2(1024)
AUTHOR VARCHAR2(100)
this is the trigger i have written
CREATE OR REPLACE TRIGGER INSERTFEATURE_ASSETID BEFORE INSERT ON
FEATURE FOR EACH ROW
BEGIN
SELECT ASSET_ID into :NEW.ASSET_ID FROM ASSET WHERE ASSET_TYPE_ID = 15 AND VPATH
= :NEW.VPATH;
insert into feature(asset_id) values(:new.asset_id);
END;
when i am inserting data into feature with
insert into feature(site_section,hed,content_format,tout,publish_date,fragment_path,vpath)
values('asdf','acv','aaaa','aaaa',TO_DATE('06/06/1985','MM/DD/YYYY'),'qqqq','/even/more/paths');
it is saying no data found and error at the trigger in line 4;
where there is appropriate data in the asset table
SQL> select asset_id from asset where vpath='/some/other/path' and asset_type_id=15;
4
please help me.
thank you,
but if i have the trigger like this
CREATE OR REPLACE TRIGGER INSERTFEATURE_ASSETID BEFORE INSERT ON
FEATURE FOR EACH ROW
BEGIN
SELECT ASSET_ID into :NEW.ASSET_ID FROM ASSET WHERE ASSET_TYPE_ID = 15 AND VPATH
= :NEW.VPATH;
END;
and
SQL> insert into feature(site_section,hed,content_format,tout,publish_date,fragment_path,vpath)
2 values('asdf','acv','aaaa','aaaa',TO_DATE('06/06/1985','MM/DD/YYYY'),'qqqq','/even/more/paths')
insert into feature(site_section,hed,content_format,tout,publish_date,fragment_path,vpath)
ERROR at line 1:
ORA-00001: unique constraint (BEDEV.PK_FEATURE_ASSET_ID) violated
this is the problem i am getting
Similar Messages
-
F4 help for a dropdown field in ALV
I am trying to enable F4 help for a field in ALV (OO style) that also has a dropdown assigned to it.
If I enable the dropdown in the field catalog, the field does not respond to F4 event at all.
When I remove the dropdown attribute from the field catalog, the F4 help works, but obviously now there is no dropdown.
The reason I am trying to implement it this way is that my dropdown list (which is the same for all rows) is quite large while F4 help depends on the current line in the ALV (so the available values are limited).
I would like to try to avoid creating a dropdown handle for every row in ALV.
Does anybody know if it's even possible to have a dropdown and F4 help at the same time in ALV?Hi
Linking F4 Help to Fields
For the last section, we will deal with linking F4 help to fields. It is easy. As usual, define, implement and register the event onf4 at proper places in your code. For F4 help, you must register the fields whose F4 request will trigger the onf4 event. For this you must prepare a table of type LVC_T_F4 and register this table using the method register_f4_for_fields. While preparing table you must include a line for each field which will trigger F4 event. For each field in the structure;
1) Pass the fieldname to FIELDNAME
2)Set REGISTER to make the field registered,
3)Set GETBEFORE to provide field content transport before F4 in editable mode
4)Set CHNGEAFTER to make the data changed after F4 in editable mode.
Preparing table for the fields to be registered to trigger F4 event
DATA: lt_f4 TYPE lvc_t_f4 WITH HEADER LINE .
lt_f4-fieldname = 'PRICE'.
lt_f4-register = 'X' .
lt_f4-getbefore = 'X' .
APPEND lt_f4 .
CALL METHOD gr_alvgrid->register_f4_for_fields
EXPORTING
it_f4 = lt_f4[] .
A sample onf4 method implementation
METHOD handle_on_f1 .
PERFORM f4_help USING e_fieldname es_row_no .
er_event_data->m_event_handled = 'X' .
ENDMETHOD .
Again, we set the attribute er_event_data->m_event_handled to prevent further processing of standard F4 help.
Check this link
http://help.sap.com/saphelp_nw04/helpdata/en/ed/ec623c4f69b712e10000000a114084/content.htm
Check these standard programs
BCALV_GRID_F4_HELP_APPLICATION
BCALV_GRID_F4_HELPM01
BCALV_TEST_GRID_F4_HELP
Regards
Pavan -
Custom search help for a custom field in SRM 7
EDIT: I'm gonna clarify on this thread since my first post wasn't explicative enough... thanks for the patience
Hi all gurus,
the question is about a search help in SRM7 but since the task is about abap development, I guess this is the right section to ask for.
Shortly; every purchase doc in our SRM7 has a custom header table which contains data which are retrieved from the connected backends. In this custom table, the user has the opportunity to add manually a line, and for a specific input field in table, we have to define a search help which should retrieve the appropriate possible values w.r.t. the "target" backend for the document.
A bit of technical data: say the field is called ZZ_R3_ROLE; it's included in a custom structure ZR7_HEADER_CST_GEN which is itself an append for BBP_PDHCF.
I defined a Search Help for that field and the corresponding exit FM to manage our task.
Unfortunately, to retrieve the possible values for the specific backend I need some informations like:
- the backend on which the document will be distributed;
- the process type of the document.
This means that my search help should take into account additional informations that comes from the document I'm processing; I don't know what's the "clean" solution to do this.
I've seen on an old system (a SAP SRM 3.0) a workaround based on IMPORT/EXPORT ... TO MEMORY ID has been used. Actually, I'd like to find a more elegant solution, if any.
So... as you can see, I'm absolutely a newbie on the argument, but since I can trigger the search help only from a purchase document (PO, contract) process, I should need at least the GUID of the document to retrieve, for example, what's the target backend for that document in order to provide proper values.
Any hint/suggestion and in particular, a sketch of code as example is welcome.
Edited by: Matteo Montalto on Oct 22, 2010 3:01 PMHi,
into your modify view,
extract data you need in your search help in an itab (do it into a class do not perform select directly into modify view) and then bind it as value help to your WD element.
Regards,
Ivan -
How to create F4 help for a coloumn in CL_GUI_ALV_GRID?
Hi experts,
I have created alv grid on a container where i can enter data. But i need to create f4 help for a coloumn in the grid.Can you experts suggest some way to do it??
Thanks in advance
regards,
AshwinHi ,
Follow thios code.
Develop a method in your class as follows.
CLASS CL_PRICE_DATA DEFINITION.
PUBLIC SECTION.
ON_F4
FOR EVENT ONF4 OF CL_GUI_ALV_GRID
IMPORTING ES_ROW_NO E_FIELDNAME ER_EVENT_DATA.
CLASS CL_PRICE_DATA IMPLEMENTATION.
F4 for Reason Code
METHOD ON_F4.
FIELD-SYMBOLS: <FT_MODI> TYPE LVC_T_MODI .
REFRESH :GT_FIELD_TAB,GT_VALUE_TAB,GT_RETURN.
IF E_FIELDNAME = 'CTMBRCHGREASCD'.
LOOP AT VALUES_TAB INTO VALUE_TAB.
MOVE VALUE_TAB-CTMBRCHGREASCD TO GS_VALUE_TAB-STRING .
APPEND GS_VALUE_TAB TO GT_VALUE_TAB.
CLEAR : GS_VALUE_TAB.
MOVE VALUE_TAB-CTMBRCHGRSNDSC TO GS_VALUE_TAB-STRING .
APPEND GS_VALUE_TAB TO GT_VALUE_TAB.
CLEAR :GS_VALUE_TAB.
ENDLOOP.
GS_FIELD_TAB-FIELDNAME = 'CTMBRCHGREASCD' .
GS_FIELD_TAB-TABNAME = '/CPC/TCTMBRCHG'.
APPEND GS_FIELD_TAB TO GT_FIELD_TAB.
clear GS_FIELD_TAB.
GS_FIELD_TAB-FIELDNAME = 'CTMBRCHGRSNDSC' .
GS_FIELD_TAB-TABNAME = '/CPC/TCTMBRCHG'.
APPEND GS_FIELD_TAB TO GT_FIELD_TAB.
clear GS_FIELD_TAB.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
RETFIELD = 'CTMBRCHGREASCD'
VALUE_ORG = 'C'
TABLES
VALUE_TAB = GT_VALUE_TAB
FIELD_TAB = GT_FIELD_TAB
RETURN_TAB = GT_RETURN.
ASSIGN ER_EVENT_DATA->M_DATA->* TO <FT_MODI>.
GWA_MODI-ROW_ID = ES_ROW_NO-ROW_ID.
LOOP AT GT_RETURN INTO GWA_LS_RETURN .
GWA_MODI-FIELDNAME = GWA_LS_RETURN-FIELDNAME.
GWA_MODI-VALUE = GWA_LS_RETURN-FIELDVAL.
INSERT GWA_MODI INTO TABLE <FT_MODI>.
READ TABLE VALUES_TAB INTO VALUE_TAB WITH KEY CTMBRCHGREASCD =
GWA_LS_RETURN-FIELDVAL.
GWA_MODI-FIELDNAME = 'CTMBRCHGRSNDSC'.
GWA_MODI-VALUE = VALUE_TAB-CTMBRCHGRSNDSC.
INSERT GWA_MODI INTO TABLE <FT_MODI>.
ENDLOOP.
ER_EVENT_DATA->M_EVENT_HANDLED = 'TRUE'.
ELSEIF E_FIELDNAME = 'CONTMBRSTATCODE'.
loop at gt_member_status into gs_member_status.
MOVE gs_member_status-status TO GS_VALUE_TAB-STRING .
APPEND GS_VALUE_TAB TO GT_VALUE_TAB.
CLEAR : GS_VALUE_TAB.
MOVE gs_member_status-description TO GS_VALUE_TAB-STRING .
APPEND GS_VALUE_TAB TO GT_VALUE_TAB.
CLEAR :GS_VALUE_TAB.
endloop.
GS_FIELD_TAB-FIELDNAME = 'CONTMBRSTATCODE' .
GS_FIELD_TAB-TABNAME = '/CPC/TCTMBRHST'.
GS_FIELD_TAB-reptext = 'Member Status'.
APPEND GS_FIELD_TAB TO GT_FIELD_TAB.
clear GS_FIELD_TAB .
GS_FIELD_TAB-FIELDNAME = 'CTSTATSHRTDESC' .
GS_FIELD_TAB-TABNAME = '/CPC/TCONSTAT'.
APPEND GS_FIELD_TAB TO GT_FIELD_TAB.
GS_FIELD_TAB-FIELDNAME = 'CTMBRCHGRSNDSC' .
GS_FIELD_TAB-TABNAME = '/CPC/TCTMBRCHG'.
APPEND GS_FIELD_TAB TO GT_FIELD_TAB.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
RETFIELD = 'CONTMBRSTATCODE'
VALUE_ORG = 'C'
TABLES
VALUE_TAB = GT_VALUE_TAB
FIELD_TAB = GT_FIELD_TAB
RETURN_TAB = GT_RETURN.
ASSIGN ER_EVENT_DATA->M_DATA->* TO <FT_MODI>.
GWA_MODI-ROW_ID = ES_ROW_NO-ROW_ID.
LOOP AT GT_RETURN INTO GWA_LS_RETURN .
GWA_MODI-FIELDNAME = GWA_LS_RETURN-FIELDNAME.
GWA_MODI-VALUE = GWA_LS_RETURN-FIELDVAL.
INSERT GWA_MODI INTO TABLE <FT_MODI>.
READ TABLE VALUES_TAB INTO VALUE_TAB WITH KEY CTMBRCHGREASCD =
GWA_LS_RETURN-FIELDVAL.
GWA_MODI-FIELDNAME = 'CTMBRCHGRSNDSC'.
GWA_MODI-VALUE = VALUE_TAB-CTMBRCHGRSNDSC.
INSERT GWA_MODI INTO TABLE <FT_MODI>.
ENDLOOP.
ER_EVENT_DATA->M_EVENT_HANDLED = 'TRUE'.
ELSEIF E_FIELDNAME = 'SH_CUST_NMBR'.
LOOP AT GT_SHARED_CUSTOMER INTO GS_SHARED_CUSTOMER.
SELECT SINGLE CUST_NAME FROM /CPC/TCUSTOMER INTO
GS_SHARED_CUSTOMER-CUST_NAME
WHERE CUST_NMBR = GS_SHARED_CUSTOMER-SH_CUST_NMBR.
MOVE GS_SHARED_CUSTOMER-SH_CUST_NMBR TO GS_VALUE_TAB-STRING .
APPEND GS_VALUE_TAB TO GT_VALUE_TAB.
CLEAR : GS_VALUE_TAB.
MOVE GS_SHARED_CUSTOMER-CUST_NAME TO GS_VALUE_TAB-STRING .
APPEND GS_VALUE_TAB TO GT_VALUE_TAB.
CLEAR : GS_VALUE_TAB.
ENDLOOP.
GS_FIELD_TAB-FIELDNAME = 'SH_CUST_NMBR' .
GS_FIELD_TAB-TABNAME = '/CPC/TGRPSHRHLD'.
APPEND GS_FIELD_TAB TO GT_FIELD_TAB.
clear GS_FIELD_TAB.
GS_FIELD_TAB-FIELDNAME = 'CUST_NAME' .
GS_FIELD_TAB-TABNAME = '/CPC/TCUSTOMER'.
APPEND GS_FIELD_TAB TO GT_FIELD_TAB.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
RETFIELD = 'SH_CUST_NMBR'
VALUE_ORG = 'C'
TABLES
VALUE_TAB = GT_VALUE_TAB
FIELD_TAB = GT_FIELD_TAB
RETURN_TAB = GT_RETURN.
ASSIGN ER_EVENT_DATA->M_DATA->* TO <FT_MODI>.
GWA_MODI-ROW_ID = ES_ROW_NO-ROW_ID.
LOOP AT GT_RETURN INTO GWA_LS_RETURN .
GWA_MODI-FIELDNAME = GWA_LS_RETURN-FIELDNAME.
GWA_MODI-VALUE = GWA_LS_RETURN-FIELDVAL.
INSERT GWA_MODI INTO TABLE <FT_MODI>.
ENDLOOP.
ER_EVENT_DATA->M_EVENT_HANDLED = 'TRUE'.
ENDIF.
ENDMETHOD.
This will trigger when do a F4 on the field .
Apart from this in the fieldcatalog for that field assign 'X' for the field F4AVAILABL and also set handler eventobj->on_f4 for grid .
Please reward if useful. -
Visual tool for trigger development
I am looking for a visual tool for trigger (or PL/SQL) development that includes metadata. It should be a kind of ETL tool but specific for triggers. That would help a lot when documenting triggers, checking for dependencies, data lineage, etc.
Anyone know any tool from Oracle or out there?How about Oracle's very own SQLDeveloper?
http://www.oracle.com/technology/software/products/sql/index.html
Other option would be TOAD by quest
http://www.quest.com/toad_for_oracle/
or PL/SQL Developer from AllroundAutomations.com
http://www.allroundautomations.com/bodyplsqldev.html
Message was edited by:
satishkandi -
Creating search help for a field in AdHoc Query
Hi
We have created an infoset based on LDB PCH.
(The infoset contains object type O only).
For the object-id field the users want search help when choosing this field for selection.
Using "start via selection screen" does not give a good solution.
Can anyone explain how I can create search help for fields in an infoset?
Regards
KirstenHi
We have created an infoset based on LDB PCH.
(The infoset contains object type O only).
For the object-id field the users want search help when choosing this field for selection.
Using "start via selection screen" does not give a good solution.
Can anyone explain how I can create search help for fields in an infoset?
Regards
Kirsten -
Need to restrict values in F4 help for Batch Characteristic
Hi,
I need to restrict values in F4 Help for a batch characteristic based on values entered for another characteristic. I could not find any BADI or Exit for this purpose. There is a BADI CACL_VALUE which is triggered after an entry is selected from dropdown list but nothing when we press F4. I thought of using Object Dependency but I need to write a programming logic for the requirement. Please let me know if there is any way to write program in Object Dependency or any other way for this requirement.
Regards,
NikhilHi nikhil simha,
first of all, find out which search help is called.
[Hierarchy of the Search Help Call|http://help.sap.com/saphelp_nw70/helpdata/en/0b/32e9b798da11d295b800a0c929b3c3/frameset.htm]
may help you.
If you know the search help, you may enhance it, but first of all you should check the where-used-list and make sure that the search help shows the requested behavior only in the context where you want it to.
If it is your own program, you may be better off to create your own search help and define the triggering fields as search help interface input fields. Then you can use the values to filter results.
Regards
Clemens -
Search Help for Vendor Feild not getting populated in the Screen Element
Hi Everyone,
In transaction Miro, I get a POP-UP for Invoicing Party i.e. Vendor and Users required a custom search help.
The Search help for Vendor(LIFNR) is KRED_C and i appended a Z search help under this.
Now that the search help exists and I can drill down the values too but when i select/choose any value, that value is not getting populated in Screen feild.
is there any validation I need to do for this.
Please suggest me... I checked SDN there are many things but i couldn't figure out wat i need to do and where I need to modify.
Regards,
RajDear Hema,
Could you please tell me how many internal tables you are using to store the data for display.
I observerd that you have lt_stock and lt_mat2 declared in the part of the program
>DATA: lv_stock TYPE lty_stock.
>DATA: ltmat2 TYPE TABLE OF lty_mat.
you have displayed above, however you are also using ls_stock and lv_stock .
>IF p_ztotal = ' '. "line
>WRITE 18 ls_stock-matnr.
>WRITE 38 lv_stock-strgr.
>
>ELSEIF ztotal = 'S'. "subtotal
>WRITE: 15 ls_stock-nrmit.
>WRITE 32 lv_stock-dispo.
>WRITE 43 lv_stock-fevor.
>ELSE. "total
>WRITE: 15 'TOTAL'(016), ls_stock-prgrp.
>
>ENDIF.
Are those for displaying some other information?
Also the problem of display you are facing can also be because there are no records to be displayed which satisfies the selection criteria.
Best Regards,
Rajesh.
Please reward points if found helpful. -
Search help for SKAT-SAKNR OR SKAT-SAKNR is not working
Hi All,
I have created a Search Help for F4 in a dialog program for SKAT-SAKNR OR SKAT-SAKNR. While i click F4 on that field, it displays blank values.
Here is the module:
module HELP_FOR_SAPGL_ACC input.
CLEAR t_SAPGL.
SELECT SAKNR TXT20
FROM SKAT
INTO CORRESPONDING FIELDS OF TABLE t_SAPGL UP TO 1000 ROWS
WHERE SPRAS = SY-LANGU.
WHERE L_GL_ACC = v_FIELD_VALUE-FIELDVALUE.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
DDIC_STRUCTURE = ' '
RETFIELD = 'SAKNR'
PVALKEY = ' '
DYNPPROG = PROGNAME
DYNPNR = DYNNUM
DYNPROFIELD = 'SKA1-SKANR'
STEPL = 0
WINDOW_TITLE =
VALUE = ' '
VALUE_ORG = 'S'
MULTIPLE_CHOICE = ' '
DISPLAY = ' '
CALLBACK_PROGRAM = ' '
CALLBACK_FORM = ' '
MARK_TAB =
IMPORTING
USER_RESET =
TABLES
VALUE_TAB = t_SAPGL
FIELD_TAB =
RETURN_TAB =
DYNPFLD_MAPPING =
EXCEPTIONS
PARAMETER_ERROR = 1
NO_VALUES_FOUND = 2
OTHERS = 3
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
endmodule.
In the above code I am selecting 1000 rows from SKAT table and in the Search Help Popup it is also displaying 1000 rows but all are blank.
Please help me.
Regards,
AvaneetHi check my weblog on search help exit codeing..
https://wiki.sdn.sap.com/wiki/x/du0
\* Prepare for output
CALL FUNCTION 'F4UT_RESULTS_MAP'
TABLES
shlp_tab = shlp_tab
record_tab = record_tab
source_tab = lt_result
CHANGING
shlp = shlp
callcontrol = callcontrol
EXCEPTIONS
illegal_structure = 1
OTHERS = 2.
IF rc = 0.
callcontrol-step = 'DISP'.
ELSE. -
I have problem with buying in games , I got the massage that the purchased can not be completed , please contact iTunes support.. I need help for my case please
http://www.apple.com/support/itunes/contact/
-
Search help for date field in Editable ALV
Hello Friends,
I am using editable alv using 'reuse_* '.
I have used date as input field. While creating fieldcatlog also i have declared dat as a mkpf-budat.
But i am not getting serach help for date in output.
Is it possible with reuse or i have to go by object oriented ?Hi,
Just pass the Edit option of the fieldcatalog for those specific fields...
fcat-edit = 'X'.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_program = sy-cprog
i_callback_pf_status_set = 'PF_STATUS_SET'
i_callback_user_command = 'USER_COMMAND' "<---- pass this
i_callback_top_of_page = 'TOP'
is_layout = it_layout
it_fieldcat = it_fcat
i_default = 'X'
i_save = 'A'
it_events = it_event
TABLES
t_outtab = it_final
EXCEPTIONS
program_error = 1
OTHERS = 2.
*& Form USER_COMMAND
* text
* -->R_UCOMM text
* -->RS_SELFIELD text
FORM user_command USING r_ucomm LIKE sy-ucomm
rs_selfield TYPE slis_selfield.
CASE r_ucomm.
WHEN '&DATA_SAVE'. "<-------check this
PERFORM save_data.
ENDCASE.
ENDFORM. "USER_COMMAND -
How to create a F4 help for a report selection screen field
hi,
can any one guide me to create F4 help for a field in a selection screen in a report program,plz give me a sample codehi,
Here are the following ways
1.with the help of match code objects we can create the F4 Functionality for Field.
Syntax is :
PARAMETERS: p_org LIKE t527x-orgeh MATCHCODE OBJECT zorg.
2. One more thing is we can do it with Search Help's also.
3. Even we can do it HELP Views also.
Help Views:
You have to create a help view if a view with outer join is needed as selection method of a search help
The selection method of a search help is either a table or a view. If you have to select data from several tables for the search help, you should generally use a database view as selection method. However, a database view always implements an inner join. If you need a view with outer join for the data selection, you have to use a help view as selection method.
All the tables included in a help view must be linked with foreign keys. Only foreign keys that have certain attributes can be used here. The first table to be inserted in the help view is called the primary table of the help view. The tables added to this primary table with foreign keys are called secondary tables.
The functionality of a help view has changed significantly between Release 3.0 and Release 4.0. In Release 3.0, a help view was automatically displayed for the input help (F4 help) for all the fields that were checked against the primary table of the help view. This is no longer the case in Release 4.0.
As of Release 4.0, you must explicitly create a search help that must be linked with the fields for which it is offered (see Linking Search Helps with Screen Fields ).
Existing help views are automatically migrated to search helps when you upgrade to a release higher than 4.0.
A help view implements an outer join, i.e. all the contents of the primary table of the help view are always displayed. You therefore should not formulate a selection condition for fields in one of the secondary tables of the help view. If records of these secondary tables cannot be read as a result of this selection condition, the contents of the corresponding fields of the secondary table are displayed with initial value.
<REMOVED BY MODERATOR>
Edited by: Alvaro Tejada Galindo on Feb 15, 2008 3:15 PM -
Reg : F4 help for custom fields in ALV report
hi friends..
in my internal table i have fields including 1 custom field..
DATA : BEGIN OF i_final OCCURS 0,
pernr LIKE p0000-pernr,
begda LIKE p0000-begda,
plans LIKE ZPOSITION-plans, (custom)
werks LIKE pspar-werks,
end of i_final.
i want to display this i_final table in alv. for that i genetrate one fieldcatalog
PERFORM fcat USING:
'I_FINAL' 'PERNR' 'P0000' 'PERNR' '15' 'X' '',
'I_FINAL' 'BEGDA' 'P0000' 'BEGDA' '10' 'X' '',
'I_FINAL' 'PLANS' 'ZPOSITION' 'PLANS' '8' 'X' '',
'I_FINAL' 'WERKS' 'PSPAR' 'WERKS' '14' 'X' ''.
in custom table zposition, i maintain serch help for custom field "PLANS".
then i used reuse_alv_grid_display.. for all the std fields along wit custom fields
i got f4 all std fields but for my custom i am not getting the f4 help
how can i get the F$ help for this custom fields Zposition-plans..
plz give some ideaHi
In that Ztable against the field
PLANS give the check table name as <b>T528B</b>
then it will automatically give the search help
or you can create your own search help(elementary) and add to that field
Reward if useful
regards
Anji -
How to add a search help for a field in alv?
HI!Everyone ,
i want to add a search help created by myself for one field in alv,
and i want to use this function "HELP_VALUES_GET_WITH_TABLE".
can anyone help me ?
thanks!HI,Vijay.
My code like this :
PERFORM build_fcat.
PERFORM build_objects.
PERFORM layo_build.
PERFORM set_drdn_table .
CALL METHOD alv_grid->set_table_for_first_display
EXPORTING
i_structure_name = 'STU_S'
is_layout = s_layo
CHANGING
it_outtab = itab_out
it_fieldcatalog = i_fcat
."Period
IF sy-subrc <> 0.
EXIT.
ENDIF.
for example, there is a field 'UNAME' IN Structure 'STU_S',
i want to add a search help for 'UNAME'.
the 'UNAME' is not users in SAP R/3 , i want to add some data by myself or from a table . -
How to add search help for field in ALV object
Hello,
In a program, we use ALV object ( container) to create a liste like : field1, field2 .. but when display we do not have search help for this . Could you please help me how to add match code in this case for field 1 and field2, We use set_table_for_first_display
Thanks,Hi,
when you define your field catalogue you can create data elements with search help in se11 and use them for field 1 and field 2.
But maybe it is enough to use data elements belonging to a domain with a value help and to set field F$AVAILABL in the field catalogue or to fill the name of the field CHECKTABLE.
Regards,
Klaus
Maybe you are looking for
-
I had a new hard drive installed and my original ghosted over. The drive is guid formatted and now has about 120 gigs of "free space" that I can't seem to touch. If I try to reboot from my orginal drive in an external inclosure via firewire it always
-
Upgraded to 4.0, added fire FTP and all of my settings carried over. Now it just sits there and tries to connect. It does not connect. What needs to be done?
-
Restriction in event reported date and time
Dear All, We have a requirement where we want to keep check on all the reported events such that none of the events are reported with future date and time. We have some 25 reporting events and we have an option to keep the check
-
Getting started with HP Connect
I downloader the HP Connect app to my android phone and my hp laptop. I looks like I've lost some o my photos. Ii don't know what to do and not techie enoug to understand what I'm find on the web. Help.
-
How to enable commenting tools in Adobe Reader in a C# application
When Iam using Adobe Reader, Iam not able to get the JSObject to set Collab.showAnnotToolsWhenNoCollab = true. Please let me know how to proceed enabling comminting tools for Adobe Reader Please do let me know if you require any other details Thanks,