Needed selection screen validation for all entries in the range
Hi all,
I'm using the below code for Material validation in selection-screen.
SELECT SINGLE MATNR FROM MARC INTO MARC-MATNR
WHERE MATNR IN S_MATNR.
IF sy-subrc NE 0.
MESSAGE e000(su) WITH text-035. "Invalid Material Number
ENDIF.
This validation is working only for one record in the range.
If I give multiple material numbers in the range having a record which doesn't exist in MARC, its not throwing the error.
Seems like loop should be placed at s_matnr. Is that correct procedure or any pointers on the same would be of great help.
Regards,
Vamsee Priya.
Hi priya
Use this way,
REFRESH IT_LIPS. CLEAR IT_LIPS.
SELECT VBELN
POSNR
MATNR
WERKS
LFIMG
ARKTX
VGBEL
VGPOS
BWART
FROM LIPS INTO TABLE IT_LIPS
WHERE PSTYV IN
('ZZTC', 'ZTAD', 'ZMVN', 'ZCVA', 'ZCVB', 'ZCVC') AND "ASR 18721
WERKS IN ('1140', '1143', '1149').
IF IT_LIPS[] IS INITIAL.
MESSAGE E000 WITH TEXT-005.
endif.
revert back if you need any help..
Help us to help you, Manas
Similar Messages
-
Performance issue with select query and for all entries.
hi,
i have a report to be performance tuned.
the database table has around 20 million entries and 25 fields.
so, the report fetches the distinct values of two fields using one select query.
so, the first select query fetches around 150 entries from the table for 2 fields.
then it applies some logic and eliminates some entries and makes entries around 80-90...
and then it again applies the select query on the same table using for all entries applied on the internal table with 80-90 entries...
in short,
it accesses the same database table twice.
so, i tried to get the database table in internal table and apply the logic on internal table and delete the unwanted entries.. but it gave me memory dump, and it wont take that huge amount of data into abap memory...
is around 80-90 entries too much for using "for all entries"?
the logic that is applied to eliminate the entries from internal table is too long, and hence cannot be converted into where clause to convert it into single select..
i really cant find the way out...
please help.chinmay kulkarni wrote:Chinmay,
Even though you tried to ask the question with detailed explanation, unfortunately it is still not clear.
It is perfectly fine to access the same database twice. If that is working for you, I don't think there is any need to change the logic. As Rob mentioned, 80 or 8000 records is not a problem in "for all entries" clause.
>
> so, i tried to get the database table in internal table and apply the logic on internal table and delete the unwanted entries.. but it gave me memory dump, and it wont take that huge amount of data into abap memory...
>
It is not clear what you tried to do here. Did you try to bring all 20 million records into an internal table? That will certainly cause the program to short dump with memory shortage.
> the logic that is applied to eliminate the entries from internal table is too long, and hence cannot be converted into where clause to convert it into single select..
>
That is fine. Actually, it is better (performance wise) to do much of the work in ABAP than writing a complex WHERE clause that might bog down the database. -
Selection Screen Validation for Character
Hi All
My query is regarding the selection screen validation for character.
I am using a Select-option: S_ORDER FOR VBAK-VBELN OBLIGATORY.
and S_order should be only having the numeric field.
Please help how to validate it for character field.Hi,
Do as below :
at selection-screen.
if not s_order[] is initial.
if s_order-low CA 'ABCDEF.............Z'.
message 'Enter only numerics only' type 'E'.
endif.
"similarly for s_order-high also.
endif.
Thanks,
Sriram Ponna. -
Advice required on a select statement using "FOR ALL ENTRIES"
Hi,
this is really intresting ...
I have a small requirement where in i have to find out
the valid entries in my internal table (T_MATNR) by using a select statement to a check table (MARA) which has all the fields present in the internal table T_MATNR.
Select statement is
SELECT MATNR
MTART
from MARA
for all entries in T_MATNR
into table T_MATNR
where matnr eq T_MATNR-MATNR.
If you observe the itab in the option 'FOR ALL ENTRIES' and the destination table is the same. I want to know whether this is correct? will it cause any performance issue? right now this statement is working fine for me.Hi,
U have to use
SELECT MATNR
MTART
from MARA
<b>into table I_MATNR(different table)</b>
for all entries in T_MATNR
where matnr eq T_MATNR-MATNR.
If u r specifying both same table name then for what entries it will retrieve, if u have alreay selected some entries and appending u can use
SELECT MATNR
MTART
from MARA
<b>into table T_MATNR</b>where matnr eq T_MATNR-MATNR.
then
SELECT MATNR
MTART
from MARA
<b>appending table T_MATNR</b>
for all entries in T_MATNR
where matnr eq T_MATNR-MATNR.
In this way u can do.
Hope u got it. -
Select SUM in FOR ALL ENTRIES Select Query
Hi ,
I am using for all entries select statment ,can any one guide me how can i use SUM in the select statment with for all entries .
Regards,
VeeraHi,
THis is not possible using for all entries.
Thanks,
Sriram Ponna. -
Select ... for all entries problem
Hi,
I'm making select statements to BKPF and BSEG, but I can't do an inner join between this two table because BSEG it's a cluster table so I have to do a SELECT... FOR ALL ENTRIES, but in SE16 I make the same query that I have writen in my program as shown below,
SELECT BUKRS BELNR GJAHR BUDAT MONAT
FROM BKPF INTO CORRESPONDING FIELDS OF TABLE it_bkpf
WHERE BUKRS = 'XXX'
AND GJAHR = '2005'
AND BELNR = '0000000250'. "just for proof
AND MONAT = '10'
The above query returns me 1 row in program and in SE16 and then I make the next query for BSEG to do the join
SELECT BUKRS BELNR GJAHR BSCHL SHKZG WRBTR HKONT
FROM BSEG INTO CORRESPONDING FIELDS OF TABLE IT_BSEG
FOR ALL ENTRIES IN it_bkpf
WHERE bukrs = it_bkpf-bukrs
and gjahr = it_bkpf-gjahr
and belnr = it_bkpf-belnr.
this query returns 897 rows and in SE16 this same query returns 901 rows
Why SELECT...FOR ALL ENTRIES brings me less rows affected by the query in SE16
Thanks for your help!!Hi,
Please use the following code for selcting the exact number of rows.
IF it_bkpf[] IS NOT INITIAL.
SELECT *
FROM BSEG INTO CORRESPONDING FIELDS OF TABLE IT_BSEG
FOR ALL ENTRIES IN it_bkpf
WHERE bukrs = it_bkpf-bukrs
and gjahr = it_bkpf-gjahr
and belnr = it_bkpf-belnr.
ENDIF.
Instead of * ,you can specify the exact fields required along with all the key fields as selection fields.Also it is must to check the condition it_bkpf[] IS NOT INITIAL before using the statement FOR ALL ENTRIES IN it_bkpf.Suppose if this condition is not used and if it_bkpf is initial,it will fetch all entries from the table.
Reward if helpful.
Regards,
Aravind -
For all entries changes the order of the itab
Hi Experts
In the following query i have used two internal tables namely it_first and it_zlist.
The material inwhich the it_zlist is different sorting order
After executing this query, the order of the material inwhich the it_first is different from the it_zlist.
What could be the reason, pls explain me on this.
select matnr test zsno ztnam from zmaster1
into corresponding fields of table it_first
for all entries in it_zlist
where matnr = it_zlist-matnr.
Thanks in advance.
Regards
Rajaramfor all entries u should specified all primary key.
sort by u condition.
Effect
If the addition FOR ALL ENTRIES is specified before the language element WHERE, then the components comp of the internal table itab can be used as operands when comparing with relational operators.
The internal table itab must have a structured line type and the component comp must be compatible with the column col.
The logical expression sql_cond of the WHERE condition can comprise various logical expressions by using AND and OR. However, if FOR ALL ENTRIES is specified, there must be at least one Comparison with a column of the internal table itab, which can be specified either statistically or dynamically (Release 6.40 and higher). In a statement with a SELECTstatement with FOR ALL ENTRIES, the addition ORDER BY can only be used with the addition PRIMARY KEY.
The whole logical expression sql_cond is evaluated for each individual line of the internal table itab. The resulting set of the SELECT statement is the union of the resulting sets from the individual evaluations. Duplicate lines are automatically removed from the resulting set. If the internal table itab is empty, the whole WHERE statement is ignored and all lines in the database are put in the resulting set.
Notes
In Release 6.10 and higher, the same internal table can be specified after FOR ALL ENTRIES and after INTO.
The addition FOR ALL ENTRIES is only possible before WHERE conditions of the SELECT statement.
If the additions PACKAGE SIZE or UP TO n ROWS are specified together with FOR ALL ENTRIES, they are not passed to the database system but are applied instead to the resulting set once all selected rows on the application server have been imported.
With duplicated rows in the resulting set, the addition FOR ALL ENTRIES has the same effect as if addition DISTINCT were specified in the definition of the selection quantity. Unlike DISTINCT, the rows are not deleted from the database system but are deleted on the application server from the resulting set.
Addition FOR ALL ENTRIES is only possible for WHERE conditions of the SELECT statement.
Example
Exporting all flight data for a specified departure city. The relevant airlines and flight numbers are first put in an internal table entry_tab, which is evaluated in the WHERE condition of the subsquent SELECT statement. -
Facin problems in the 'Select... for all entries'
I am facing problem with this piece of code, please share ur thoughts on it. I have specified the inputs.
I am extracting the open items from the BSIS table for specified 3 account number.
Inputs to the prg:
field No. of values
r_bukrs 1
r_hkont 2
r_blart 6
r_budat date range of 1 yr
r_bldat nil
v_tosdef contain 1 account number
" In each FI document posted, one line will have the 'v_tosdef' account number and one account from the 'r_hkont' values."
So will this query efficient.
SELECT bukrs
hkont
gjahr
belnr
budat
bldat
xblnr
blart
shkzg
dmbtr
FROM bsis
INTO TABLE i_bsis
WHERE bukrs IN r_bukrs " Company code
AND hkont = v_tosdef " Account number
AND budat IN r_budat " Posting date
AND bldat IN r_bldat " Document date
AND blart IN r_blart. " Document type
IF sy-subrc <> 0.
MESSAGE i003.
STOP.
ENDIF.
*@ Collecting the BELNR & GJAHR From the extracted records
li_bsis[] = i_bsis[].
SORT li_bsis BY bukrs gjahr belnr.
DELETE ADJACENT
DUPLICATES FROM li_bsis
COMPARING bukrs gjahr belnr.
IF NOT li_bsis[] IS INITIAL.
SELECT bukrs
hkont
gjahr
belnr
budat
bldat
xblnr
blart
shkzg
dmbtr
FROM bsis
APPENDING TABLE i_bsis
FOR ALL ENTRIES IN li_bsis
WHERE bukrs = li_bsis-bukrs " Company code
AND hkont IN r_hkont " Account number
AND gjahr = li_bsis-gjahr " Fiscal year
AND belnr = li_bsis-belnr. " Document num
BSIS table size around 86GB
primary index size aroung 33GB
and the index quality is 54%
the CBO shows less cost, but the actual runs takes too much disk read's / bgets..
Message was edited by:
SandyHi Sandy,
You indicated the size of the tables and index, what is the total number of records in your BSIS?
In your range tables, make sure they are postive formed.
Ex. r_bukrs : I EQ '1001', and not I NE '1000'.
You should consider coding your statements to check for input for bldat, code it with r_bldat and then another set without. It should be better performance to not have empty where conditions. So two routines, Selects with bldat and without.
Don't know if you have a Basis person to help analyze the performance, but you should look at the indexes in BSIS. You may have several indexes that contain some of your input fields but they may be spread across several indexes or there may be none. But say you have 5 indexes and it happens that just one of your parameters are in each of those indexes. Well, it can only use one index so while you think you are providing alot of parameters to help performance only one field is being used to access the index. What you need to do then is to find an index that has the most fields in your where clause and see if you can add to that, so long it's not an SAP index. If it's a z index consider adding additional fields to it, or consider creating a new index.
You can at least analyze the first Select in your DEV client. Run a trace, ST05 and then execute your code. It will show you which index it has used if any.
Also, look at the query values it is passing to the database. You said you get 6 M records on the first Select. This just seem like a lot of records, which is for just one account number (v_tosdef) along with the other parameters. I'm wondering if there's a problem with your input data. With 6M in your first table, your FOR ALL ENTRIES statement will be executed 1.2 million times. Tyically the database interface breaks down your Select-For All entries statement into 5 records per query. Again, run ST05 and you will see this.
In SE16, on your BSIS table, what is your count of records if you enter only the account number?
As a test, you might want to try entering all your parameters in SE16, run ST05 to trace the SQL to see what it is doing. You may have to kill your SE16 session or it may time out on you. You can stop your ST05 trace before your SE16 finishes and it will still show how SAP is going after the data and what index it used.
Let me know if this helped any.
Regards,
Filler -
Select query like For all Entries
Hi,
I have a requirement like:
I need to extract data (BKTXT) from table BKPF based on some criteria, into one internal table and I need to query on REGUP table for the above data, the selection criteria on REGUP as follows:
BKTXT(Document Header Text with 25 Char) is a combination of DATE and character string.
Ex: bkpf-bktxt = 20060710-PL02 (YYYYMMDD)
it is like LAUFD + LAUFI (of table REGUP)
i.e: LAUFD (REGUP) = 07/10/2006 (MM/DD/YYYY) and LAUFI(REGUP) = PL02
here I am thinking to use a select query on REGUP using FOR ALL ENTRIES of table i_bkpf..
How can I change the date format YYYYMMDD to MM/DD/YYYY for my requirement?
(( Run-on Date (REGUP-LAUFD) = the first 8 characters in the Document Header Text (BKPF- BKTXT) in MM/DD/YYYY date format (e.g. 07/10/2006)
Run ID (REGUP-LAUFI) = the 10th character through the 15th character in the Document Header Text (BKPF- BKTXT)It is not possible to do in the way you are thinking of doing. "For all entries" requires you to have the itab table field and the database table field to have the same type and length. So something like below <u>will not work</u>.
TABLES: regup.
DATA: BEGIN OF itab OCCURS 0,
text LIKE bkpf-bktxt.
DATA: END OF itab.
DATA: BEGIN OF itab_regup OCCURS 0.
INCLUDE STRUCTURE regup.
DATA: END OF itab_regup.
SELECT * INTO TABLE itab_regup
FROM regup FOR ALL ENTRIES IN itab
WHERE laufd = itab-text+0(8).
If you run this code, you will get an error as follows:
<i>"When using the addition "FOR ALL ENTRIES IN itab", the fields "LAUFD" and "ITAB-TEXT+0(8)" must have the same type and length."</i> -
Selection screen validation for batch
This is my scenario:
If program is executed in background, plant (in selection screen) is not mandatory.
If program is executed directly, plant (in selection screen) needs to be filled (mandatory).
I tried using sy-batch and coding at the AT SELECTION-SCREEN portion for validation but it seems that sy-batch is only populated after START-OF-SELECTION.
How do i code it so that if user does not execute program in background, it will prompt an error message and prompt user to fill the plant field in the selection screen?HI,
use sy-batch in start-of-selection. not in at selection-screen.
start-of-selection.
if sy-batch = ' X' . (If it runs in background)
Then raise message.
endif.
This will work.
Reward If helpful. -
Select... for all entries in...
Hi,
Can anybody help me to sort out this issue. This select should work. I m filling an itab with distinct pernr. in temp it should give <b>all the records for which pernr should not be in itab.</b>
report ZTEST4.
data : begin of ITAB occurs 0,
PERNR like PA0001-PERNR,
ename like pa0001-ename,
end of ITAB.
data : temp like itab occurs 0 with header line.
clear : ITAB, TEMP.
refresh : ITAB,TEMP.
select distinct PERNR into table ITAB from PA0001 where PERNR le 10.
select PERNR ENAME into table TEMP from PA0001
for all entries in ITAB where pernr not in itab-pernr.
sort TEMP by PERNR.
break-point.Hi Sagar,
If i understand it well, you exclude all PERNR LE 10.
But first things first.
You cannot use the FOR ALL ENTRIES in your case (it doesn't allow the operator "NOT IN").
Your code should be:
REPORT ztest4.
TYPES: BEGIN OF ty_itab,
pernr TYPE persno,
ename TYPE emnam,
END OF ty_itab.
DATA : itab TYPE ty_itab occurs 0,
wtab TYPE ty_itab.
CLEAR: itab,
wtab.
SELECT pernr ename
INTO TABLE itab
FROM pa0001
WHERE pernr LE 10
ORDER BY pernr.
IF sy-subrc EQ 0.
DELETE ADJACENT DUPLICATES FROM itab COMPARING pernr.
ENDIF.
Regards,
Rob. -
Select statment using FOR ALL ENTRIES not allow to do sum,
Hi All,
SELECT DELIV_NUMB
SUM( GRS_WGT_DL )
UNIT_OF_WT
FROM /BIC/AGSSD000600
INTO TABLE I_GROSS
FOR ALL ENTRIES IN I_LAYTWO
WHERE DELIV_NUMB = I_LAYTWO-DELIV_NUMB
GROUP BY DELIV_NUMB UNIT_OF_WT.
While compiling it shows the error
The addition "FOR ALL ENTRIES" excludes all aggregate functions with
the exception of "COUNT( * )", as the single element of the SELECT
clause.
Please give some solution to do sum
with regards,
Thambe .You could just select all entries into an internal table and then loop through and use COLLECT or similar to get your sum values.
Gareth. -
Select fom table for all entries where field starts with value
Hello
I want to write a select like this
select * from bsis
into lt_bsis
for all entries in lt_itab
where xblnr like lt_itab-belnr%
I want to select all the entries from bsis where the field xblnr starts with the values found in lt_itab-belnr.
for example
ls_itab-belnr = 5100000028
bsis-xblnr = 510000002810001
510000002810002
510000002810003
520000002810001
and i want to select only the entries that start with 5100000028 in this case
Can anybody help?
ThanksHi,
I hope below example code will help you to fix your issue,
REPORT ytest.
TYPES : BEGIN OF ty_typ1,
val TYPE i,
END OF ty_typ1.
TYPES : BEGIN OF ty_typ2,
val1 TYPE hrobjid,
val2 TYPE hrobjid,
END OF ty_typ2.
DATA : int_typ1 TYPE TABLE OF ty_typ1,
int_typ2 TYPE TABLE OF ty_typ2,
wa_typ1 TYPE ty_typ1,
wa_typ2 TYPE ty_typ2,
int_1001 TYPE TABLE OF hrp1001,
wa_1001 TYPE hrp1001.
REFRESH : int_typ1, int_typ2, int_1001.
CLEAR : wa_typ1, wa_typ2, wa_1001.
wa_typ1-val = 500001.
APPEND wa_typ1 TO int_typ1.
wa_typ1-val = 500002.
APPEND wa_typ1 TO int_typ1.
wa_typ1-val = 500003.
APPEND wa_typ1 TO int_typ1.
wa_typ1-val = 500001.
APPEND wa_typ1 TO int_typ1.
SORT int_typ1 ASCENDING BY val.
DELETE ADJACENT DUPLICATES FROM int_typ1 COMPARING val.
LOOP AT int_typ1 INTO wa_typ1.
wa_typ2-val1 = ( wa_typ1-val * 100 ) + 1.
wa_typ2-val2 = wa_typ2-val1 + 98.
APPEND wa_typ2 TO int_typ2.
CLEAR : wa_typ1, wa_typ2.
ENDLOOP.
SELECT * FROM hrp1001 INTO TABLE int_1001
FOR ALL ENTRIES IN int_typ2 WHERE
plvar EQ '01' AND
otype EQ 'S' AND
sclas EQ 'O' AND
begda LE sy-datum AND
endda GE sy-datum AND
objid GE int_typ2-val1 AND
objid LE int_typ2-val2.
LOOP AT int_1001 INTO wa_1001.
WRITE : / wa_1001-objid.
ENDLOOP.
Thanks & Regards,
Harish Kumar N -
How does select stmt with for all entries uses Indexes
Hello all,
I goes through a number of documents but still confused how does select for all entries uses indexes if fields are not in sequences. i got pretty much the same results if i take like two cases on Hr tables HRP1000 and HRP1001(with for all entries based upon hrp1000). Here is the sequence of index fields on hrp1001 (MANDT, OTYPE, OBJID, PLVAR, RSIGN, RELAT, ISTAT, PRIOX, BEGDA, ENDDA, VARYF, SEQNR). in second case objid field is in sequence as in defined Index but i dont see significant increase in field even though the number of records are around 30000. My question is does it make a differrence to use field sequence (same as in table indexes) in comparison to redundant field sequence (not same as defined in table indexes), secondly how we can ge tto know if table index is used in Select for entries query i tried Explain in ST05 but its not clear if it uses any index at all in hrp1001 read.
here is the sample code i use to get test results.
test case 1
REPORT zdemo_perf_select.
DATA: it_hrp1000 TYPE STANDARD TABLE OF hrp1000 WITH HEADER LINE.
DATA: it_hrp1001 TYPE STANDARD TABLE OF hrp1001 WITH HEADER LINE.
DATA: it_hrp1007 TYPE STANDARD TABLE OF hrp1007 WITH HEADER LINE.
DATA: it_pa0000 TYPE STANDARD TABLE OF pa0000 WITH HEADER LINE.
DATA: it_pa0001 TYPE STANDARD TABLE OF pa0001 WITH HEADER LINE.
DATA: it_pa0002 TYPE STANDARD TABLE OF pa0002 WITH HEADER LINE.
DATA: it_pa0105_10 TYPE STANDARD TABLE OF pa0105 WITH HEADER LINE.
DATA: it_pa0105_20 TYPE STANDARD TABLE OF pa0105 WITH HEADER LINE.
DATA: t1 TYPE timestampl,
t2 TYPE timestampl,
t3 TYPE timestampl
SELECT * FROM hrp1000 CLIENT SPECIFIED INTO TABLE it_hrp1000 bypassing buffer
WHERE mandt EQ sy-mandt AND
plvar EQ '01' AND
otype EQ 'S'AND
istat EQ '1' AND
begda <= sy-datum AND
endda >= sy-datum AND
langu EQ 'EN'.
GET TIME STAMP FIELD t1.
SELECT * FROM hrp1001 CLIENT SPECIFIED INTO TABLE it_hrp1001 bypassing buffer
FOR ALL ENTRIES IN it_hrp1000
WHERE mandt EQ sy-mandt AND
otype EQ 'S' AND
* objid EQ it_hrp1000-objid and
plvar EQ '01' AND
rsign EQ 'B' AND
relat EQ '007' AND
istat EQ '1' AND
begda LT sy-datum AND
endda GT sy-datum and
sclas EQ 'C' and
objid EQ it_hrp1000-objid.
* %_hints mssqlnt 'INDEX(HRP1001~0)'.
*delete it_hrp1001 where sclas ne 'C'.
GET TIME STAMP FIELD t2.
t3 = t1 - t2.
WRITE: 'Time taken - ', t3.
test case 2
REPORT zdemo_perf_select.
DATA: it_hrp1000 TYPE STANDARD TABLE OF hrp1000 WITH HEADER LINE.
DATA: it_hrp1001 TYPE STANDARD TABLE OF hrp1001 WITH HEADER LINE.
DATA: it_hrp1007 TYPE STANDARD TABLE OF hrp1007 WITH HEADER LINE.
DATA: it_pa0000 TYPE STANDARD TABLE OF pa0000 WITH HEADER LINE.
DATA: it_pa0001 TYPE STANDARD TABLE OF pa0001 WITH HEADER LINE.
DATA: it_pa0002 TYPE STANDARD TABLE OF pa0002 WITH HEADER LINE.
DATA: it_pa0105_10 TYPE STANDARD TABLE OF pa0105 WITH HEADER LINE.
DATA: it_pa0105_20 TYPE STANDARD TABLE OF pa0105 WITH HEADER LINE.
DATA: t1 TYPE timestampl,
t2 TYPE timestampl,
t3 TYPE timestampl
SELECT * FROM hrp1000 CLIENT SPECIFIED INTO TABLE it_hrp1000 bypassing buffer
WHERE mandt EQ sy-mandt AND
plvar EQ '01' AND
otype EQ 'S'AND
istat EQ '1' AND
begda <= sy-datum AND
endda >= sy-datum AND
langu EQ 'EN'.
GET TIME STAMP FIELD t1.
SELECT * FROM hrp1001 CLIENT SPECIFIED INTO TABLE it_hrp1001 bypassing buffer
FOR ALL ENTRIES IN it_hrp1000
WHERE mandt EQ sy-mandt AND
otype EQ 'S' AND
objid EQ it_hrp1000-objid and
plvar EQ '01' AND
rsign EQ 'B' AND
relat EQ '007' AND
istat EQ '1' AND
begda LT sy-datum AND
endda GT sy-datum and
sclas EQ 'C'." and
* objid EQ it_hrp1000-objid.
* %_hints mssqlnt 'INDEX(HRP1001~0)'.
*delete it_hrp1001 where sclas ne 'C'.
GET TIME STAMP FIELD t2.
t3 = t1 - t2.
WRITE: 'Time taken - ', t3.Mani wrote:
Thank you for your answer, its very helpful but i am still nor sure how does parameter rsdb/max_blocking_factor affect records size.
Hi,
The blocking affects the size of the statement and the memory structures for returning the result.
So if your itab has 500 rows and your blocking is 5, the very same statement will be executed 100 times.
Nothing good or bad about this so far.
Assume, your average result for an inlist 5 statement is 25 records with an average size of 109 bytes.
You average result size will be 2725 byte plus overhead which will nearly perfectly fit into two 1500 byte ethernet frames.
Nothing to do in this case.
Assume your average result for an inlist 5 statement is 7 records with an average size of 67 bytes.
You average result size will be ~ 470 byte plus overhead which will only fill 1/3 of a 1500 byte ethernet frame.
In this case, setting the blocking to 12 ... 15 will give you 66% network transfer performance gain,
and reduces the number of calls to the DB by 50%, giving additional benefit.
Now this is an extreme example. The longer the average row length is, the lower will be the average loss in the network.
You have the same effects in memory structures, but on that layer you are fighting single micro seconds instead of
hundreds of these, so in real life it is rarely measurable.
Depending on table-statistics, oracle might decide for short inlists to use a concatanation instead of an inlist.
This is supposed to be more costy, but I never had a case where I could proove a big difference.
Values from 5 to 15 for blocking seem to be ok for me. If you have special statements in customer coding,
it #might# be benefitial to do the mentioned calculations and do some network tracing to see if you can squeeze your
network efficiency by tuning the blocking.
If you have jumbo frames enabled, it might be worth to be analyzed as well.
If you are only on a DB-CI system that is loopback connected to the DB, I doubt there might be a big outcome.
Hope this helps
Volker -
Selection screen control for a field in the report painter report
Hi,
Could you please advice me as to how we can add exclude selection functionality for a field on the selection screen of a report made by trhough report painter report.
Your prompt reply will be really appreciated.
Thanks,
Ramesh.look at this code and try
select-options : S_NODEID for ZNODETAB-ZNODEID.
at selection-screen on value-request for s_nodeid-low
perform f4_nodeid using 'S_NODEID-LOW'.
at selection-screen on value-request for s_nodeid-low
perform f4_nodeid using 'S_NODEID-HIGH'.
end-of-selection.
FORM f4_nodeid USING p_field.
declare it_node.
select znodeid from ZNODETAB into table it_node.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield = 'ZNODEID'
dynpprog = sy-repid
dynpnr = sy-dynnr
dynprofield = p_field
value = space
value_org = 'S'
display = 'F'
TABLES
value_tab = it_node
EXCEPTIONS
parameter_error = 1
no_values_found = 2
OTHERS = 3.
endform
Maybe you are looking for
-
How do I add remember password for a new web site?
I am trying to have Firefox remember a password for a specific website. I go to Options, then Security but have great difficulty thereafter. Can you give me specific data to enter, where to enter it and how to save the password? Thank you Al Landry
-
Creating query on Bex - Quaterly comparison for statistical & Actual
Hi All, I would like to create a query for 'Quarterly comparison for statistical & Actual periods'. My Key Figures should be 1) Plan 1st Qtr (Fiscal year, Period: 1 to 3, Value type : 1(Plan), Version : 0(Plan/actual), Valuation View: actual Value).
-
Reporting: Multi-value select prompt
Multi-value select prompt: Need to verify if there is a limit to the number of items/size in a drop down list or if there are selected value limitations.
-
How do we get Chinese keyboard support in Lion
How do we get Chinese character support in Lion using American keyboard?
-
Hi, I been configured WebDAV repository by connecting to content server which is installed on UNIX o.s. these are the below stpes i followed 1.created a New System from template by choosing u201CKM WebDAV Systemu201D 2.done user mapping and assigned