Deletion flag ISU OBJECTS
Hello experts.
We have a process in which we need to mark to deletion (archiving) some ISU objects. The problem is, so far, we could not find any deletion/archiving function, method or flag (LOEVM) for:
- ISU CONNECTION OBJECT.
- ISU DEVICE LOCATION
We really appreciate any help.
Regards.
Nicolas
You must create a new archiving object. More information about creation of archiving object you can found here:
http://help.sap.com/SAPHELP_NW04S/helpdata/en/2a/fa043a493111d182b70000e829fbfe/frameset.htm
It seems to me that you can use "PM_IFLOT" as example.
Similar Messages
-
Problem :ALV:Deletion Flags not showing in output
hi all !
I have a alv program which displays customer data.there are three deletion flags columns in the output.
First deletion flag will be: KNA1-LOEVM
Second deletion flag will be: KNB1-LOEVM
Third deletion flag will be: KNVV-LOEVM
earlier all three were showing.but now no one is showing.i'm pasting my code here if any expert can have a look and find out the BUG.
CODE STARTS----
report zqsdcap_cust.
INCLUDE DECLARATIONS
include:
ziabapcapph_macros. "Holcim Useful Macros
TABLE DECLARATIONS
tables:
tvko, "Org. Unit: Sales Organizations
t001, "Company codes
kna1, "Customer Master
knvv, "Customer master sales
knvi, "Customer tax classificat'n
knb1, "Customer master company code
<<CR003-DEVK949538 start ins
adr6. "SMTP numbers
<<CR003-DEVK949538 end ins
TYPE DECLARATIONS
type-pools:
slis.
STRUCTURE DECLARATIONS
Define structure for keep data in ALV list
data: begin of gs_output_list,
vkorg like knvv-vkorg, "Sales organization
ktokd like kna1-ktokd, "Customer A/C grp
kunnr like kna1-kunnr, "Customer number
vtweg like knvv-vtweg, "Distribution channel
name1 like kna1-name1, "Name1
name3 like kna1-name3, "Name3
name4 like kna1-name4, "Name4
stras like kna1-stras, "Street
cityc like kna1-cityc, "City
bezei1 like t005h-bezei, "Sales office
land1 like kna1-land1, "Country
regio like kna1-regio, "Region
bezei2 like t005u-bezei, "Region decription
kdgrp like knvv-kdgrp, "Customer group
ktext like t151t-ktext, "Cust grp name
bzirk like knvv-bzirk, "Sales district
bztxt like t171t-bztxt, "Description
zterm like knvv-zterm, "Payment term
lzone like kna1-lzone, "Transport zone
vtext like tzont-vtext, "Description
erdat like kna1-erdat, "Creation date
end of gs_output_list.
Internal table for customer tax data
data: begin of gs_output_tax,
vkorg like knvv-vkorg, "Sales organization
kunnr like kna1-kunnr, "Customer number
vtweg like knvv-vtweg, "Distribution channel
name1 like kna1-name1, "Name1
name3 like kna1-name3, "Name3
name4 like kna1-name4, "Name4
ort01 like kna1-ort01, "City
stcd1 like kna1-stcd1, "STD code
spart like knvv-spart, "Division
taxkd like knvi-taxkd, "Tax classific'n
tatyp like knvi-tatyp, "Tax category
vtext like tskdt-vtext, "Tax description
end of gs_output_tax.
Internal table for HVL customer master
data: begin of gs_output_hvl,
kunnr like kna1-kunnr, "Customer number
stceg like kna1-stceg, "VAT registration no
telfx like kna1-telfx, "Fax number
telf1 like kna1-telf1, "First telephone number
stras like kna1-stras, "House number and stret
ort02 like kna1-ort02, "District
cityc like kna1-cityc, "City code
bezei like t005h-bezei, "City description
regio like kna1-regio, "Region
ort01 like kna1-ort01, "City
name2 like kna1-name2, "Name2
name1 like kna1-name1, "Name1
bzirk like knvv-bzirk, "Sales district
spart like knvv-spart, "Division
vtweg like knvv-vtweg, "Distribution channel
vkorg like knvv-vkorg, "Sales organization
end of gs_output_hvl.
Internal table for customer database CRM
data: begin of gs_output_crm,
vkorg like knvv-vkorg, "Sales organization
vtweg like knvv-vtweg, "Distribution channel
bzirk like knvv-bzirk, "Sales district
kunnr like kna1-kunnr, "Customer number
name1 like kna1-name1, "Name1
name2 like kna1-name2, "Name2
stras like kna1-stras, "House number street
ort01 like kna1-ort01, "City
ort02 like kna1-ort02, "District
pstlz like kna1-pstlz, "Postal code
cityc like kna1-cityc, "City code
telf1 like kna1-telf1, "First telephone number
telfx like kna1-telfx, "Fax number
vkbur like knvv-vkbur, "Sales office
regio like kna1-regio, "Region
vkgrp like knvv-vkgrp, "Sales group
kdgrp like knvv-kdgrp, "Customer group
kvgr3 like knvv-kvgr3, "Customer group 3
altkn like knb1-altkn, "Previous record number
erdat like knvv-erdat, "Creation date
found_dat like zcrm_bp_ext-found_dat, "Found date
<<CR000-DEVK943142 start del
versg like knvv-versg, "Customer statistic grp
bukrs like knb1-bukrs, "Company code
<<CR000-DEVK943142 end del
end of gs_output_crm.
Internal table for customer information
data: begin of gs_output_info,
kunnr like kna1-kunnr, "Customer number
vkorg like knvv-vkorg, "Sales organization
vtweg like knvv-vtweg, "Distribution channel
stcd2 like kna1-stcd2, "Tax code
name1 like kna1-name1, "Name1
name2 like kna1-name2, "Name2
<<CR002-DEVK944835 start ins
name3 like kna1-name3, "Name3
<<CR002-DEVK944835 end ins
stras like kna1-stras, "House number street
ort01 like kna1-ort01, "City
ort02 like kna1-ort02, "District
pstlz like kna1-pstlz, "Postal code
regio like kna1-regio, "Region
land1 like kna1-land1, "Country code
cityc like kna1-cityc, "City code
telf1 like kna1-telf1, "First telephone number
telfx like kna1-telfx, "Fax number
<<CR001-DEVK944239 start ins
bzirk like knvv-bzirk, "Sales District
vkbur like knvv-vkbur, "Sales Office
kdgrp like knvv-kdgrp, "Customer group
<<CR001-DEVK944239 end ins
vkgrp like knvv-vkgrp, "Sales group
kvgr3 like knvv-kvgr3, "Customer group 3
versg like knvv-versg, "Customer stat grp
kdkg2 like kna1-kdkg2, "Customer condition gp2
kdkg1 like kna1-kdkg1, "Customer condition gp1
<<CR001-DEVK944239 start del
kdgrp like knvv-kdgrp, "Customer group
<<CR001-DEVK944239 end del
altkn like knb1-altkn, "Previous record#
erdat like knvv-erdat, "Creation date
note_text(200) type c, "<<CR003-DEVK949538 ins
smtp_addr like adr6-smtp_addr, "<<CR003-DEVK949538 ins
loevm1 like kna1-loevm, "Deletion flag all
loevm2 like knb1-loevm, "Deletion flag Cd
loevm3 like knvv-loevm, "Deletion flag sal
end of gs_output_info.
ALV Grid Declaration
data:
gs_fieldcat type slis_fieldcat_alv,
gs_layout type slis_layout_alv,
gs_event type slis_t_event,
gs_variant like disvariant,
gs_sort_info type slis_sortinfo_alv,
gs_exit_caused_by_user type slis_exit_by_user,
gs_tabname type slis_tabname,
gs_header type slis_entry.
INTERNAL TABLE DECLARATIONS
Define internal table for keep data in ALV list
data:
gt_output_list like table of gs_output_list,
gt_output_tax like table of gs_output_tax,
gt_output_hvl like table of gs_output_hvl,
gt_output_crm like table of gs_output_crm,
gt_output_info like table of gs_output_info,
<<CR003-DEVK949538 start ins
gv_text like tline occurs 0 with header line,
<<CR003-DEVK949538 start ins
ALV Grid Declaration
gt_fieldcat type slis_t_fieldcat_alv,
gt_list_top_of_page type slis_t_listheader,
gt_list_top_of_page2 type slis_t_listheader,
gt_sort_info type slis_t_sortinfo_alv.
VARIABLE DECLARATIONS
data:
ALV Grid Declaration
gv_save,
gv_exit_caused_by_caller,
gv_repid type sy-repid,
gv_user_command type slis_formname value 'USER_COMMAND',
gv_top_of_page type slis_formname value 'TOP_OF_PAGE',
gv_top_of_list type slis_formname value 'TOP_OF_LIST',
gv_end_of_list type slis_formname value 'END_OF_LIST',
lv_store like thead-tdname, "<<CR003-DEVK949538 ins
lv_id like thead-tdid, "<<CR003-DEVK949538 ins
lv_lines type i. "<<CR003-DEVK949538 ins
SELECTION SCREEN DECLARATIONS
Define selection-screen of query
selection-screen: begin of block blk with frame title text-001.
select-options: s_vkorg for knvv-vkorg "Sales org
obligatory
memory id vko,
s_bzirk for knvv-bzirk, "Sales district
s_vtweg for knvv-vtweg, "Dist channel
s_spart for knvv-spart "Division
default 'CM',
s_taxkd for knvi-taxkd, "Tax classific'n
s_kunnr for kna1-kunnr, "Customer number
s_regio for kna1-regio, "Region
s_kdgrp for knvv-kdgrp, "Customer group
s_vkgrp for knvv-vkgrp, "Sales group
s_vkbur for knvv-vkbur, "Sales office
s_lzone for kna1-lzone, "Zone
s_erdat for kna1-erdat, "Creation date
s_zuawa for knb1-zuawa, "Key for sorting
s_ktokd for kna1-ktokd, "Customer A/C grp
s_altkn for knb1-altkn, "Previous rec no
s_bukrs for knb1-bukrs "Company code
obligatory
memory id buk,
s_loevm1 for kna1-loevm, "Deletion flag all
s_loevm2 for knb1-loevm, "Deletion flag Cd
s_loevm3 for knvv-loevm. "Deletion flag sal
selection-screen: end of block blk.
selection-screen: begin of block b2 with frame title text-002.
parameters: pr_cust1 radiobutton group a1
default 'X'
user-command bkg,
pr_cust2 radiobutton group a1,
pr_cust3 radiobutton group a1,
pr_cust4 radiobutton group a1,
pr_cust5 radiobutton group a1.
selection-screen: end of block b2.
AT SELECTION-SCREEN ON S_VKORG
at selection-screen on s_vkorg.
select vkorg
into tvko-vkorg
from tvko
where vkorg in s_vkorg.
authorization check for sales org.
authority-check object 'V_VBRK_VKO'
id 'VKORG' field tvko-vkorg
id 'ACTVT' field '03'.
check sy-subrc ne 0.
message e002(zgen) with 'No authorization for sales org.'
tvko-vkorg.
endselect.
AT SELECTION-SCREEN ON S_BUKRS
at selection-screen on s_bukrs.
if pr_cust4 eq 'X' or
pr_cust5 eq 'X'.
select bukrs
into t001-bukrs
from t001
where bukrs in s_bukrs.
authorization check for plant and company code
authority-check object 'A_S_WERK'
id 'BUKRS' field t001-bukrs
id 'WERKS' dummy.
check sy-subrc ne 0.
message e002(zgen) with 'No authorization for this company code.'
t001-bukrs.
endselect.
endif.
AT SELECTION-SCREEN OUTPUT
at selection-screen output.
loop at screen .
if pr_cust1 eq 'X'.
if screen-name = 'S_VTWEG-LOW' or
screen-name = 'S_VTWEG-HIGH' or
screen-name = 'S_SPART-LOW' or
screen-name = 'S_SPART-HIGH' or
screen-name = 'S_TAXKD-LOW' or
screen-name = 'S_TAXKD-HIGH' or
screen-name = 'S_BUKRS-LOW' or
screen-name = 'S_BUKRS-HIGH' or
screen-name = 'S_ERDAT-LOW' or
screen-name = 'S_ERDAT-HIGH' or
screen-name = 'S_ALTKN-LOW' or
screen-name = 'S_ALTKN-HIGH' or
screen-name = 'S_VKBUR-LOW' or
screen-name = 'S_VKBUR-HIGH' or
screen-name = 'S_LOEVM1-LOW' or
screen-name = 'S_LOEVM1-HIGH' or
screen-name = 'S_LOEVM2-LOW' or
screen-name = 'S_LOEVM2-HIGH' or
screen-name = 'S_LOEVM3-LOW' or
screen-name = 'S_LOEVM3-HIGH'.
screen-input = 0.
endif.
elseif pr_cust2 eq 'X'.
if screen-name = 'S_BZIRK-LOW' or
screen-name = 'S_BZIRK-HIGH' or
screen-name = 'S_KDGRP-LOW' or
screen-name = 'S_KDGRP-HIGH' or
screen-name = 'S_LZONE-LOW' or
screen-name = 'S_LZONE-HIGH' or
screen-name = 'S_KTOKD-LOW' or
screen-name = 'S_KTOKD-HIGH' or
screen-name = 'S_ERDAT-LOW' or
screen-name = 'S_ERDAT-HIGH' or
screen-name = 'S_KTOKD-LOW' or
screen-name = 'S_KTOKD-HIGH' or
screen-name = 'S_ALTKN-LOW' or
screen-name = 'S_ALTKN-HIGH' or
screen-name = 'S_VKBUR-LOW' or
screen-name = 'S_VKBUR-HIGH' or
screen-name = 'S_LOEVM1-LOW' or
screen-name = 'S_LOEVM1-HIGH' or
screen-name = 'S_LOEVM2-LOW' or
screen-name = 'S_LOEVM2-HIGH' or
screen-name = 'S_LOEVM3-LOW' or
screen-name = 'S_LOEVM3-HIGH' or
screen-name = 'S_BUKRS-LOW' or
screen-name = 'S_BUKRS-HIGH' or
screen-name = 'S_VKGRP-LOW' or
screen-name = 'S_VKGRP-HIGH'.
screen-input = 0.
endif.
elseif pr_cust3 eq 'X'.
if screen-name = 'S_BZIRK-LOW' or
screen-name = 'S_BZIRK-HIGH' or
screen-name = 'S_KDGRP-LOW' or
screen-name = 'S_KDGRP-HIGH' or
screen-name = 'S_LZONE-LOW' or
screen-name = 'S_LZONE-HIGH' or
screen-name = 'S_ERDAT-LOW' or
screen-name = 'S_ERDAT-HIGH' or
screen-name = 'S_KTOKD-LOW' or
screen-name = 'S_KTOKD-HIGH' or
screen-name = 'S_SPART-LOW' or
screen-name = 'S_SPART-HIGH' or
screen-name = 'S_TAXKD-LOW' or
screen-name = 'S_TAXKD-HIGH' or
screen-name = 'S_REGIO-LOW' or
screen-name = 'S_REGIO-HIGH' or
screen-name = 'S_ALTKN-LOW' or
screen-name = 'S_ALTKN-HIGH' or
screen-name = 'S_VKBUR-LOW' or
screen-name = 'S_VKBUR-HIGH' or
screen-name = 'S_LOEVM1-LOW' or
screen-name = 'S_LOEVM1-HIGH' or
screen-name = 'S_LOEVM2-LOW' or
screen-name = 'S_LOEVM2-HIGH' or
screen-name = 'S_LOEVM3-LOW' or
screen-name = 'S_LOEVM3-HIGH' or
screen-name = 'S_BUKRS-LOW' or
screen-name = 'S_BUKRS-HIGH' or
screen-name = 'S_VKGRP-LOW' or
screen-name = 'S_VKGRP-HIGH' or
screen-name = 'S_VTWEG-LOW' or
screen-name = 'S_VTWEG-HIGH'.
screen-input = 0.
endif.
elseif pr_cust4 eq 'X'.
if screen-name = 'S_LZONE-LOW' or
screen-name = 'S_LZONE-HIGH' or
screen-name = 'S_TAXKD-LOW' or
screen-name = 'S_TAXKD-HIGH' or
screen-name = 'S_REGIO-LOW' or
screen-name = 'S_REGIO-HIGH' or
screen-name = 'S_ZUAWA-LOW' or
screen-name = 'S_ZUAWA-HIGH'.
screen-input = 0.
endif.
else.
if screen-name = 'S_LZONE-LOW' or
screen-name = 'S_LZONE-HIGH' or
screen-name = 'S_TAXKD-LOW' or
screen-name = 'S_TAXKD-HIGH'.
screen-input = 0.
endif.
endif.
modify screen.
endloop.
INITIALIZATION
initialization.
perform deactivate_program using sy-cprog.
START OF SELECTION
start-of-selection.
Customized function to get data from database table
perform get_data.
<<CR003-DEVK949538 start ins
perform get_internal_note_text tables gt_output_info.
<<CR003-DEVK949538 end ins
Create sort of ALV list
perform build_sort.
Send data to ALV list to display
if pr_cust1 eq 'X'.
gs_tabname = text-003.
gs_header = text-004.
perform write_alv_report tables gt_output_list
gt_sort_info.
elseif pr_cust2 eq 'X'.
gs_tabname = text-005.
gs_header = text-006.
perform write_alv_report tables gt_output_tax
gt_sort_info.
elseif pr_cust3 eq 'X'.
gs_tabname = text-007.
gs_header = text-008.
perform write_alv_report tables gt_output_hvl
gt_sort_info.
elseif pr_cust4 eq 'X'.
gs_tabname = text-009.
gs_header = text-010.
perform write_alv_report tables gt_output_crm
gt_sort_info.
else.
gs_tabname = text-011.
gs_header = text-012.
perform write_alv_report tables gt_output_info
gt_sort_info .
endif.
FORM EVENTTAB_FIELD
Fill Event tab, for ALV Grid Display
form eventtab_field using gs_events type slis_t_event.
data:
ls_event type slis_alv_event.
call function 'REUSE_ALV_EVENTS_GET'
exporting
i_list_type = 0
importing
et_events = gs_events.
read table gs_events with key name = slis_ev_top_of_page
into ls_event.
if sy-subrc = 0.
move gv_top_of_page to ls_event-form.
append ls_event to gs_events.
endif.
endform. " eventtab_field
FORM TOP_OF_PAGE
Write at Top of Page of ALV grid
form top_of_page.
call function 'REUSE_ALV_COMMENTARY_WRITE'
exporting
it_list_commentary = gt_list_top_of_page.
endform. "top_of_page
FORM COMMENT_BUILD
Write header of ALV grid
form comment_build using lt_top_of_page type slis_t_listheader
gs_header.
data:
lv_tdate(10),
lv_fdate(10),
ls_line type slis_listheader.
clear: ls_line.
ls_line-typ = 'H'.
ls_line-info = gs_header.
append ls_line to lt_top_of_page.
endform. "comment_build
FORM INIT_FIELDCAT
Fill Field Catalog for ALV Grid
form init_fieldcat using gs_tabname.
refresh: gt_fieldcat.
use this function to get the all fields in the structure.
call function 'REUSE_ALV_FIELDCATALOG_MERGE'
exporting
i_program_name = gv_repid
i_internal_tabname = gs_tabname
i_inclname = gv_repid
changing
ct_fieldcat = gt_fieldcat.
if sy-subrc eq 0.
clear mark for key field to set color of key column
gs_fieldcat-key = ''.
modify gt_fieldcat from gs_fieldcat transporting key
where fieldname ne space.
read table gt_fieldcat with key fieldname = 'FOUND_DAT'
into gs_fieldcat.
gs_fieldcat-seltext_l = text-013.
modify gt_fieldcat from gs_fieldcat
transporting seltext_l
where fieldname = 'FOUND_DAT'.
<<CR003-DEVK949538 start ins
read table gt_fieldcat with key fieldname = 'NOTE_TEXT'
into gs_fieldcat.
gs_fieldcat-seltext_l = text-014.
modify gt_fieldcat from gs_fieldcat
transporting seltext_l
where fieldname = 'NOTE_TEXT'.
<<CR003-DEVK949538 start ins
endif.
endform. "init_fieldcat
FORM INIT_LAYOUT
Layout initial
form init_layout using gs_layout type slis_layout_alv.
gs_layout-info_fieldname = 'LINECOLOR'.
gs_layout-colwidth_optimize = 'X'.
gs_layout-zebra = 'X'.
endform. " init_layout
FORM WRITE_ALV_REPORT
form write_alv_report tables gt_output
gt_sort_info.
ALV Grid display
clear: gv_repid,
gv_save.
gv_repid = sy-repid.
gs_variant-report = gv_repid.
gv_save = 'A'.
Build fieldcatalog
perform init_fieldcat using gs_tabname.
Build list events
perform eventtab_field using gs_event.
Show in ALV Grid form
perform init_layout using gs_layout.
Build comments
perform comment_build using gt_list_top_of_page[]
gs_header.
call function 'REUSE_ALV_GRID_DISPLAY'
exporting
i_buffer_active = ' '
i_callback_program = gv_repid
is_layout = gs_layout
i_save = gv_save
is_variant = gs_variant
it_events = gs_event[]
it_sort = gt_sort_info[]
it_fieldcat = gt_fieldcat[]
importing
e_exit_caused_by_caller = gv_exit_caused_by_caller
es_exit_caused_by_user = gs_exit_caused_by_user
tables
t_outtab = gt_output
exceptions
program_error = 1
others = 2.
endform. "write_alv_report
FORM GET_DATA
form get_data.
Get customer list
if pr_cust1 eq 'X'.
select knvv~vkorg
kna1~ktokd
kna1~kunnr
knvv~vtweg
kna1~name1
kna1~name3
kna1~name4
kna1~stras
kna1~cityc
kna1~regio
kna1~land1
knvv~kdgrp
knvv~bzirk
knvv~zterm
kna1~lzone
kna1~erdat
from kna1 join knvv
on kna1kunnr = knvvkunnr
into corresponding fields of table gt_output_list
where kna1~kunnr in s_kunnr
and knvv~vkorg in s_vkorg
and knvv~bzirk in s_bzirk
and kna1~regio in s_regio
and knvv~kdgrp in s_kdgrp
and kna1~lzone in s_lzone
and kna1~erdat in s_erdat
and kna1~ktokd in s_ktokd.
loop at gt_output_list into gs_output_list.
Get City decsription
perform get_city_description using gs_output_list-cityc
changing gs_output_list-bezei1.
Get Region description
select single bezei
from t005u
into gs_output_list-bezei2
where bland = gs_output_list-regio
and land1 = gs_output_list-land1"<<CR000-DEVK942345 ins
and spras = sy-langu.
Get customer group description
select single ktext
from t151t
into gs_output_list-ktext
where kdgrp = gs_output_list-kdgrp
and spras = sy-langu.
Get sales district description
select single bztxt
from t171t
into gs_output_list-bztxt
where bzirk = gs_output_list-bzirk
and spras = sy-langu.
Get zone decription
select single vtext
from tzont
into gs_output_list-vtext
where zone1 = gs_output_list-lzone
and spras = sy-langu.
modify gt_output_list from gs_output_list index sy-tabix
transporting bezei1
bezei2
ktext
bztxt
vtext.
clear gs_output_list.
endloop.
Get customer tax data
elseif pr_cust2 eq 'X'.
select kna1~kunnr
kna1~name1
kna1~name3
kna1~name4
kna1~ort01
kna1~stcd1
knvv~vkorg
knvv~spart
knvv~vtweg
knvi~taxkd
knvi~tatyp
from kna1 join knvv
on kna1kunnr = knvvkunnr
join knvi
on kna1kunnr = knvikunnr
into corresponding fields of table gt_output_tax
where kna1~kunnr in s_kunnr
and knvv~vkorg in s_vkorg
and knvv~vtweg in s_vtweg
and knvv~spart in s_spart
and kna1~regio in s_regio
and knvi~taxkd in s_taxkd.
Get customer tax description
loop at gt_output_tax into gs_output_tax.
select single vtext
from tskdt
into gs_output_tax-vtext
where tatyp = gs_output_tax-tatyp
and taxkd = gs_output_tax-taxkd
and spras = sy-langu.
if sy-subrc eq 0.
modify gt_output_tax from gs_output_tax index sy-tabix
transporting vtext.
clear gs_output_tax.
endif.
endloop.
Get customer HVL data
elseif pr_cust3 eq 'X'.
select kna1~kunnr
kna1~stceg
kna1~telfx
kna1~telf1
kna1~stras
kna1~ort02
kna1~cityc
kna1~regio
kna1~ort01
kna1~name2
kna1~name1
knvv~bzirk
knvv~spart
knvv~vtweg
knvv~vkorg
from kna1 join knvv
on kna1kunnr = knvvkunnr
into corresponding fields of table gt_output_hvl
where kna1~kunnr in s_kunnr
and knvv~vkorg in s_vkorg.
loop at gt_output_hvl into gs_output_hvl.
Get city description.
perform get_city_description using gs_output_hvl-cityc
changing gs_output_hvl-bezei.
if sy-subrc eq 0.
modify gt_output_hvl from gs_output_hvl index sy-tabix
transporting bezei.
clear gs_output_hvl.
endif.
endloop.
Get cust CRM data
elseif pr_cust4 eq 'X'.
select kna1~kunnr
knvv~versg "<<CR000-DEVK943142 del
knvv~vkorg
knvv~vtweg
knvv~bzirk
knvv~vkgrp
knvv~kdgrp
knvv~vkbur
kna1~name1
kna1~name2
kna1~ort01
kna1~pstlz
kna1~regio
kna1~stras
kna1~telf1
kna1~telfx
kna1~ort02
kna1~cityc
knvv~kvgr3
knb1~altkn
knb1~bukrs "<<CR000-DEVK943142 del
knvv~erdat
zcrm_bp_ext~found_dat
from kna1 join knvv
on kna1kunnr = knvvkunnr
join knb1
on knvvkunnr = knb1kunnr
join zcrm_bp_ext
on knb1kunnr = zcrm_bp_extkunnr
into corresponding fields of table gt_output_crm
where kna1~kunnr in s_kunnr
and knvv~vkorg in s_vkorg
and knvv~vtweg in s_vtweg
and knvv~spart in s_spart
and knvv~bzirk in s_bzirk
and knvv~kdgrp in s_kdgrp
and knvv~vkgrp in s_vkgrp
and knvv~vkbur in s_vkbur
and knvv~erdat in s_erdat
and kna1~ktokd in s_ktokd
and kna1~loevm in s_loevm1
and knb1~loevm in s_loevm2
and knvv~loevm in s_loevm3
and knb1~bukrs in s_bukrs
and knb1~altkn in s_altkn.
else.
Get customer information
<<CR001-DEVK944342 start del
select kna1~kunnr
knvv~vkorg
knvv~vtweg
kna1~stcd2
kna1~name1
kna1~name2
kna1~ort01
kna1~land1
kna1~pstlz
kna1~regio
kna1~stras
kna1~telf1
kna1~telfx
knvv~bzirk "<<CR001-DEVK944239 ins
knvv~vkbur "<<CR001-DEVK944239 ins
kna1~ort02
kna1~cityc
knvv~vkgrp
knvv~kvgr3
knvv~versg
kna1~kdkg2
kna1~kdkg1
knvv~kdgrp
knb1~altkn
knvv~erdat
kna1~loevm
knb1~loevm
knvv~loevm
<<CR001-DEVK944342 end del
<<CR001-DEVK944342 start ins
select kna1~kunnr
knvv~vkorg
knvv~vtweg
kna1~stcd2
kna1~name1
kna1~name2
kna1~name3 "<<CR002-DEVK944835 ins
kna1~stras
kna1~ort01
kna1~ort02
kna1~pstlz
kna1~regio
kna1~land1
kna1~cityc
kna1~telf1
kna1~telfx
knvv~bzirk
knvv~vkbur
knvv~kdgrp
knvv~vkgrp
knvv~kvgr3
knvv~versg
kna1~kdkg2
kna1~kdkg1
knb1~altkn
knvv~erdat
kna1~loevm
knb1~loevm
knvv~loevm
<<CR001-DEVK944342 end ins
from kna1 join knvv
on kna1kunnr = knvvkunnr
join knb1
on kna1kunnr = knb1kunnr
<<CR001-DEVK944252 start del
into corresponding fields of table gt_output_info
<<CR001-DEVK944252 end del
<<CR003-DEVK949538 start del
into table gt_output_info "<<CR001-DEVK944342 ins
<<CR003-DEVK949538 end del
<<CR003-DEVK949538 start ins
into corresponding fields of table gt_output_info
<<CR003-DEVK949538 end ins
where kna1~kunnr in s_kunnr
and knvv~vkorg in s_vkorg
and knvv~vtweg in s_vtweg
and knvv~spart in s_spart
and knvv~bzirk in s_bzirk
and knvv~kdgrp in s_kdgrp
and knvv~vkgrp in s_vkgrp
and knvv~vkbur in s_vkbur
and knvv~erdat in s_erdat
and kna1~ktokd in s_ktokd
and kna1~regio in s_regio
<<CR001-DEVK944252 start del
and kna1~loevm in s_loevm1
and knb1~loevm in s_loevm2
and knvv~loevm in s_loevm3
<<CR001-DEVK944252 end del
<<CR001-DEVK944252 start ins
and ( kna1~loevm in s_loevm1
or knb1~loevm in s_loevm2
or knvv~loevm in s_loevm3 )
<<CR001-DEVK944252 end ins
and knb1~zuawa in s_zuawa
and knb1~bukrs in s_bukrs
and knb1~altkn in s_altkn.
<<CR003-DEVK949538 start ins
loop at gt_output_info into gs_output_info.
select single adrnr
into kna1-adrnr
from kna1
where kunnr = gs_output_info-kunnr.
check sy-subrc eq 0.
select single smtp_addr
into adr6-smtp_addr
from adr6
where addrnumber = kna1-adrnr.
check sy-subrc eq 0.
gs_output_info-smtp_addr = adr6-smtp_addr.
modify gt_output_info from gs_output_info.
endloop.
<<CR003-DEVK949538 end ins
endif.
<<CR003-DEVK949538 start ins
loop at gt_output_info into gs_output_info.
lv_store = gs_output_info-loevm1.
endloop.
<<CR003-DEVK949538 end ins
endform.
FORM BUILD_SORT
form build_sort.
if pr_cust1 eq 'X' or
pr_cust2 eq 'X'.
clear gs_sort_info.
gs_sort_info-fieldname = 'VKORG'.
gs_sort_info-spos = 1.
gs_sort_info-up = 'X'.
append gs_sort_info to gt_sort_info.
endif.
clear gs_sort_info.
gs_sort_info-fieldname = 'KUNNR'.
gs_sorhi shivaji!
thx for the reply.
can u chk whether there is any problem with the queries or not.
regards
sachin -
How to close Purchase Order and mark to deletion flag.??
Hi,
We need to close all Open POs(For archiving, some old data) through a report.
Considering .....
1. PO-GR-IR
and 2. STO-Outboundelivery-PGI-IBD-PGR
Checked few threads, though useful but still more information required.
-> Preprocessing program for archiving standard object MM_EKKO 'RM06EV47' is helpful.
-> Example we have four POs p1,p2,p3 and p4.
P1,p2 has deletion flag as 'L' so will be filtered out with
SELECT ebeln FROM ekko INTO TABLE lt_sekko
WHERE ebeln IN er_ebeln
AND ekorg IN er_ekorg
AND bstyp IN er_bstyp
AND bedat IN er_bedat
AND bsart IN er_bsart
AND ekgrp IN er_ekgrp
AND loekz <> 'L'
ORDER BY EBELN.
For P3 has GR .
P4 has to be marked for deletion flag.
Regards
Mohinder SinghHi Thanks for the reply. I checked with that bapi too. I used some part of standard code and then manipulated. Will shorty paste the code on to SDN as its general one and may be used by others.It still under testing.
Edited by: Mohinder Singh Chauhan on Feb 20, 2009 4:07 AM -
Hi Gurus,
How to delete multiple customers (its not specified from 1 to 10 like, its like customer no: 2, 4,8,10,13,17,89,99,110 like)in one go, In XD06 we can enter only one customer number. I tried T. Code: MASS also, but could not find the solution.
please help me ASAP.
Thanks in advance.
Regards,
Vamsi P.Hi Vamsi,
The CATT is primarly a testing tool and can also be used for mass upload of data. The CATT works as if an user is updating the values one by one.
The procedure to upload the data using CATT is done in four steps
a) Creating the CATT Test Case & Recording the sample data input
b) Download of source data file
c) Modify the source data file
d) Upload the data from source file
I have explained the procedure step by step and do note the following explanation is specific to your problem
Creation of CATT Test Case:
1)Go to TCODE [SCAT]
2)Create a Test Case by entering a name and clicking the TCD button in application tool bar
3)Enter the TCODE you want to execute [XD06]
4)Enter the customer number, company code and sales area data.
5) Select the required deletion flag and/or deletion blocks
6)Click on Save
7)End Recording
8)Click on Save and save as local object
9)Press Exit button and save changes while exiting.
Now we have created a recording for deleting a customer with a sample data.
Ensure while recording the transaction you do not get an warning or error messages else you might have to redo the recordng.
Download of source data file
1)In the [SCAT] screen select your test case and click on change
2)Click on choose button in the application tool bar
3)Click on field list in the application tool bar
4)Double click on the customer number and change the parameter name as &CUSTNO. Any field starting with & would be treated as an input field from a file. If you have to execute the customer deletion across multiple Sales Area you need to do the same for the Sales Area fields too
5)Remove the default value
6)Press Exit and save the test case
7)In the SCAT screen select your test case and in the menu bar Goto -> Variant -> Export Default
8)You would get a text file.
Now you have downloaded a source data file
Modify the source data file
1)Open the text file in Excel and load the remaining data
2)Remove the fourth line which starts with three asterisks
3)Below the customer number heading (&CUSTNO) load all the customers for which the deletion flag has to be set
4)Save the file as Text Delimiter
Now the data to be uploaded as been prepared.
Upload the data from source file
1)Go to [SCAT], select the test case and press F8
2)Select the processing mode as background
3)Chose variant as external from file
4)Click on choose and select the path of the text file
5)Press F8 for the remaing records to be updated
After execution press Enter to see the log. Any line highlighted in Red is an Error for which you need to do further analysis to find out the error reason.
Hope this helps.
Regards
Nadarajah Pratheb -
Deletion flags for equipment BOM
Hi,
In equipment BOM header , there are 2 fields for deletion flag :
-one is set manually (the one on the right)
-the other set by the system (the one on the left).
Can someone explain to me how deletion flag indicator (on the left) work?
Thanks,
P.Hi,
To explain this i must say first there is a difference in the Deletion Flag (Right in Header) and Deletion Indicator(Left in Header).
In SAP term The deletion Indicator shows the item which has already been Deleted from the System and Deletion flag shows that the record has been flagged for deletion and will hence be Archieve (when, depends on the Archieving strategy followed in the company).
To explain the affect these will have is the Deletion Indicator will not allow you to use the and will show the error as the object has been deleted and is not in the system.
Deletion flag for BOMs
Indicator: this BOM will be archived during the next archiving run and, if necessary, deleted from the data base.
Where as the Deletion Flag will show that the object is ready to be archieved and is set to be deleted.
Deletion Indicator
Indicator showing that the BOM header or the BOM item has been deleted with reference to the change number.
Now there is another difference in the way we can amke the objects active from deletion flag anf the deletion indicator.
For Deletion flag you have to go to change mode and just remove or untick the deletion flag.
For Deletion indicator you have to go to Archieve table and pull the object back in to SAP system and it will then show only the deletion flag, which can be removed by the way explained above.
I hope this was helpful, if yes then please award points.
Regards
Anoop -
In what situation we can use a deletion Flag. Once we set a deletion Flag for the WBS element, what are the impacts, i mean what can be done and what cannot be for that particular project.
HI
The Deletion flag status designates work breakdown structures or WBS elements that have been flagged for deletion. This means that the objects are deleted logically, but not physically
for more clarity please refer to the sap HELP on System statuses on workbreak down structures.
Regards.
Vara prasad -
Impact deletion flag set process order
If i have "Set deletion flag for old process order" after the same any impact in Finance or production side.
ChintanHi,
You should set the deletion flag only for orders:
which are delivered or technically completed
for which variances have been calculated
for which you do not anticipate any further follow-up costs
If follow-up costs must be charged to the object, you can remove the deletion flag (DLFL). Deletion indicators (DLT), however, cannot be withdrawn.
As long as the accounting period is not yet closed, data (such as from results analysis) can still be transferred to Financial Accounting (FI). The FI period should be closed before you can set the deletion indicator (DLT), since no more costs can be settled to FI after that point.
When the orders are deleted, the quantity information on the routing operations is also deleted.
Regards,
Antje -
Dear friends,
once maintenance order has been released,I am unable to put deletation flag for that order.
is there any option to put deletion flag after releasing maint order other than locking
your response is highly appriciated.
Regards,
K.SunilHi Sunil,
It can allow you to delet, might be an Authorization Issue
for your Maintenence Order Creation Role, Just check for the Object: I_VORG_ORD
Field: BETRVORG
Field Value: LVMS Mark for deletion
LVMZ Remove deletion flag
Hope it helps you.
Regards,
Yawar Khan -
Mass Deletion of Rental Objects
Hi,
I have to delete all Rental Objects approx. 100+. Is there any way I can perform that quickly?
Thanks
AtifHi,
You can see two text boxes in the left pane of RE80 Transcation, In the first box enter "My Objects" Second text box enter "User ID of the Creator". Then system shows list of all rental objects, from which you can select and delete as explained above. These two boxes are visible only if you are using latest GUI.
Note: In the customization of RE-FX. SPRO-> Tools->Archiving->Deletion of Real estate objects without Archiving check box should be flagged to delete objects.
Thanks,
B. -
Hi Experts,
I have replaced an equipment with new one and scrapped the old one.Can you tell me what system status i maintain
should i put in available status with user status scrapped or put the deletion flag and user status scrapped.
Also if i put deletion flag to equipment is the same will affect somewhere like settlement of order etc.
AR
Edited by: Amit Rana on Feb 22, 2010 5:05 PMAR,
You may want to do both. Set the User status to "SCRAP" and also set the "Deletion flag" On the equipment master for information / historical purpose. There shouldn't be any effect on the settlement process of the order as such.
Whenever you use the same piece of equipment again on the order a warning/ error message may come up indicating to check the status of the the object.
Regards
Narasimhan -
How to set deletion flag in Production order item level
Hi Friends,
I have a requirement like...
Suppose production order conatians 100 items. now i want to set deletion flag for 20 items only.
In Co02 t.code deletion check box is disable mode.
There are nearly 100 production orders .i have to write the program....
Is there any BAPI or other way to meet this requirement.
Can you please help me..Also, You might want to have a look at the BAPIs like BAPI_PRODORD_SET_DELETION_FLAG which are used to set the deletion indicator but it appears to me the deletion flag can only be set at the header level using these BAPIs.
Please have a look at SAP business object BUS2005 methods from transaction SW01 for more Production Order related BAPIs.
One more thing ... since you mentioned that in CO02 the deletion indicator is greyed out, then it might mean you are missing the authorizations to set the deletion flag. Please consult with your Authorization (BASIS) administrator. As a hint, the authorization object here is C_AFKO_AWK.
Cheers,
Aditya -
What happen with deletion flag indicator??
Dear Experts,
In my organization my previous consultant created maintenance plan for 3 years, in that some maintenance plans having deletion flag and already maintenance plans are scheduled for 3 years. May I know what will happen to this maintenance plan ??
will maintenance orders generated as per the schedule irrespective of deletion flag?? or orders can't generated because of deletion flag.
Can anybody explain in detail.
Regards,
Sunil BoyaDeletion flag is pre-requisite for archiving the object. If deletion flag is set for maintenance plans, it will not further generate orders during scheduling.
Though, the orders created before deletion flag activation will be available for your execution. -
Hi,
Even when we have set a Deletion flag for a Functional Location, it allows us to install Equipment in it. Our
requirement is that the System should disallow it. How can we restrict equipment installation?
Regards
AbhiHi PeteA,
I have already tried the first option.
Can you explain the procedure ,how to restrict equipment installation by using user status. I tried that but could not find any business transaction releated to equipment installation for Object--FL in Status Profile creation.
Abhi -
Deleting all the materials with deletion flag
Hi all.
How is it posiible to delete all the materials in the system that have a deletion flag using tcode MM71?
Regards, Nikolai.MM71 is an archiving transaction. You have to do customizing for archiving.
Create logical and physical file names and paths. Define the size of an archive. and define what you want execute in what sequence.
Create a variant with your selection.
But if you want delete material masters that were already in use, then be prepared that your success may be very limited. As you would have to archive all dependend data first.
Materials are the very last step in an archiving cycle.
Click the network button right of the executing button to see what objects you have to archive first, to be able to finally archive a material -
Change pointer for functional location- deletion flag & activation status
Hello,
Im trying to use change pointer for functional location outbound interface. I did all required settings in BD52. The problem is with deletion flag and acive/deactive status.
I found that those two are stored in:
table field
TAPL LOEKZ
TAPL PARKZ
The problem I have is that I cannot find the object for those table, and due to that it cannot be customized in BD52.
Could You please advise which object class should I use or alternatively which other table/field and object should I type in to activate change poiters for deletion flag and active/ not active status?
For object IFLO, and its table (IFLOT, IFLOTX, ILOA)- there is no field for del flag and active status.
Thanks in advance.Hi, standard didnt let us fulfilling this requirement. What we did- we extended table IFLOT with additional field for the status and used an user exit when saving FL, to take the value (status) from table JEST/TJ02T and copy the value to the newly created field. Then BD52, iflo, iflot, and the new field and it worked. Of course the function module for the message type (BD60) had to be changed to add this status value in additional segment/field for the idoc. Hope this will help You, as there is a lot of technical background behind it, and this is only functional overview.
rgds.
Maybe you are looking for
-
Is there a way to view videos on the web, with my Pre?
smkranz I am a volunteer, and not an HP employee. Palm OS ∙ webOS ∙ Android
-
We have Lync 2013, Exchange 2010 and several AD servers in mixed mode 2003/2008. All user are unable to see their own profile photo either in the main Lync window, in the settings or in a chat although other user can see that their photo is there and
-
TS1846 external video all frames
When I'm editing my video in Final Cut Pro 7, the external video Video freezes, I only hear the audio. To try to solve, I click on View> External Video> Refresh A /V Devices and nothing changes. Canvas in the program, the video runs normally.
-
App says "Evaluatio​n Copy" but ActiveX controls are not evaluation copies.
App has been running for 3+ years in a Win95 machine. Just moved to Win98 machine and now "Evaluation Copy" appears in app. I have copied the two OCX files from the Win95 machine and registered them on the new machine. I purchased ComponentWorks 3 ye
-
For the second time in as many months I have had to roll back to version 3.6.19 as the new firefox (versions 4 or 5) was unable to use 'no script', 'forecastfox' or 'download status bar'. I hope mozilla will continue to support v3.6.19 until my issue