Help in select performance
hi,
i need to select data from table catsdb but i have lot of
recored like 2,000.000 records ,
i see that this table have secondary index ,
maybe this can help ?
how i use it?
Best Regards
If you don't specfiy what you want to select, then nobody undertsand why you need the secondary key. Maybe the primary is also o.k.
Just write your select and use all information in the where condition which you have.
It will always work, but if will only perform well, if you have the first fields or all of an index in the WHERE condition.
You don't need a package size, the table has 2.000.000 records, but I hope you want to select much less.
Siegfried
Similar Messages
-
Problem on Search Help for select-option
Hi,
Iam working on a search help for select-option,
is there a way to incorporate select-all or multiple
selection on this?
Thanks!Hi catherine,
1. Just copy paste this program.
(It will POPULATE the SELECT-OPTION,
based upon
MULTIPLE Selection,
selected by the user,
in the help provided thru F4IF_INT_TABLE_VALUE_REQUEST.)
2. Eg. is for BUKRS (company code)
3.
REPORT ABC.
TABLES : T001.
DATA : ITAB LIKE TABLE OF T001 WITH HEADER LINE.
DATA : RETURN LIKE TABLE OF DDSHRETVAL WITH HEADER LINE.
SELECT-OPTIONS : BUKRS FOR T001-BUKRS.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR BUKRS-LOW.
PERFORM MYPOPULATE.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR BUKRS-HIGH.
PERFORM MYPOPULATE.
FORM MYPOPULATE.
REFRESH ITAB.
SELECT * FROM T001 INTO TABLE ITAB.
call function 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield = 'BUKRS'
dynprofield = 'BUKRS'
dynpprog = sy-REPID
dynpnr = sy-dynnr
multiple_choice = 'X'
value_org = 'S'
TABLES
value_tab = ITAB
return_tab = return.
IF RETURN[] IS NOT INITIAL.
REFRESH BUKRS.
CLEAR BUKRS.
LOOP AT RETURN.
BUKRS-SIGN = 'I'.
BUKRS-OPTION = 'EQ'.
BUKRS-LOW = RETURN-FIELDVAL.
BUKRS-HIGH = RETURN-FIELDVAL.
APPEND BUKRS.
ENDLOOP.
ENDIF.
ENDFORM.
regards,
amit m. -
I have copied many photo's from another laptop to my Mac. The older photo's are in directories with names that help me select what I need to view. I would like to have all my imported new photo's also bee added to the directory structure I have in Finder but my new photo's are all in iPhoto. I want to use directories for storing and iPhoto for viewing. Is this possible or do I need to have all my photo's in iPhoto??
MitchiPhoto is not a Photo Viewer. It's a Photo Manager and designed for looking after the files while you organise the Photos. It really works much better if you let it manage those files. If you use iPhoto you never go near those files because iPhoto is your start point for anything you want to do with your Photos - the point of the pplication.
You can run iPhoto in Referenced mode, where it does not copy the files to the Library, but I caution you that you are making life a lot more difficult for yourself by doing that.
How to, and some comments on why you shouldn't, are in this thread
https://discussions.apple.com/thread/3062728?tstart=0
Regards
TD -
Restricting values F4 help in selection screen-Urgent
Hi,
can anyone pls tell how can I ristrict the values for search help in any field in selection screen.
please tell me the way to hide some values in F4 help in selection screen so that user can not see those data for selection.
Regardsi think u can not hide the data.........
create own f4 help............restrict the data and then pass it the f4 internal table....
fro exp;;;;;
types : begin of ty_tab,
post_code1 like adrc-post_code1,
end of ty_tab.
data : it_tab type ty_tab occurs 0.
data : lt_field type table of dfies,
lw_field type dfies.
select post_code1 from adrc into corresponding fields of table it_tab.
call function 'F4IF_INT_TABLE_VALUE_REQUEST'
exporting
retfield = 'POST_CODE1'
dynpprog = sy-repid
dynpnr = sy-dynnr
dynprofield = 'LI_LIST1'
value_org = 'S'
tables
value_tab = it_tab
field_tab = lt_field
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.
Regards
Anbu -
How to created Freely Programmed F4 help in Select Options
hi,all
I have a probelm about how to created a Freely Programmed F4 help in Select Options,and put help value into select options field
Thanks and Best RegardsHi Haung,
You need to use FREE_HELP not the component name.
Modify you code as below:
LT_RANGE_TABLE_V = wd_this->m_handler_V->create_range_table( 'ZCYPHDATE' ).
wd_this->M_HANDLER_V->add_selection_field(
i_id = 'ZCYPHDATE'
it_result = LT_RANGE_TABLE_V
i_value_help_type = if_wd_value_help_handler=>CO_PREFIX_APPLDEV
i_value_help_id = 'FREE_HELP'
i_no_intervals = abap_false ).
Hope this helps you.
Regards,
Rama -
[Oracle 8i] Help with query performance
The following query is running VERY slowly for me:
SELECT oord.part_nbr
, sopn.ord_nbr
, sopn.sub_ord_nbr
, sopn.major_seq_nbr
, sopn.wctr_id
, sopn.oper_desc
, SUM(pact.act_dlrs_earned+pact.act_brdn_dls_earned+pact.tool_dlrs_earned+pact.act_fix_brdn_dls_ea)
, pact.activity_date
FROM PACT pact
, SOPN sopn
, OORD oord
WHERE pact.order_nbr = sopn.ord_nbr AND
pact.maj_seq_nbr = sopn.major_seq_nbr AND
sopn.sub_ord_nbr = pact.sub_order_nbr AND
sopn.ord_nbr = oord.ord_nbr AND
sopn.sub_ord_nbr = oord.sub_ord_nbr AND
pact.activity_date >= ? AND
sopn.rework_ind = 'N' AND
(oord.part_nbr, sopn.major_seq_nbr, sopn.wctr_id)
NOT IN (
SELECT rout.doc_nbr
, rout.major_seq_nbr
, rout.wctr_id
FROM ROUT rout
WHERE (rout.begn_eff_dt <=SYSDATE) AND
(rout.end_eff_dt >SYSDATE) AND
(rout.po_rework_ind ='N')
GROUP BY oord.part_nbr
, sopn.ord_nbr
, sopn.sub_ord_nbr
, sopn.major_seq_nbr
, sopn.wctr_id
, sopn.oper_desc
, pact.activity_dateI sent a request off to my IT department (specifically asking for the explain plan and tkprof, as described in the [main post on this topic|http://forums.oracle.com/forums/thread.jspa?threadID=501834] ), and they replied with a screen shot of the 'explain plan' the tool they use (Toad) provides.
!http://temp-sample.webs.com/explain_plan.jpg!
I don't know if anyone can help me based off this, since I know it's not really what the main post says to provide, but it's all I was given.
My IT department also made a few changes to my original query (see below) and told me it got rid of one of the full scans of the PACT table, but they aren't sure why it helped, and I have to say I'm suspect of any fixes where it's not understood why it helped.
SELECT oord.part_nbr
, sopn.ord_nbr
, sopn.sub_ord_nbr
, sopn.major_seq_nbr
, sopn.wctr_id
, sopn.oper_desc
, SUM(pact.act_dlrs_earned+pact.act_brdn_dls_earned+pact.tool_dlrs_earned+pact.act_fix_brdn_dls_ea)
, pact.activity_date
FROM PACT pact
, SOPN sopn
, OORD oord
WHERE sopn.ord_nbr = pact.order_nbr AND
sopn.major_seq_nbr = pact.maj_seq_nbr AND
pact.sub_order_nbr = sopn.sub_ord_nbr AND
oord.ord_nbr = sopn.ord_nbr AND
oord.sub_ord_nbr = sopn.sub_ord_nbr AND
(pact.activity_date >= ?) AND
'N' = sopn.rework_ind AND
pact.order_nbr = oord.ord_nbr AND
oord.sub_ord_nbr = pact.sub_order_nbr AND
(oord.part_nbr, pact.maj_seq_nbr, sopn.wctr_id) NOT IN
SELECT /*+ INDEX_JOIN(ROUT) */ rout.doc_nbr
, rout.major_seq_nbr
, rout.wctr_id
FROM ROUT rout
WHERE rout.begn_eff_dt <= SYSDATE AND
rout.end_eff_dt > SYSDATE AND
'N' = rout.po_rework_ind
GROUP BY oord.part_nbr
, sopn.ord_nbr
, sopn.sub_ord_nbr
, sopn.major_seq_nbr
, sopn.wctr_id
, sopn.oper_desc
, pact.activity_dateAny help on this would be appreciated... when I run this (right now) for 2-3 months of data, it takes a minimum of 3 hours to complete, and I'll eventually need to run this for up to a year's worth of data.Hi,
Well, let's see.
You get 156 rows returned using IN and 121 rows using exists.
You need identify the 'missing records' and conclude if that's correct or not, I'm not able to do that from remote, without knowing your data or system.
It would be helpful if we could see cost and cardinalities, you (or your IT dept.) can get them easily be running the queries from your SQL*Plus prompt.
Type
SET AUTOTRACE TRACEONLYbefore running the queries.
That gives you the explain plan and additional statistics (sorts in memory and sorts to disk).
Since you use a group by, and you're on 8i can you also post results of these queries:
select banner from v$version;
select name, value, isdefault from v$parameter where name like '%area%';Finally, does below query give you a different plan?
select oord.part_nbr
, oord.ord_nbr
, oord.sub_ord_nbr
, pact.major_seq_nbr
, sopn.wctr_id
, sopn.oper_desc
, sum(pact.act_dlrs_earned + pact.act_brdn_dls_earned + pact.tool_dlrs_earned + pact.act_fix_brdn_dls_ea)
, pact.activity_date
from oord oord
, pact pact
, sopn sopn
where oord.ord_nbr = pact.order_nbr
and oord.sub_ord_nbr = pact.sub_order_nbr
and oord.ord_nbr = sopn.ord_nbr
and oord.sub_ord_nbr = sopn.sub_ord_nbr
and sopn.major_seq_nbr = pact.maj_seq_nbr
and (pact.activity_date >= ?)
and 'N' = sopn.rework_ind
and (oord.part_nbr, pact.maj_seq_nbr, sopn.wctr_id) not in ( select rout.doc_nbr
, rout.major_seq_nbr
, rout.wctr_id
from rout rout
where rout.begn_eff_dt <= sysdate
and rout.end_eff_dt > sysdate
and 'N' = rout.po_rework_ind)
group by oord.part_nbr
, oord.ord_nbr
, oord.sub_ord_nbr
, pact.major_seq_nbr
, sopn.wctr_id
, sopn.oper_desc
, pact.activity_date -
Can i assign a collective srch help for select option in list display
can i assign a collective srch help for select option in list display
Hi,
Yes ,u can assign a collective search help for select-option in list display.
Eg:
Define your select option like this
SELECT-OPTIONS: s_vbeln FOR likp-vbeln MATCHCODE OBJECT vmva.
Regards,
Shiva. -
How to get calender in f4 help for select options in module pool (URGENT)
Hi All,
how to get calender in f4 help for select options in module pool
Please help .
Thanx in advance,
amrutaHi Amruta,
First of all, you can not create select-options directly in module pool.
For creating <b>select-option is dialog prog</b> follow these steps:
1. create your selection screen model as subscreen by:
SELECTION-SCREEN BEGIN OF SCREEN 2000 AS SUBSCREEN.
PARAMETRS: P_MATNR LIKE MARA-MATNR.
SELECT-OPTIONS: S_BISMAT FOR MARA-BISMAT.
SELECTION-SCREEN END OF SCREEN 2000.
2. create a screen ( example 100 ) in your module-pool dedicated for selection-screen. on this screen layout sketch a sub-screen name like subscree_2000.
3. write this bit of code in PBO and PAI of the screen 100;
CALL SUBSCREEN SUBSCREEN_2000.
4. include this code in PBO:
INCLUDING SY-REPID '2000'
6. write user_command of PAI, call screen which is going to executable after selection-screen.
5. create a transcation for this dialog module pool with screen 100.
6. execute this transaction and you can see it's behaving like cool with select-options.
After that in [bprocee on value-request]</b>, use F4_DATE for both from and to option field.
Hope it will solve the problem.
Regards
Krishnendu -
Need help on select statement...
Hi,
I need to fetch from vbfa table those records where vbeln starts with '0800'.
my select statement given below gives a syntax error..pl help.
SELECT * FROM vbfa WHERE vbeln(4) = '0800'.
vbeln(4) is not accepted and i get the message ' field vbeln(4) is unknown' ...what to do?
thksUse LIKE. Please see F1 on this.
Rob
(changed CP to LIKE)
Edited by: Rob Burbank on Sep 15, 2008 11:18 AM -
F4 help for select options based on parameter value
hi all,
I need a help to create an F4 help for select options for object id based on parameter value of object type, I mean once an object type is given the f4 help should contain object id's only of that type for each option.
Regard's,
Girija
Moderator Message : Duplicate post locked. Continue with [f4 help for select options based on parameter value |f4 help for select options based on parameter value;.
Edited by: Vinod Kumar on May 17, 2011 1:36 PMhi all,
I need a help to create an F4 help for select options for object id based on parameter value of object type, I mean once an object type is given the f4 help should contain object id's only of that type for each option.
Regard's,
Girija
Moderator Message : Duplicate post locked. Continue with [f4 help for select options based on parameter value |f4 help for select options based on parameter value;.
Edited by: Vinod Kumar on May 17, 2011 1:36 PM -
Hi its urgent...help on selection screen parameters
Hi all,
I need help on selection screen parameters.
requirement is that,
i am having input fields for material, plant ,start date and end date and a check box and an input field for getting the txt file.
when i select the checkbox, it should ignore the mandatory fileds in the selection screen.
and when i get the file input, it should take the input data material, plant, start date and end date from the flat file and populate the corresponding input fields in selection screen.
How to do this..
thanks in advance.Hi ..
While declare the Matnr, Plant etc dont use the OBLIGATORY addition.
instead of the based on the value of check box validate them .
AT SELECTION-SCREEN.
IF c_box = ' '.
<< validate for mandatory fields>>
endif.
<b>REWARD IF HELPFUL.</b> -
Search help on select optionbased on other select ooption entered
hi,
I need to know search help for selection screen based on value entered in another select options
SELECT-OPTIONS : s_bukrs FOR bkpf-bukrs OBLIGATORY,
s_belnr FOR bkpf-belnr,
s_gjahr FOR bkpf-gjahr OBLIGATORY,
s_budat FOR bkpf-budat OBLIGATORY,
s_akont FOR lfb1-akont,
s_saknr FOR bseg-saknr. """"""""""
*PARAMETERS : p_akont type lfb1-akont.
here i need to get the vaues of s_akont based on values entered in s_bukrs,
In event at selection screeen for s_akont i am writing
SELECT a~bukrs
a~saknr
a~mitkz
b~txt50
FROM skb1 AS a
INNER JOIN skat AS b
ON asaknr = bsaknr
INTO CORRESPONDING FIELDS OF TABLE lt_skb1
WHERE bukrs IN s_bukrs
AND mitkz = 'K'
AND b~spras = 'EN'.
but not getting value of s_bukrs at this point of execution. I requir the fiels in select statement in F4 of s_akont.
what are the function modules to call and what is the way to do??
thanks..Check the below solution for your issue - The FM "'RS_SELECTIONSCREEN_READ" is used to get the S_BUKRS values. Even though the FM returns single values of the Select options ( Low & High ) it fits the requirement.As the trick part is...If user enters multiple values or even enters sign for select options, S_BUKRS itself will have the value. That's why we have If else S_BUKRS[] is initial and R_BUKRS. Let me know if you have any issues with the solution provided.
TABLES: bkpf, lfb1.
DATA lt_fieldvalues TYPE STANDARD TABLE OF rsselread.
DATA ls_fieldvalue TYPE rsselread.
DATA r_bukrs TYPE RANGE OF bkpf-bukrs.
DATA ls_bukrs LIKE LINE OF r_bukrs.
SELECT-OPTIONS: s_bukrs FOR bkpf-bukrs,
s_akont FOR lfb1-akont.
INITIALIZATION.
ls_fieldvalue-name = 'S_BUKRS'.
ls_fieldvalue-kind = 'S'.
ls_fieldvalue-position = 'LOW'.
APPEND ls_fieldvalue TO lt_fieldvalues.
ls_fieldvalue-name = 'S_BUKRS'.
ls_fieldvalue-kind = 'S'.
ls_fieldvalue-position = 'HIGH'.
APPEND ls_fieldvalue TO lt_fieldvalues.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR s_akont-low.
refresh r_bukrs.
clear ls_bukrs.
IF s_bukrs[] IS INITIAL.
CALL FUNCTION 'RS_SELECTIONSCREEN_READ'
EXPORTING
program = sy-repid
dynnr = '1000'
TABLES
fieldvalues = lt_fieldvalues.
IF NOT lt_fieldvalues[] IS INITIAL.
ls_bukrs-sign = 'I'.
READ TABLE lt_fieldvalues INTO ls_fieldvalue WITH KEY position = 'LOW'.
IF sy-subrc EQ 0.
ls_bukrs-low = ls_fieldvalue-fieldvalue.
ENDIF.
READ TABLE lt_fieldvalues INTO ls_fieldvalue WITH KEY position = 'HIGH'.
IF sy-subrc EQ 0.
ls_bukrs-high = ls_fieldvalue-fieldvalue.
ENDIF.
IF ls_bukrs-high IS NOT INITIAL.
ls_bukrs-option = 'BT'.
ELSE.
ls_bukrs-option = 'EQ'.
ENDIF.
if ls_bukrs-low is not initial or ls_bukrs-high is not initial.
APPEND ls_bukrs TO r_bukrs.
endif.
ENDIF.
ELSE.
r_bukrs[] = s_bukrs[].
ENDIF.
SELECT a~bukrs a~saknr a~mitkz b~txt50 FROM skb1 AS a
INNER JOIN skat AS b
ON a~saknr = b~saknr
INTO CORRESPONDING FIELDS OF TABLE lt_skb1
WHERE bukrs IN r_bukrs " Changed to r_burks
AND mitkz = 'K'
AND b~spras = 'EN'. -
Search help in selection screens for interactive report
A search help can only be assigned to DB table.
So my doubt is can it also be used for seletion screens created for an interactive report?
If yes what is the procedure.. Please give me one example at least...
waiting for your valuable suggestions.....
Thanks,
regards,
ChinmayHi Chinmay,
I suppose your requirement is to give search help to selection screen elements.
Here is the code.
REPORT ZSHAIL_F4HELP .
parameters: name(10) type c .
TYPES: BEGIN OF VALUES,
CARRID TYPE SPFLI-CARRID,
CONNID TYPE SPFLI-CONNID,
END OF VALUES.
dATA: PROGNAME LIKE SY-REPID,
DYNNUM LIKE SY-DYNNR,
DYNPRO_VALUES TYPE TABLE OF DYNPREAD,
FIELD_VALUE LIKE LINE OF DYNPRO_VALUES,
VALUES_TAB TYPE TABLE OF VALUES.
at selection-screen on value-request for name.
CALL FUNCTION 'F4IF_FIELD_VALUE_REQUEST'
EXPORTING
tabname = 'DEMOF4HELP'
fieldname = 'CARRIER1'
SEARCHHELP = ' '
SHLPPARAM = ' '
DYNPPROG = PROGNAME
DYNPNR = DYNNUM
DYNPROFIELD = 'CARRIER'
STEPL = 0
VALUE = ' '
MULTIPLE_CHOICE = ' '
DISPLAY = ' '
SUPPRESS_RECORDLIST = ' '
CALLBACK_PROGRAM = ' '
CALLBACK_FORM = ' '
SELECTION_SCREEN = ' '
IMPORTING
USER_RESET =
TABLES
RETURN_TAB =
EXCEPTIONS
FIELD_NOT_FOUND = 1
NO_HELP_FOR_FIELD = 2
INCONSISTENT_HELP = 3
NO_VALUES_FOUND = 4
OTHERS = 5
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
AT SELECTION-SCREEN OUTPUT.
PROGNAME = SY-REPID.
DYNNUM = SY-DYNNR.
CLEAR: FIELD_VALUE, DYNPRO_VALUES.
FIELD_VALUE-FIELDNAME = 'CARRIER'.
APPEND FIELD_VALUE TO DYNPRO_VALUES.
I hope your query is solved.
If so,please award points.
Regards,
Sylendra. -
Could any one tell the FM for F4 help to select the file from application server.
Hi,
Try this one..
REPORT ZTESTAPPL.
data: t_filetab type table of SALFLDIR with header line,
t_spopli type table of spopli with header line.
parameters p_dir like SALFILE-LONGNAME default 'D:\SAPWORKING'.
call function 'RZL_READ_DIR_LOCAL'
exporting
name = p_dir
tables
file_tbl = t_filetab
EXCEPTIONS
ARGUMENT_ERROR = 1
NOT_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.
loop at t_filetab.
if t_filetab-size ne space.
t_spopli-varoption = t_filetab-name.
append t_spopli.
clear t_spopli.
endif.
endloop.
call function 'POPUP_TO_DECIDE_LIST'
exporting
CURSORLINE = 1
MARK_FLAG = 'X'
MARK_MAX = 25
START_COL = 0
START_ROW = 0
textline1 = 'Choose Files'
TEXTLINE2 = ' '
TEXTLINE3 = ' '
titel = 'File Selection'
DISPLAY_ONLY = ' '
IMPORTING
ANSWER =
tables
t_spopli = t_spopli
EXCEPTIONS
NOT_ENOUGH_ANSWERS = 1
TOO_MUCH_ANSWERS = 2
TOO_MUCH_MARKS = 3
OTHERS = 4
if sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
endif.
loop at t_spopli.
if t_spopli-selflag ne ' '.
write :/ 'Selected File: ' , t_spopli-varoption.
endif.
reward points if helpful -
Add custom field in the F4 help for selecting source field in tcode FMDER
HI,
I an working in FUND MANAGEMENT, i want to add custom field in the F4 help for selecting source field in t-code FMDERIVE.
How this possible.
Regards,
PankajOK
Maybe you are looking for
-
BPEL Server classpath has priority over a BPEL Process classpath
Hi all I developed a BPEL process which uses org.apache.commons.io.FileUtils class (latest version 1.3.1) through a <bpel exec> activity. However, when I deploy it to a BPEL 10.1.3 server it throws an exception warning me that the method doens´t exis
-
Latest MacBook Pro able to run Rosetta?
I plan to seek a used MacBook Pro that is able to run Rosetta on Snow Leopard. What is the latest model able to do so?
-
I have the same JRE error does anyone out there have a solution?
See previous post for error message: I am trying to install Oracle 8.1.6 on a Windows 98 machine. When I attempt to run the setup.exe I get an error message:"Unable to locate ../.../.../jre.exe. Please log on to www.javasoft.com and download JRE 1.1.
-
Where is the api documentation?
Um, I signed up for my key and cannot find the api docs anywhere. Would someone please provide a link to the api documentation? Thank you.
-
Button images broken ? - in TAB(2) Red1
I switched from the "simple tabs with breadcrums" page template to the "TAB(2)Red1" template and tried to make use of the Einstein1 Button templates - but all Buttons do have incomplete images: The left and the right part of the image is OK - but the