2007 Mar 07 9:34 PM
i got a performance issue with the following select:
SELECT SINGLE vbeln netwr knumv
FROM VBAK
INTO (v_vbeln, v_netwr, v_knumv)
WHERE auart = p_tipo
AND bstnk = pti_zcmtt_envase-ref.
how do i complete a key when i don't have it i mean is there a way to make something to complete the index fields even when you don't know the exactly values, thanks.
2007 Mar 07 9:37 PM
Hi,
Perhaps you can create secondary index for table VBAK with MANDT, AUART and BSTNK fields or database view (SE11).
Regards,
Ferry Lianto
i got a performance issue with the following select:
SELECT SINGLE vbeln netwr knumv
FROM VBAK
INTO (v_vbeln, v_netwr, v_knumv)
WHERE auart = p_tipo
AND bstnk = pti_zcmtt_envase-ref.
how do i complete a key when i don't have it i mean is there a way to make something to complete the index fields even when you don't know the exactly values, thanks.
2007 Mar 07 9:37 PM
Hi,
Perhaps you can create secondary index for table VBAK with MANDT, AUART and BSTNK fields or database view (SE11).
Regards,
Ferry Lianto
2007 Mar 07 9:40 PM
but without creating a secondary index, is there a way to complete the index key with a condition that always be true, i mean something like audat GT 19900101??? how this affects my performance is it a good practice or no?
2007 Mar 07 9:40 PM
Hi,
I believe there is an index on the customer purchase order number BSTNK..
Try this..
SELECT VBELN NETWR KNUMV
UP TO 1 ROWS
FROM VBAK
WHERE bstnk = pti_zcmtt_envase-ref
AND auart = p_tipo
ENDSELECT.
Thanks
Naren
2007 Mar 07 9:47 PM
Hi,
You can try to add field AUDAT in your select statement since there is secondary index AUD for field AUDAT. It should improve the performance.
Regards,
Ferry Lianto
2007 Mar 07 9:53 PM
exactly that's what i want but how do i add the 'audat' field if don't know it?? or i use it in a condition that always be true??
| User | Count |
|---|---|
| 6 | |
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |