Replace SM30 with Transaction
Hi,
for authorization reasons I would like to replace SM30 maintainance with a custom transaction. Is there any easy way to achieve this?
Thanks.
/Elvez
Hi,
Create a transaction for the table using the SM30.
How to create the transaction..
GOTO SE93
Give the transaction name..
Press create button
Enter the description..
Select the "Transaction with parameters (parameter transaction)"
Press enter.
In the transaction field give SM30..
Press enter..
Check the checkbox "Skip initial screen"
IN the bottom of the screen..
NAME OF SCREEN FIELD VALUE
VIEWNAME "Give your ztable name"
UPDATE X
Save the transaction..
Thanks,
Naren
Similar Messages
-
Table Maintaince with Transaction SM30 with selection Screen
Hi Friends,
I have a requirement for maintance of Z table "ABC" and it need to be maintanied.
This Ztable should have Ztransaction Code connecting to transaction SM30.
Also this should have a selection screen with 3 fields to filter the data and only the selected data needs to be used to enter the values in SM30 with the Maintain mode.
I have created the table and t code and below is the report .
REPORT zrktest.
******************Declaration*************************
***Tables Declaration*******
TABLES : zkexxirac_calend.
DATA : gt_calend TYPE STANDARD TABLE OF zkexxirac_calend,
wa_calend TYPE zkexxirac_calend.
***SELECTION SCREEN***
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-100.
SELECT-OPTIONS : s_burks FOR zkexxirac_calend-bukrs ,
s_zbukrs FOR zkexxirac_calend-zzbukrs,
s_partn FOR zkexxirac_calend-partner_number.
SELECTION-SCREEN END OF BLOCK b1.
******************Start - Of - Selection*************************
START-OF-SELECTION.
******************Main Processing*************************
*& Form get_data
* Get the Data from the table after satisfying
* the condition form Selection Screen
* --> p1 text
* <-- p2 text
******Select the data from the table***
SELECT *
FROM zkexxirac_calend
INTO CORRESPONDING FIELDS OF TABLE gt_calend
WHERE bukrs EQ s_burks
AND zzbukrs EQ s_zbukrs
AND partner_number EQ s_partn.
CALL TRANSACTION 'ZITXXIRACCALEND' AND SKIP FIRST SCREEN.
but when i execute the report it goes to the 1st screen of SM30 and gives the error message to selecting the option of No restriction , enter condition .. etc .
I have already ticked the Check box to skip initial Screen in the SM93, while creating the Transaction Code.
Let me know what chnages needs to be done and what code should i write.Rabiya,
You actually do not need to do any data selection beforehand to accomplish this. Just convert the select-options to a different format and then call FM 'VIEW_MAINTENANCE_CALL'.instead of CALL TRANSACTION. The process is described here:
Add a Selection Screen to a Table Maintenance Dialog
Best,
Eric -
Replace gail with extra/gtk2? [Y/n]
Verifying before I update
(pacman -Syu)
What is this?:
Replace gail with extra/gtk2? [Y/n]Here it is:
[gour@gaura-nitai gour] yaourt -Syu
Password:
:: Synchronizing package databases...
gaur is up to date
core is up to date
extra is up to date
community is up to date
:: Replace gail with extra/gtk2? [Y/n] y
:: Starting full system upgrade...
:: Replace gail with extra/gtk2? [Y/n] y
warning: bogofilter: local (1.1.7-3) is newer than gaur (1.1.6-1)
warning: bzrtools: local (1.7.0-1) is newer than community (0.91.0-1)
warning: cinelerra-cv: local (1061-3) is newer than gaur (1056-2)
warning: emacs-w3m-cvs: local (20080425-1) is newer than gaur (20080307-1)
warning: glade: local (3.6-1) is newer than extra (3.5.2-1)
warning: kiwi: local (1.9.23-1) is newer than community (1.9.22-1)
warning: postgresql: ignoring package upgrade (8.3.4-1 => 8.3.4-3)
warning: xmobar-darcs: local (20080616-1) is newer than gaur (20080416-1)
resolving dependencies...
looking for inter-conflicts...
Remove (1): gail-1.22.3-1
Total Removed Size: 1,63 MB
Targets (69): glib2-2.18.2-1 atk-1.24.0-1 libpng-1.2.32-1 libcups-1.3.9-1 xcb-util-0.3.0-2 cairo-1.8.0-1
pango-1.22.0-1 gtk2-2.14.4-1 cairomm-1.6.4-1 libetpan-0.57-1 claws-mail-3.6.1-1
claws-mail-extra-plugins-3.6.1-1 e2fsprogs-1.41.2-1 popt-1.14-1 cryptsetup-1.0.6-2
cups-1.3.9-1 dhcpcd-4.0.2-1 dnsutils-9.5.0.P2-1 postgresql-libs-8.3.4-2 dovecot-1.1.4-1
fam-2.7.0-11 gegl-0.0.20-1 libglade-2.6.3-1 pycairo-1.6.4-1 pygobject-2.15.4-1 pygtk-2.13.0-1
gimp-devel-2.6.1-1 gimp-help-2-2.4.2-1 glibmm-2.18.0-1 gmp-4.2.4-1 gnome-doc-utils-0.14.0-1
gstreamer0.10-0.10.21-1 pangomm-2.14.0-1 gtkmm-2.14.1-1 imagemagick-6.4.4.9-1
kernel26-2.6.27.1-1 klibc-udev-130-1 lib32-libpng-1.2.32-1 libdvdcss-1.2.10-1
libisofs-0.6.10-1 libjpeg-6b-5.1 liboil-0.3.15-1 libx11-1.1.5-2 mpfr-2.3.2-2 netcfg-2.1.2-1
ntp-4.2.4p5-1 nvidia-173xx-173.14.12-2 orbit2-2.14.16-1 pm-utils-1.2.2.1-1 pygtk-docs-2.13.0-1
python-gdata-1.2.2-1 qt-4.4.3-1 qscintilla-2.3-1 sdl-1.2.13-2 shadow-4.1.2.1-2 sip-4.7.7-2
subversion-1.5.3-1 tcl-8.5.5-1 xvidcore-1.1.3-2 lzo2-2.02-3 transcode-1.0.6-1 udev-130-1
libshout-2.2.2-2 vlc-0.9.4-2 inputproto-1.4.4-1 xextproto-7.0.3-2 xpdf-3.02_pl2-2
xtrans-1.2.2-1 youtube-dl-2008.10.16-1
Total Download Size: 0,00 MB
Total Installed Size: 672,14 MB
Proceed with installation? [Y/n] y
checking package integrity...
(69/69) checking for file conflicts [#######################################################] 100%
error: could not prepare transaction
error: failed to commit transaction (conflicting files)
/usr/share/gtk-doc/html/pygtk/atk-class-reference.html exists in both 'pygtk' and 'pygtk-docs'
[snip]
pygtk: /usr/share/gtk-doc/html/pygtk/unixprint-functions.html exists in filesystem
Errors occurred, no packages were upgraded.
missing dependency for libgnomecanvas : gail>=1.22.0
Sincerely,
Gour -
Replacing bash with dash or zsh as default shell
Now that initscripts are no longer default init system for Arch, it should be possible (if initscripts removed from system) to remove bash and replace it with other shell, right? On my system I have this:
:: autoconf: requires bash
:: automake: requires bash
:: ca-certificates: requires bash
:: cpupower: requires bash
:: dcron: requires bash
:: enca: requires bash
:: fftw: requires bash
:: filesystem: requires bash
:: gpm: requires bash
:: gsl: requires bash
:: gzip: requires bash
:: iptables: requires bash
:: libksba: requires bash
:: m4: requires bash
:: man-db: requires bash
:: mkinitcpio: requires bash
:: p7zip-light: requires bash
:: pacman: requires bash
:: pkgstats: requires bash
:: pm-utils: requires bash
:: shadow: requires bash
:: smartmontools: requires bash
:: systemd: requires bash
:: unzip: requires bash
(Note: I've removed packets requiring sh.)
Here's a complete list of packets depending on bash (110):
abcde
abs
acpid
antiword
arch-backup
archboot
arch-install-scripts
arch-wiki-lite
audio-convert
aurphan
autoconf
autojump
automake
bashburn
bash-completion
bashdb
bashrun
bwidget
ca-certificates
cl
cpupower
cronie
dcron
dhclient
dkms
drbd
dvdrtools
ecl
enca
fftw
filesystem
foomatic-db-engine
fssos-nsvs
geos
gimp-gap
gpm
groovy
gsl
gzip
hdparm (optional)
ifplugd
incron
initscripts
inputattach
iptables
jython
kim4
laptop-mode-tools
libksba
lksctp-tools
lrzip
lvm2
lvm2 (testing)
lxc
m4
man-db
mathomatic (optional)
mfs-chunkserver
mfs-client
minicom
mkinitcpio
multipath-tools
nanoblogger
noip
ode
oidentd
opencv-samples
openlierox (optional)
openslp
ozerocdoff
p7zip
pacman
pacmatic
pax-utils
pkgstats
pkgtools
pmount
pm-utils
polipo
ponysay
preload
quilt
ratpoison
rblcheck
redis
rkhunter
rpcbind
rpmextract
sane
sdcc
shadow
smartmontools
source-highlight
speedtouch
systemd
tablelist
taglib-rcc
ted
tor
translate-toolkit
txt2man
unzip
uptimed
vde2
vnstat
wdm
wings3d
wireshark-cli
xbase
xdm-archlinux
Do these packages (except initscripts) really need bash? Debian uses dash as its default shell, I think Arch at least need to offer a possibility for using shells other than bash as default.
Any thoughts?Demon wrote:Why not? I'm just exploring the possibilities.
zsh is not completely backwards-compatible with bash (not that bash is "backwards" in any real way). There's always a chance that, without the bash interpreter installed, some utilities written in bash won't work properly. Also, sh in Arch is distributed in the bash package, so uninstalling it will pull those packages with it.
Demon wrote:But then packages not needing bash (autoconf, automake, gzip, unzip) should list only sh as dependency, not bash. Right?
Some of them already do:
Arch Linux :: GLaDOS » pacman -Rp bash
error: failed to prepare transaction (could not satisfy dependencies)
:: autoconf: requires bash
:: automake: requires bash
:: bison: requires sh
:: ca-certificates: requires bash
:: cairo: requires sh
:: cpupower: requires bash
:: cronie: requires bash
:: db: requires sh
:: dhcpcd: requires sh
:: dictd: requires sh
:: diffutils: requires sh
:: dmenu: requires sh
:: e2fsprogs: requires sh
:: fakeroot: requires sh
:: filesystem: requires bash
:: findutils: requires sh
:: flex: requires sh
:: freetype2: requires sh
:: gawk: requires sh
:: gdbm: requires sh
:: gettext: requires sh
:: gmp: requires sh
:: gpm: requires bash
:: grep: requires sh
:: gzip: requires bash
:: icu: requires sh
:: iptables: requires bash
:: keyutils: requires sh
:: laptop-mode-tools: requires bash
:: libgpg-error: requires sh
:: libksba: requires bash
:: libpng: requires sh
:: libtool: requires sh
:: libusb-compat: requires sh
:: m4: requires bash
:: make: requires sh
:: man-db: requires bash
:: mkinitcpio: requires bash
:: nss: requires sh
:: pacman: requires bash
:: perl: requires sh
:: sane: requires bash
:: sed: requires sh
:: shadow: requires bash
:: systemd: requires bash
:: taglib: requires sh
:: tar: requires sh
:: unzip: requires bash
:: which: requires sh
:: xorg-mkfontdir: requires sh
:: xz: requires sh -
[SOLVED] Replacing mariadb with aur/mysql
Hi,
I use KDE and therefore have akonadi as dependency of mariadb.
I need the original mysql community for development.
How do I replace mariadb with aur/mysql?
Thanks for help
Silberling
Last edited by Silberling (2015-01-16 09:30:59)@fsckd Thanks for moving my post to the right location
==> Finished making: mysql 5.6.22-1 (Thu Jan 15 20:24:17 CET 2015)
==> Continue installing mysql ? [Y/n]
==> [v]iew package contents [c]heck package with namcap
==> ---------------------------------------------------
==>
loading packages...
resolving dependencies...
looking for conflicting packages...
:: libmysqlclient and libmariadbclient are in conflict. Remove libmariadbclient? [y/N]
error: unresolvable package conflicts detected
error: failed to prepare transaction (conflicting dependencies)
:: libmysqlclient and libmariadbclient are in conflict
==> WARNING: Your packages are saved in /tmp/yaourt-tmp-kai
These are the last lines. The conflict is:
root@luna /home/kai> pacman -R mariadb
checking dependencies...
error: failed to prepare transaction (could not satisfy dependencies)
:: akonadi: requires mariadb
root@luna /home/kai> pacman -R libmariadbclient
checking dependencies...
error: failed to prepare transaction (could not satisfy dependencies)
:: gdal: requires libmariadbclient
:: mariadb-clients: requires libmariadbclient
:: mysql-connector-c++: requires libmysqlclient
:: mysql-python: requires libmariadbclient
:: mysql-workbench: requires libmariadbclient
The dependencies meet at mariadb, which I can not remove because of akonadi.
Is it possible to enforce removal and the akonadi package detects aur/mysql as alternative?
The connector and workbench might just need recompilation
Last edited by Silberling (2015-01-15 19:46:40) -
My 5th gen ipod died and apple replaced it with a new one. I synced it up to the itunes that I already have on my computer but an error message keeps coming up telling me that its not authorized on this computer. What do I do?
About iTunes Store authorization and deauthorization
iPod: Troubleshooting songs and audiobooks that won't play
iPod does not play content purchased from the iTunes Store -
I not so recently changed my email adress I associated with my Apple ID and my iCloud ID. My old email still shows up for iCloud, and won't let me change it to my new email. When I try to delete it and replace it with the proper email, it wants my password, which it won't accept because it's an invalid username.
I had this same issue and got it resolved very simply when I contacted Apple SUpport
Go to https://appleid.apple.com/cgi-bin/WebObjects/MyAppleId.woa/ and sign into your infomation
> Go to Manage apple id and primary email address
> Change it to the old apple id that your device is asking for
> Save changes
> Go to Settings > iCloud and sign out of the infomation
> Go back to https://appleid.apple.com/cgi-bin/WebObjects/MyAppleId.woa/
> Change it back to the correct apple id
> Go to the email address adn reverify the apple id
> Sign back into iCloud on your device
> Smile
Article to back up my statement http://support.apple.com/kb/TS5223 -
After soak test update, I get error messages repeatedly. The majority are "unfortunately, messaging has stopped", but you can replace messaging with "android os", or any other process, as it happens with more than just messaging. I have had numerous people call and ask why I didn't reply to their texts...and I look, but have not received any new texts. YES, I have restarted phone. I have cleared data as well as cache on all apps. I have downloaded the vzw messaging app, which seems silly, since it happens with several different processes and apps, but all to no avail. I am missing texts from my employer, from my family. This did happen, but rarely, before this "soak test". It is now Kitkat version 19.6.3.obake_verizon.en.US. THIS is when I started having problems...like 50 times a day kind of problems! I have seen hundreds of posts all over the internet over the past 3 days. Does no one know how to fix this??? Shouldn't there be a way to revert phone to a pre-update state? and no, hard reset did NOT work!!!! I have been with verizon for well over 15 years, but I have not upgraded my lines and will not in July either. This is ridiculous. It's not like my games aren't working, it is my messaging and "android os"...my lifeline at work!
kristinaf333,
Oh no, I am sorry to hear your messages are not working since the software update. I greatlly appreciate doing all that troubleshooting to try and get the messaging application back in business. I know how much I rely on my messages so I can understand the urgency to get this resolved. Have you had a resolution ticket opened since you started experiencing issues with your messages? Does this happen with all contacts or just some? Please provide additional information to ensure we get to the bottom of this for you.
KarenC_VZW
Follow us on Twitter @VZWSupport -
I have a MacBook Pro 15.4" 2.53GHz Core 2 Duo (A1286) - Mid 2009 MC118LL/A and I think the MATSHITA DVD-R UJ-868 is going out. Should I replace it with the exact same drive or is there a better one that is compatible?
I went to my local Apple store last weekend with a similar issue on my 2007 C2D MBP and they quoted me a price of around £60 (excluding VAT) to replace the optical drive. That's about the same price as the external optical drive a bought for my RMBP.
Alternatively you could just buy a 3rd party external drive if you want to save cash but note that the external Apple superdrive is not compatible with MacBooks with built in optical drives. -
I have a new computer and have installed iTunes on it.
Now I want to sync my iphone but the new itunes on the new computer wants to remove everything on my niphone and replace it with what's on the newly installed itunes data but it does not have my data.
How can I sync the new itunes with my iphone and not have my phone data wiped out?
Thanks,
hscllchscllc wrote:
How can I sync the new itunes with my iphone and not have my phone data wiped out?
There is no way to stop iTunes from doing exactly what it is designed to do.
The iPhone is designed to sync with one and only one computer.
If you have moved/copied your iTunes library from your old computer to your new one, then iTunes wiping your device is no problem. You would simply sync and iTunes will put all the content back. -
Required replace BSEG with BSAK BSIK BSIS BSAS for report performance
Hi Experts
i m optimizing a report in which data is extracting from BSEG , 5 time so i reduses the performance of report
so i want replace BSEG with BSAK BSIK BSIS BSAS for the same data what I am getting now . this is report of Purchase of item. code is here.
REPORT zmm_pur_reg_kanhe LINE-SIZE 1023.
*& Des :Purchase Tax Register Report for KANHE
*& Created on :12-07-07
*& Suggested by:Paresh Saini(MM)
*& Changes By: Lailu Philip
*& Changed On: 24.09.2007
*& Changes: New columns for G/L Code Description,VAT Amt,VAT Perc,CST Perc
*& ,SHCESS Amounts,WCT G/L Acc., WCT Amt,Tax Code
*& for Purchase Order,WCT tax code & Percentage.
*& Request No: S6DK921577
Data Declaration
*& changes: by Vincy on 12.01.2007
*& changes: display purchase order with vendor type zpsr(get_zpsr)
*& Request No: S6DK930821
TABLES:ekbe, lfa1, faglflexa.",j_1iexcdtl,lfa1,bkpf,bseg.
TYPE-POOLS: slis. "ALV Declarations
DATA: fieldcatalog TYPE slis_t_fieldcat_alv WITH HEADER LINE,
gd_layout TYPE slis_layout_alv,
gd_repid LIKE sy-repid.
DATA: it_sortcat TYPE slis_sortinfo_alv OCCURS 1,
col_pos LIKE fieldcatalog-col_pos .
TYPES :BEGIN OF wa1_ekbe,
belnr TYPE ekbe-belnr,
budat TYPE ekbe-budat,
menge TYPE ekbe-menge,
matnr TYPE ekbe-matnr,
ebelp TYPE j_1iexcdtl-ritem1,
ebeln TYPE ekbe-ebeln,
gjahr TYPE ekbe-gjahr,
lfbnr TYPE ekbe-lfbnr,
lfpos TYPE ekbe-lfpos,
bldat TYPE ekbe-bldat,
REEWR TYPE REEWR,
END OF wa1_ekbe.
TYPES :BEGIN OF wa2_ekbe,
belnr TYPE ekbe-belnr,
budat TYPE ekbe-budat,
menge TYPE ekbe-menge,
ebelp TYPE ekbe-ebelp,
ebeln TYPE ekbe-ebeln,
gjahr TYPE ekbe-gjahr,
lfbnr TYPE ekbe-lfbnr,
lfpos TYPE ekbe-lfpos,
bldat TYPE ekbe-bldat,
REEWR TYPE REEWR,
awkey(20) TYPE c,
MATNR TYPE MATNR,
MWSKZ TYPE EKBE-MWSKZ,
END OF wa2_ekbe.
TYPES :BEGIN OF wa1_j_1iexcdtl,
exnum TYPE j_1iexcdtl-exnum,
exdat TYPE j_1iexcdtl-exdat,
lifnr TYPE j_1iexcdtl-lifnr,
matnr TYPE j_1iexcdtl-matnr ,
maktx TYPE j_1iexcdtl-maktx ,
capind TYPE j_1iexcdtl-capind,
exbas TYPE j_1iexcdtl-exbas,
exbed TYPE j_1iexcdtl-exbed,
ecs TYPE j_1iexcdtl-ecs,
werks TYPE j_1iexcdtl-werks,
ritem1 TYPE j_1iexcdtl-ritem1,
rdoc1 TYPE j_1iexcdtl-rdoc1,
docyr TYPE j_1iexcdtl-docyr,
bedinv type J_1IBEDINV,
ecsinv type J_1IECSINV,
EXADDINV1 type J_1IEXADDINV1,
exaddtax1 TYPE j_1iexcdtl-exaddtax1,
rdoc2 TYPE j_1iexcdtl-rdoc2,
ritem2 TYPE j_1iexcdtl-ritem2,
menge TYPE j_1iexcdtl-menge,
ADDED FOR RUDRAPUR ON 08.03.2008 BY ASHOK.CH
*ENDED ON 08.02.2008
END OF wa1_j_1iexcdtl.
TYPES :BEGIN OF wa1_lfa1,
name1 TYPE lfa1-name1,
ktokk TYPE lfa1-ktokk,
werks TYPE lfa1-werks,
lifnr TYPE lfa1-lifnr,
END OF wa1_lfa1.
TYPES :BEGIN OF wa1_ekexclf,
belnr TYPE ekbe-belnr,
budat TYPE ekbe-budat,
menge TYPE ekbe-menge,
ebelp TYPE ekbe-ebelp,
ebeln TYPE ekbe-ebeln,
gjahr TYPE ekbe-gjahr,
awkey(20) TYPE c,
exnum TYPE j_1iexcdtl-exnum,
exdat TYPE j_1iexcdtl-exdat,
lifnr TYPE j_1iexcdtl-lifnr,
matnr TYPE j_1iexcdtl-matnr ,
maktx TYPE j_1iexcdtl-maktx ,
capind TYPE j_1iexcdtl-capind,
exbas TYPE j_1iexcdtl-exbas,
exbed TYPE j_1iexcdtl-exbed,
ecs TYPE j_1iexcdtl-ecs,
werks TYPE j_1iexcdtl-werks,
ritem1 TYPE j_1iexcdtl-ritem1,
rdoc1 TYPE j_1iexcdtl-rdoc1,
docyr TYPE j_1iexcdtl-docyr,
name1 TYPE lfa1-name1,
ktokk TYPE lfa1-ktokk,
exaddtax1 TYPE j_1iexcdtl-exaddtax1,
added for rudrapur on 08.03.2008 by ASHOK.CH
bedinv type J_1IBEDINV,
ecsinv type J_1IECSINV,
EXADDINV1 type J_1IEXADDINV1,
END OF MODIFICATION ON 08.02.2008
END OF wa1_ekexclf.
TYPES :BEGIN OF wa1_bkpf,
bukrs TYPE bkpf-bukrs,
belnr TYPE bkpf-belnr,
gjahr TYPE bkpf-gjahr,
budat TYPE bkpf-budat,
tcode TYPE bkpf-tcode,
awkey TYPE bkpf-awkey,
END OF wa1_bkpf.
TYPES :BEGIN OF wa1_bseg,
bukrs TYPE bseg-bukrs,
belnr TYPE bseg-belnr,
gjahr TYPE bseg-gjahr,
buzei TYPE bseg-buzei,
bschl TYPE bseg-bschl,
fwbas TYPE bseg-fwbas ,
pswbt TYPE bseg-pswbt,
hkont TYPE bseg-hkont,
wrbtr TYPE bseg-wrbtr,
ktosl TYPE bseg-ktosl,
koart TYPE bseg-koart,
shkzg TYPE bseg-shkzg,
mwskz TYPE bseg-mwskz,
qsskz TYPE bsis-qsskz,
dmbtr TYPE bseg-dmbtr,
lifnr TYPE bseg-lifnr,
matnr TYPE bseg-matnr,
flag TYPE C,
flag_21 TYPE C,
END OF wa1_bseg.
TYPES :BEGIN OF wa1_tax,
belnr TYPE bseg-belnr,
fi_docno TYPE bseg-belnr,
gjahr TYPE bseg-gjahr,
bukrs TYPE bseg-bukrs,
awkey TYPE bkpf-awkey,
fwbas TYPE bseg-fwbas ,
cst_amt TYPE bseg-pswbt,
vat_amt TYPE bseg-pswbt,
shcess_amt TYPE bseg-pswbt,
gl_accnt TYPE bseg-hkont,
gl_desc TYPE skat-txt50,
wctglacc TYPE bseg-hkont,
wctamt TYPE bseg-dmbtr,
taxcode TYPE t059z-wt_withcd,
taxperc TYPE t059z-qsatz,
total_value TYPE bseg-wrbtr,
set_off TYPE bseg-wrbtr,
cond_type TYPE konv-kschl,
description(20) TYPE c,
service_tax TYPE bseg-wrbtr,
service_ecess TYPE bseg-wrbtr,
service_shcess TYPE bseg-wrbtr, "vincy on 31.01.08
ebelp TYPE ekbe-ebelp, " on 15.04.08
flag TYPE c,
mwskz TYPE bseg-mwskz,
END OF wa1_tax.
DATA:BEGIN OF itab_skat,
saknr TYPE skat-saknr,
spras TYPE skat-spras,
txt50 TYPE skat-txt50,
END OF itab_skat.
DATA: iskat LIKE itab_skat OCCURS 0,
wa_skat LIKE itab_skat.
DATA : BEGIN OF zbsis OCCURS 0,
bukrs TYPE bsis-bukrs,
hkont TYPE bsis-hkont,
augdt TYPE bsis-augdt,
augbl TYPE bsis-augbl,
zuonr TYPE bsis-zuonr,
gjahr TYPE bsis-gjahr,
belnr TYPE bsis-belnr,
buzei TYPE bsis-buzei,
budat TYPE bsis-budat,
qsskz TYPE bsis-qsskz,
END OF zbsis.
DATA: BEGIN OF zt059z OCCURS 0,
land1 TYPE t059z-land1,
witht TYPE t059z-witht,
wt_withcd TYPE t059z-wt_withcd,
qscod TYPE t059z-qscod,
qsatz TYPE t059z-qsatz,
hkont TYPE bsis-hkont,
belnr TYPE bsis-belnr,
END OF zt059z.
DATA: BEGIN OF it_faglflexa OCCURS 0, "added by vincy
ryear TYPE faglflexa-ryear,
docnr TYPE faglflexa-docnr,
rldnr TYPE faglflexa-rldnr,
rbukrs TYPE faglflexa-rbukrs,
docln TYPE faglflexa-docln,
prctr TYPE faglflexa-prctr,
END OF it_faglflexa.
Final Table***
TYPES :BEGIN OF wa1_final,
belnr TYPE ekbe-belnr,
fi_docno TYPE bseg-belnr,
budat TYPE ekbe-budat,
menge TYPE ekbe-menge,
rate TYPE konv-kbetr,
ebelp TYPE ekbe-ebelp,
ebeln TYPE ekbe-ebeln,
mwskz TYPE bseg-mwskz,
gjahr TYPE ekbe-gjahr,
awkey(20) TYPE c,
exnum TYPE j_1iexcdtl-exnum,
exdat TYPE j_1iexcdtl-exdat,
lifnr TYPE j_1iexcdtl-lifnr,
matnr TYPE j_1iexcdtl-matnr ,
maktx TYPE j_1iexcdtl-maktx ,
capind TYPE string,
exbas TYPE j_1iexcdtl-exbas,
exbed TYPE j_1iexcdtl-exbed,
ecs TYPE j_1iexcdtl-ecs,
werks TYPE j_1iexcdtl-werks,
ritem1 TYPE j_1iexcdtl-ritem1,
rdoc1 TYPE j_1iexcdtl-rdoc1,
docyr TYPE j_1iexcdtl-docyr,
name1 TYPE lfa1-name1,
ktokk TYPE lfa1-ktokk,
fwbas TYPE bseg-fwbas ,
vat_per TYPE konv-kbetr,
vat_amt TYPE bseg-pswbt,
cst_per TYPE konv-kbetr,
cst_amt TYPE bseg-pswbt,
shcess_amt TYPE bseg-pswbt,
gl_accnt TYPE bseg-hkont,
gl_desc TYPE skat-txt50,
wctglacc TYPE bseg-hkont,
wctamt TYPE bseg-dmbtr,
taxcode TYPE t059z-wt_withcd,
taxperc TYPE t059z-qsatz,
total_value TYPE bseg-wrbtr,
total_value1 TYPE bseg-wrbtr,
excise_tax TYPE bseg-wrbtr,
excise TYPE bseg-wrbtr,
set_off TYPE bseg-wrbtr,
inventorised TYPE konv-kawrt,
cond_type TYPE konv-kschl,
cond_type2 TYPE konv-kschl,
description(20) TYPE c,
service_tax TYPE bseg-wrbtr,
service_ecess TYPE bseg-wrbtr,
service_shcess TYPE bseg-wrbtr, "vincy on 31.01.08
END OF wa1_final.
DATA :it2_ekbe TYPE TABLE OF wa1_ekbe WITH HEADER LINE,
it_ekbe TYPE TABLE OF wa1_ekbe WITH HEADER LINE,
it1_ekbe TYPE TABLE OF wa2_ekbe WITH HEADER LINE WITH KEY ebelp ebeln,
it_j_1iexcdtl TYPE TABLE OF wa1_j_1iexcdtl WITH HEADER LINE WITH KEY rdoc1 ritem1,
it_lfa1 TYPE TABLE OF wa1_lfa1 WITH HEADER LINE WITH KEY lifnr,
it_lfa2 TYPE TABLE OF wa1_lfa1 WITH HEADER LINE WITH KEY lifnr,
it_bkpf TYPE TABLE OF wa1_bkpf WITH HEADER LINE,
it_bseg TYPE TABLE OF wa1_bseg WITH HEADER LINE WITH KEY
bukrs belnr gjahr ktosl shkzg koart,
it1_bseg TYPE TABLE OF wa1_bseg WITH HEADER LINE WITH KEY
bukrs belnr gjahr ktosl shkzg koart,
it_tax TYPE TABLE OF wa1_tax WITH HEADER LINE WITH KEY awkey ,
it_ekexclf TYPE TABLE OF wa1_ekexclf WITH HEADER LINE,
it_final TYPE TABLE OF wa1_final WITH HEADER LINE,
it_final1 TYPE TABLE OF wa1_final WITH HEADER LINE, "vincy
wa_ekbe TYPE wa1_ekbe,
wa1_ekbe TYPE wa2_ekbe,
wa_j_1iexcdtl TYPE wa1_j_1iexcdtl,
wa_lfa1 TYPE wa1_lfa1,
wa_lfa2 TYPE wa1_lfa1,
wa_bkpf TYPE wa1_bkpf,
wa_bseg TYPE wa1_bseg,
wa_tax TYPE wa1_tax,
wa_ekexclf TYPE wa1_ekexclf,
PLANT TYPE WERKS_D,
wa_final TYPE wa1_final.
DATA: it_konv TYPE konv OCCURS 0 WITH HEADER LINE ,
wa_konv TYPE konv,
invent TYPE p DECIMALS 4,
invent1 TYPE konv-kawrt.
DATA:d1 TYPE konv-kposn,
d2 TYPE ekbe-ebelp.
DATA: v_belnr TYPE ekbe-belnr,
v_gjahr TYPE ekbe-gjahr,
v_awkey(20) TYPE c,
idx TYPE sy-tabix.
**********by vincy on 12.01.07***********
DATA: BEGIN OF it_ekko OCCURS 0,
ebeln LIKE ekko-ebeln,
bukrs LIKE ekko-bukrs,
bsart LIKE ekko-bsart,
lifnr LIKE ekko-lifnr,
belnr LIKE ekbe-belnr,
END OF it_ekko.
DATA: BEGIN OF it_ekpo OCCURS 0,
ebeln LIKE ekpo-ebeln,
ebelp LIKE ekpo-ebelp,
txz01 LIKE ekpo-txz01,
END OF it_ekpo.
DATA: BEGIN OF it_lfa1v OCCURS 0,
lifnr LIKE lfa1-lifnr,
name1 LIKE lfa1-name1,
END OF it_lfa1v.
DATA: BEGIN OF s_prctr OCCURS 0,
low LIKE faglflexa-prctr,
END OF s_prctr.
DATA: it_bsegv TYPE TABLE OF wa1_bseg WITH HEADER LINE.
DATA: it_konv1 LIKE konv OCCURS 0 WITH HEADER LINE.
DATA:cnt TYPE i,
awkey1(250).
DATA: LIFNR TYPE LIFNR,
NAME TYPE NAME1_GP,
MTART TYPE MARA-MTART,
MAKTX TYPE MAKTX,
TAX_TOT TYPE KWERT.
***********end of changes by vincy ************
Selection Screen
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.
SELECT-OPTIONS: s_werks1 FOR ekbe-werks,
s_budat1 FOR ekbe-budat,
s_fiscal FOR ekbe-gjahr,
s_lifnr FOR lfa1-lifnr.
SELECTION-SCREEN END OF BLOCK b1.
**"changes being by nahid on 16.04.2008
PARAMETERS : excel AS CHECKBOX DEFAULT 'X'.
PARAMETERS: infile LIKE rlgrap-filename.
DATA : zfile TYPE string.
**"changes ended by nahid on 16.04.2008
AT SELECTION-SCREEN.
IF s_werks1 IS INITIAL.
MESSAGE 'Please Enter Plant details' TYPE 'E'.
ENDIF.
IF s_budat1 IS INITIAL.
MESSAGE 'Please Enter Posting date' TYPE 'E'.
ENDIF.
IF s_fiscal IS INITIAL.
MESSAGE 'Please Enter Fiscal Year' TYPE 'E'.
ENDIF.
*start change by nahid on 16.4.08
AT SELECTION-SCREEN ON VALUE-REQUEST FOR infile.
CALL FUNCTION 'KD_GET_FILENAME_ON_F4'
CHANGING
file_name = infile
EXCEPTIONS
mask_too_long = 1
OTHERS = 2.
zfile = infile.
*end change by nahid on 16.4.08
START-OF-SELECTION.
plant = s_werks1-low.
MODIFIED FOR RUDRAPUR BY ASHOK.CH ON 13.03.2008
IF PLANT NE 'RD01'.
PERFORM get_data.
PERFORM get_zpsr. "vincy
ENDIF.
IF PLANT EQ 'RD01'.
PERFORM get_data1.
ENDIF.
*END OF MODIFICATION ON 13.03.2008
PERFORM build_fieldcatalog.
PERFORM build_layout.
PERFORM display_alv_report.
*start chng by nahid on 16.4.08
IF excel = 'X'.
IF NOT infile IS INITIAL.
PERFORM excel_data.
ELSE.
MESSAGE e000(0) WITH 'Please Enter the File Path'.
ENDIF.
ENDIF.
*end by nahid on 16.4.08
*& Form get_data
FORM get_data .
SELECT belnr budat menge matnr ebelp ebeln gjahr lfbnr lfpos bldat REEWR FROM ekbe INTO
TABLE it_ekbe
WHERE werks IN s_werks1 AND
(bewtp EQ 'Q' OR bewtp EQ 'N') AND
bewtp IN ('Q' , 'N') AND "added N by vincy on 6.07.2008
budat IN s_budat1 AND
gjahr IN s_fiscal .
IF sy-subrc = 0. "for 1st ekbe
IF it_ekbe[] IS NOT INITIAL.
SELECT exnum exdat lifnr matnr maktx capind exbas exbed ecs werks
ritem1 rdoc1 docyr bedinv ecsinv EXADDINV1 exaddtax1 rdoc2 ritem2 menge
FROM j_1iexcdtl INTO TABLE it_j_1iexcdtl FOR ALL ENTRIES IN it_ekbe
WHERE rdoc1 = it_ekbe-ebeln
AND ritem1 = it_ekbe-ebelp AND
lifnr IN s_lifnr.
ENDIF.
IF it_j_1iexcdtl[] IS NOT INITIAL.
SELECT name1 ktokk werks lifnr FROM lfa1 INTO
TABLE it_lfa1 FOR ALL ENTRIES IN it_j_1iexcdtl
WHERE lifnr = it_j_1iexcdtl-lifnr.
ENDIF.
LOOP AT it_ekbe INTO wa_ekbe.
wa1_ekbe-belnr = wa_ekbe-belnr.
wa1_ekbe-budat = wa_ekbe-budat.
wa1_ekbe-menge = wa_ekbe-menge.
wa1_ekbe-ebelp = wa_ekbe-ebelp.
wa1_ekbe-ebeln = wa_ekbe-ebeln.
wa1_ekbe-gjahr = wa_ekbe-gjahr.
wa1_ekbe-matnr = wa_ekbe-matnr.
wa1_ekbe-lfbnr = wa_ekbe-lfbnr.
wa1_ekbe-lfpos = wa_ekbe-lfpos.
wa1_ekbe-bldat = wa_ekbe-bldat.
v_belnr = wa_ekbe-belnr.
v_gjahr = wa_ekbe-gjahr.
CONCATENATE v_belnr v_gjahr INTO v_awkey.
wa1_ekbe-awkey = v_awkey.
APPEND wa1_ekbe TO it1_ekbe.
CLEAR :wa_ekbe.
ENDLOOP.
************changes by vincy on 29.05.08 for 'FB08' and 'FB60'**************
LOOP AT s_werks1.
IF s_werks1-low = 'KN01'.
s_prctr-low = 'MUKNHSTM'.
ELSEIF
s_werks1-low = 'NS01'.
s_prctr-low = 'MUNSKSTM'.
ELSEIF
s_werks1-low = 'RD01'.
s_prctr-low = 'MURDPSTM'.
ENDIF.
APPEND s_prctr.
ENDLOOP.
SELECT bukrs belnr gjahr budat tcode awkey FROM bkpf INTO TABLE it_bkpf
WHERE bukrs = 'MU51' AND
gjahr IN s_fiscal AND
budat IN s_budat1 AND
( tcode = 'FB60' OR tcode = 'FB08' ).
IF it_bkpf[] IS NOT INITIAL.
SELECT ryear docnr rldnr rbukrs docln prctr FROM faglflexa INTO TABLE it_faglflexa
FOR ALL ENTRIES IN it_bkpf WHERE rbukrs = 'MU51' AND
ryear = it_bkpf-gjahr AND
docnr = it_bkpf-belnr.
ENDIF.
LOOP AT it_faglflexa.
READ TABLE s_prctr WITH KEY low = it_faglflexa-prctr.
IF sy-subrc <> 0.
DELETE it_faglflexa.
ENDIF.
CLEAR: it_faglflexa, s_prctr.
ENDLOOP.
**************************end of change*************************************
IF it1_ekbe[] IS NOT INITIAL.
SELECT bukrs belnr gjahr budat tcode awkey FROM bkpf APPENDING
TABLE it_bkpf FOR ALL ENTRIES IN it1_ekbe
WHERE bukrs = 'MU51' AND
gjahr IN s_fiscal AND
awkey = it1_ekbe-awkey.
ENDIF.
IF sy-subrc = 0. "bkpf
IF it_bkpf[] IS NOT INITIAL.
SELECT bukrs belnr gjahr buzei bschl fwbas pswbt hkont wrbtr ktosl koart shkzg mwskz qsskz dmbtr lifnr matnr
FROM bseg INTO TABLE it1_bseg FOR ALL ENTRIES IN it_bkpf
WHERE belnr = it_bkpf-belnr AND
gjahr = it_bkpf-gjahr AND
bukrs = it_bkpf-bukrs AND
( bschl = '21' ) AND
lifnr IN s_lifnr. "added 21 for miro cancelation
IF it1_bseg[] IS NOT INITIAL.
SELECT bukrs belnr gjahr buzei bschl fwbas pswbt hkont wrbtr ktosl koart shkzg mwskz qsskz dmbtr lifnr matnr
FROM bseg INTO TABLE it_bseg FOR ALL ENTRIES IN it1_bseg
WHERE belnr = it1_bseg-belnr AND
gjahr = it1_bseg-gjahr AND "changed it_bkpf to it1_bseg
bukrs = it1_bseg-bukrs .
LOOP AT it_bseg.
it_bseg-wrbtr = it_bseg-wrbtr * -1.
it_bseg-fwbas = it_bseg-fwbas * -1.
it_bseg-pswbt = it_bseg-pswbt * -1.
it_bseg-flag_21 = 'X'.
MODIFY it_bseg.
CLEAR it_bseg.
ENDLOOP.
SELECT name1 ktokk werks lifnr FROM lfa1 INTO
TABLE it_lfa2 FOR ALL ENTRIES IN it1_bseg
WHERE lifnr = it1_bseg-lifnr.
ENDIF.
REFRESH it1_bseg.
SELECT bukrs belnr gjahr buzei bschl fwbas pswbt hkont wrbtr ktosl koart shkzg mwskz qsskz dmbtr lifnr matnr
FROM bseg INTO TABLE it1_bseg FOR ALL ENTRIES IN it_bkpf
WHERE belnr = it_bkpf-belnr AND
gjahr = it_bkpf-gjahr AND
bukrs = it_bkpf-bukrs AND
( bschl = '31' ) AND "added bschl and lifnr by vincy
lifnr IN s_lifnr.
IF it1_bseg[] IS NOT INITIAL.
SELECT name1 ktokk werks lifnr FROM lfa1 APPENDING
TABLE it_lfa2 FOR ALL ENTRIES IN it1_bseg
WHERE lifnr = it1_bseg-lifnr.
SELECT bukrs belnr gjahr buzei bschl fwbas pswbt hkont wrbtr ktosl koart shkzg mwskz qsskz dmbtr lifnr matnr
FROM bseg APPENDING TABLE it_bseg FOR ALL ENTRIES IN it1_bseg
WHERE belnr = it1_bseg-belnr AND
gjahr = it1_bseg-gjahr AND "changed it_bkpf to it1_bseg
bukrs = it1_bseg-bukrs AND
bschl <> '35'. "added bschl to avoid vendor paymnt
ENDIF.
SELECT bukrs belnr gjahr buzei bschl fwbas pswbt hkont wrbtr ktosl koart shkzg mwskz qsskz dmbtr lifnr
FROM bseg APPENDING CORRESPONDING FIELDS OF TABLE it_bseg
FOR ALL ENTRIES IN it_bkpf
WHERE belnr = it_bkpf-belnr AND
gjahr = it_bkpf-gjahr AND
lifnr IN s_lifnr AND
bukrs = it_bkpf-bukrs AND qsskz IN ('WI', 'WJ').
ENDIF.
ENDIF.
SORT it_bseg BY belnr buzei.
IF NOT it_bseg[] IS INITIAL.
SELECT saknr spras txt50 FROM skat
INTO TABLE iskat
FOR ALL ENTRIES IN it_bseg
WHERE saknr = it_bseg-hkont AND spras = 'EN'.
SELECT bukrs hkont augdt augbl zuonr gjahr belnr buzei budat qsskz FROM bsis
INTO TABLE zbsis
FOR ALL ENTRIES IN it_bseg
WHERE bukrs = 'MU51' AND hkont = it_bseg-hkont
AND belnr = it_bseg-belnr AND gjahr = s_fiscal
AND budat IN s_budat1.
ENDIF.
LOOP AT it_bseg.
READ TABLE zbsis WITH KEY hkont = it_bseg-hkont.
IF sy-subrc = 0.
it_bseg-qsskz = zbsis-qsskz.
MODIFY it_bseg.
ENDIF.
CLEAR: it_bseg,zbsis.
ENDLOOP.
LOOP AT zt059z.
LOOP AT it_bseg WHERE qsskz = zt059z-wt_withcd.
zt059z-hkont = it_bseg-hkont.
zt059z-belnr = it_bseg-belnr.
MODIFY zt059z.
CLEAR: it_bseg,zt059z.
ENDLOOP.
ENDLOOP.
CLEAR: wa_bkpf.
*******Filling Wa.
LOOP AT it_bkpf INTO wa_bkpf. "changes by vincy on 14.04.2008
LOOP AT it1_ekbe INTO wa1_ekbe .
READ TABLE it_bkpf INTO wa_bkpf
WITH KEY awkey = wa1_ekbe-awkey.
wa_tax-belnr = wa_bkpf-belnr.
wa_tax-gjahr = wa_bkpf-gjahr.
wa_tax-bukrs = wa_bkpf-bukrs.
wa_tax-awkey = wa_bkpf-awkey.
wa_tax-ebelp = wa1_ekbe-ebelp.
CLEAR: wa_bseg,wa_skat.
READ TABLE it_bseg WITH KEY bukrs = wa_bkpf-bukrs
belnr = wa_bkpf-belnr
gjahr = wa_bkpf-gjahr INTO wa_bseg.
IF sy-subrc = 0.
wa_tax-fi_docno = wa_bseg-belnr.
wa_tax-mwskz = wa_bseg-mwskz.
CLEAR: wa_bseg.
READ TABLE it_bseg WITH KEY bukrs = wa_bkpf-bukrs
belnr = wa_bkpf-belnr
gjahr = wa_bkpf-gjahr
flag = ''
ktosl = 'JP4' INTO wa_bseg.
IF sy-subrc = 0.
wa_bseg-flag = 'X'.
MODIFY it_bseg INDEX sy-tabix FROM wa_bseg.
wa_tax-gl_accnt = wa_bseg-hkont.
READ TABLE iskat INTO wa_skat WITH KEY saknr = wa_bseg-hkont.
IF sy-subrc = 0.
wa_tax-gl_desc = wa_skat-txt50.
ENDIF.
wa_tax-set_off = wa_bseg-wrbtr.
wa_tax-fwbas = wa_bseg-fwbas.
wa_tax-cst_amt = wa_bseg-pswbt.
wa_tax-description = 'CST CG Sett off'.
wa_tax-cond_type = 'JVCS'.
ENDIF.
READ TABLE it_bseg WITH KEY bukrs = wa_bkpf-bukrs
belnr = wa_bkpf-belnr
gjahr = wa_bkpf-gjahr
flag = ''
ktosl = 'VS1' INTO wa_bseg.
IF sy-subrc = 0.
wa_bseg-flag = 'X'.
MODIFY it_bseg INDEX sy-tabix FROM wa_bseg.
wa_tax-fwbas = wa_bseg-fwbas.
ENDIF.
READ TABLE it_bseg WITH KEY bukrs = wa_bkpf-bukrs
belnr = wa_bkpf-belnr
gjahr = wa_bkpf-gjahr
flag = ''
ktosl = 'JP7' INTO wa_bseg.
IF sy-subrc = 0.
wa_bseg-flag = 'X'.
MODIFY it_bseg INDEX sy-tabix FROM wa_bseg.
wa_tax-gl_accnt = wa_bseg-hkont.
READ TABLE iskat INTO wa_skat WITH KEY saknr = wa_bseg-hkont.
IF sy-subrc = 0.
wa_tax-gl_desc = wa_skat-txt50.
ENDIF.
wa_tax-set_off = wa_bseg-wrbtr.
wa_tax-fwbas = wa_bseg-fwbas.
wa_tax-vat_amt = wa_bseg-pswbt.
wa_tax-description = 'VAT CG Sett off'.
wa_tax-cond_type = 'JVCD'.
ENDIF.
CLEAR wa_bseg.
READ TABLE it_bseg WITH KEY bukrs = wa_bkpf-bukrs
belnr = wa_bkpf-belnr
gjahr = wa_bkpf-gjahr
flag = ''
ktosl = 'JP5' INTO wa_bseg.
READ TABLE it_bseg WITH KEY bukrs = wa_bkpf-bukrs
belnr = wa_bkpf-belnr
gjahr = wa_bkpf-gjahr
hkont = '0002868001' INTO wa_bseg. "vat changed for V0 tax code
IF sy-subrc = 0.
wa_bseg-flag = 'X'.
MODIFY it_bseg INDEX sy-tabix FROM wa_bseg.
wa_tax-gl_accnt = wa_bseg-hkont.
READ TABLE iskat INTO wa_skat WITH KEY saknr = wa_bseg-hkont.
IF sy-subrc = 0.
wa_tax-gl_desc = wa_skat-txt50.
ENDIF.
wa_tax-vat_amt = wa_bseg-pswbt.
wa_tax-set_off = wa_bseg-wrbtr.
wa_tax-cond_type = 'JVRD'.
wa_tax-fwbas = wa_bseg-fwbas.
wa_tax-description = 'VAT RM Set off'.
ENDIF.
CLEAR: wa_bseg,wa_skat.
READ TABLE it_bseg WITH KEY bukrs = wa_bkpf-bukrs
belnr = wa_bkpf-belnr
gjahr = wa_bkpf-gjahr
shkzg = 'H'
koart = 'K'
INTO wa_bseg.
IF sy-subrc = 0.
wa_tax-total_value = wa_bseg-wrbtr.
ENDIF.
START OF MODIFICATION BY ASHOK.CH ON 08.02.2008
service_tax
CLEAR wa_bseg.
READ TABLE it_bseg WITH KEY bukrs = wa_bkpf-bukrs
belnr = wa_bkpf-belnr
gjahr = wa_bkpf-gjahr
flag = ''
ktosl = 'VS8' INTO wa_bseg.
IF sy-subrc = 0.
wa_bseg-flag = 'X'.
MODIFY it_bseg INDEX sy-tabix FROM wa_bseg.
wa_tax-gl_accnt = wa_bseg-hkont.
READ TABLE iskat INTO wa_skat WITH KEY saknr = wa_bseg-hkont.
IF sy-subrc = 0.
wa_tax-gl_desc = wa_skat-txt50.
ENDIF.
wa_tax-service_tax = wa_bseg-wrbtr.
wa_tax-description = 'Service Tax'.
wa_tax-cond_type = 'JSRT'.
ENDIF.
service_ecess
CLEAR: wa_bseg,wa_skat.
READ TABLE it_bseg WITH KEY bukrs = wa_bkpf-bukrs
belnr = wa_bkpf-belnr
gjahr = wa_bkpf-gjahr
flag = ''
ktosl = 'VS9' INTO wa_bseg.
IF sy-subrc = 0.
wa_bseg-flag = 'X'.
MODIFY it_bseg INDEX sy-tabix FROM wa_bseg.
wa_tax-service_ecess = wa_bseg-wrbtr.
ENDIF.
**********changes by vincy on 31.01.08*********************
service_shcess
CLEAR: wa_bseg.
READ TABLE it_bseg WITH KEY bukrs = wa_bkpf-bukrs
belnr = wa_bkpf-belnr
gjahr = wa_bkpf-gjahr
flag = ''
ktosl = 'VSE' INTO wa_bseg.
IF sy-subrc = 0.
wa_bseg-flag = 'X'.
MODIFY it_bseg INDEX sy-tabix FROM wa_bseg.
wa_tax-service_shcess = wa_bseg-wrbtr.
ENDIF.
*************************end of changes***********************
END OF MODIFICATION ON 08.02.2008
APPEND wa_tax TO it_tax.
ENDIF.
CLEAR :wa_tax,wa_bseg,wa_bkpf,wa_skat.
ENDLOOP.
CLEAR wa1_ekbe.
LOOP AT it1_ekbe INTO wa1_ekbe.
READ TABLE it_j_1iexcdtl INTO wa_j_1iexcdtl
WITH KEY rdoc1 = wa1_ekbe-ebeln
ritem1 = wa1_ekbe-ebelp.
*New query added by Nilesh
READ TABLE it_j_1iexcdtl INTO wa_j_1iexcdtl
WITH KEY rdoc1 = wa1_ekbe-lfbnr
ritem2 = wa1_ekbe-lfpos.
READ TABLE it_bkpf INTO wa_bkpf
WITH KEY awkey = wa1_ekbe-awkey.
IF sy-subrc = 0.
READ TABLE it_bseg WITH KEY bukrs = wa_bkpf-bukrs
belnr = wa_bkpf-belnr
gjahr = wa_bkpf-gjahr.
IF sy-subrc = 0.
wa_ekexclf-belnr = wa1_ekbe-belnr.
wa_ekexclf-budat = wa1_ekbe-budat.
wa_ekexclf-menge = wa1_ekbe-menge.
wa_ekexclf-ebelp = wa1_ekbe-ebelp.
wa_ekexclf-ebeln = wa1_ekbe-ebeln.
wa_ekexclf-gjahr = wa1_ekbe-gjahr.
wa_ekexclf-awkey = wa1_ekbe-awkey.
wa_ekexclf-lifnr = it_bseg-lifnr.
wa_ekexclf-matnr = it_bseg-matnr .
READ TABLE it_j_1iexcdtl INTO wa_j_1iexcdtl "for records for which either rdoc1 or matnr
WITH KEY rdoc2 = wa1_ekbe-lfbnr "not maintained in ekbe by vincy on 16.06.08
menge = wa1_ekbe-menge.
IF sy-subrc <> 0 .
READ TABLE it_j_1iexcdtl INTO wa_j_1iexcdtl
WITH KEY rdoc1 = wa1_ekbe-ebeln
exdat = wa1_ekbe-bldat
matnr = wa1_ekbe-matnr
menge = wa1_ekbe-menge.
ENDIF.
READ TABLE it_j_1iexcdtl INTO wa_j_1iexcdtl
WITH KEY rdoc1 = wa1_ekbe-ebeln
ritem1 = wa1_ekbe-ebelp.
IF sy-subrc = 0.
wa_ekexclf-belnr = wa1_ekbe-belnr.
wa_ekexclf-budat = wa1_ekbe-budat.
wa_ekexclf-menge = wa1_ekbe-menge.
wa_ekexclf-ebelp = wa1_ekbe-ebelp.
wa_ekexclf-ebeln = wa1_ekbe-ebeln.
wa_ekexclf-gjahr = wa1_ekbe-gjahr.
wa_ekexclf-awkey = wa1_ekbe-awkey.
wa_ekexclf-exnum = wa_j_1iexcdtl-exnum.
wa_ekexclf-exdat = wa_j_1iexcdtl-exdat.
wa_ekexclf-lifnr = wa_j_1iexcdtl-lifnr.
wa_ekexclf-matnr = wa_j_1iexcdtl-matnr .
wa_ekexclf-maktx = wa_j_1iexcdtl-maktx .
wa_ekexclf-capind = wa_j_1iexcdtl-capind.
wa_ekexclf-exbas = wa_j_1iexcdtl-exbas.
wa_ekexclf-exbed = wa_j_1iexcdtl-exbed.
wa_ekexclf-ecs = wa_j_1iexcdtl-ecs.
wa_ekexclf-werks = wa_j_1iexcdtl-werks.
wa_ekexclf-ritem1 = wa_j_1iexcdtl-ritem1.
wa_ekexclf-rdoc1 = wa_j_1iexcdtl-rdoc1.
wa_ekexclf-docyr = wa_j_1iexcdtl-docyr.
wa_ekexclf-exaddtax1 = wa_j_1iexcdtl-exaddtax1.
IF it_bseg-flag_21 = 'X'.
wa_ekexclf-exbas = wa_ekexclf-exbas * -1.
ENDIF.
MODIFIED BY ASHOK.CH ON 08.03.2008
IF wa_j_1iexcdtl-WERKS NE 'RD01' .
wa_ekexclf-exbed = wa_j_1iexcdtl-exbed.
wa_ekexclf-ecs = wa_j_1iexcdtl-ecs.
wa_ekexclf-exaddtax1 = wa_j_1iexcdtl-exaddtax1.
IF it_bseg-flag_21 = 'X'.
wa_ekexclf-exbed = wa_ekexclf-exbed * -1.
wa_ekexclf-ecs = wa_ekexclf-ecs * -1.
wa_ekexclf-exaddtax1 = wa_ekexclf-exaddtax1 * -1.
ENDIF.
ELSE.
wa_ekexclf-exbed = wa_j_1iexcdtl-BEDINV.
wa_ekexclf-ecs = wa_j_1iexcdtl-ecsINV.
wa_ekexclf-exaddtax1 = wa_j_1iexcdtl-exaddINV1.
ENDIF.
END IF MODIFICATION ON 08.03.2008
APPEND wa_ekexclf TO it_ekexclf.
CLEAR :wa_lfa1,wa_j_1iexcdtl,wa1_ekbe.
ENDIF.
READ TABLE it_lfa2 INTO wa_lfa2
WITH KEY lifnr = wa_ekexclf-lifnr.
IF sy-subrc = 0.
wa_ekexclf-name1 = wa_lfa2-name1.
wa_ekexclf-ktokk = wa_lfa2-ktokk.
ENDIF.
APPEND wa_ekexclf TO it_ekexclf.
ENDIF.
ENDIF.
CLEAR :wa_lfa1,wa_j_1iexcdtl,wa1_ekbe,wa_lfa2,wa_ekexclf.
ENDLOOP.
CLEAR wa_ekexclf.
LOOP AT it_ekexclf INTO wa_ekexclf.
wa_final-belnr = wa_ekexclf-belnr.
wa_final-budat = wa_ekexclf-budat.
wa_final-menge = wa_ekexclf-menge.
wa_final-ebelp = wa_ekexclf-ebelp.
wa_final-ebeln = wa_ekexclf-ebeln.
wa_final-gjahr = wa_ekexclf-gjahr.
wa_final-awkey = wa_ekexclf-awkey.
wa_final-exnum = wa_ekexclf-exnum.
wa_final-exdat = wa_ekexclf-exdat.
wa_final-lifnr = wa_ekexclf-lifnr.
wa_final-matnr = wa_ekexclf-matnr .
wa_final-maktx = wa_ekexclf-maktx .
wa_final-shcess_amt = wa_ekexclf-exaddtax1.
IF wa_ekexclf-capind = 'C'.
wa_final-capind = 'Consumables'.
ENDIF.
IF wa_ekexclf-capind = 'A'.
wa_final-capind = 'Assets'.
ENDIF.
IF wa_ekexclf-capind = 'T'.
wa_final-capind = 'Tools'.
ENDIF.
IF wa_ekexclf-capind = ''.
wa_final-capind = 'Raw Material'.
ENDIF.
IF wa_ekexclf-capind = 'N'.
wa_final-capind = 'Non Cenvatable'.
ENDIF.
IF wa_ekexclf-capind NE 'C' AND wa_ekexclf-capind NE 'A' AND
wa_ekexclf-capind NE '' AND wa_ekexclf-capind NE 'N'.
wa_final-capind = wa_ekexclf-capind.
ENDIF.
wa_final-exbas = wa_ekexclf-exbas.
wa_final-exbed = wa_ekexclf-exbed.
wa_final-ecs = wa_ekexclf-ecs.
wa_final-werks = wa_ekexclf-werks.
wa_final-ritem1 = wa_ekexclf-ritem1.
wa_final-rdoc1 = wa_ekexclf-rdoc1.
wa_final-docyr = wa_ekexclf-docyr.
wa_final-name1 = wa_ekexclf-name1.
wa_final-ktokk = wa_ekexclf-ktokk.
wa_final-excise = wa_final-exbas + wa_final-exbed + wa_final-ecs + wa_final-shcess_amt.
CLEAR :wa_tax.Hi ,
I think you are using the redundant selects to fetch the data from BSEG.
First select all the data into an internal table based on bkpf.
Now you can distribute the data into whatever tables you want using the loop,read-binary search and append statements..
Loop at it_bseg.
read it_bseg where
xxxxx
xxxxx
binary search.
append wa to it2_bseg.
endloop
This avoid several database fetches..
Thank you.. -
While trying to change a BOM with transaction CS02, a runtime error appears
While trying to change a BOM with transaction CS02, a runtime error appears.
In intial screen he entered material ,plant BOM usage and date valid from after executed then id displayed item list in that he wantu2019s delete one item, he has been deleted selected item after that when he was saving he is getting runtime error
Developer trace
ABAP Program SAPLKED1_WRITE_CE4_BPS1 .
Source LKED1_WRITE_CE4_BPS1U01 Line 30.
Error Code SAPSQL_ARRAY_INSERT_DUPREC.
Module $Id: //bas/640_REL/src/krn/runt/absapsql.c#17 $ SAP.
Function HandleRsqlErrors Line 775.
RABAX: level LEV_RX_STDERR completed.
RABAX: level LEV_RX_RFC_ERROR entered.
RABAX: level LEV_RX_RFC_ERROR completed.
RABAX: level LEV_RX_RFC_CLOSE entered.
RABAX: level LEV_RX_RFC_CLOSE completed.
RABAX: level LEV_RX_IMC_ERROR entered.
RABAX: level LEV_RX_IMC_ERROR completed.
RABAX: level LEV_RX_DATASET_CLOSE entered.
RABAX: level LEV_RX_DATASET_CLOSE completed.
RABAX: level LEV_RX_RESET_SHMLOCKS entered.
RABAX: level LEV_RX_RESET_SHMLOCKS completed.
RABAX: level LEV_RX_ERROR_SAVE entered.
RABAX: level LEV_RX_ERROR_SAVE completed.
RABAX: level LEV_RX_ERROR_TPDA entered.
RABAX: level LEV_RX_ERROR_TPDA completed.
RABAX: level LEV_RX_PXA_RELEASE_RUDI entered.
RABAX: level LEV_RX_PXA_RELEASE_RUDI completed.
RABAX: level LEV_RX_LIVE_CACHE_CLEANUP entered.
RABAX: level LEV_RX_LIVE_CACHE_CLEANUP completed.
RABAX: level LEV_RX_END entered.
RABAX: level LEV_RX_END completed.
RABAX: end RX_RFC
In sm21
Perform rollback
Run-time error "SAPSQL_ARRAY_INSERT_DUPREC" occurred
Short dump "090618 110101 donalda 11557 " generated
Runtime Error SAPSQL_ARRAY_INSERT_DUPREC
Exception CX_SY_OPEN_SQL_DB
Occurred on 18.06.2009 at 11:01:01
The ABAP/4 Open SQL array insert results in duplicate database records.
What happened?
Error in ABAP application program.
The current ABAP program "SAPLKED1_WRITE_CE4_BPS1" had to be terminated because
one of the
statements could not be executed.
This is probably due to an error in the ABAP program.
What can you do?
Print out the error message (using the "Print" function)
and make a note of the actions and input that caused the
error.
To resolve the problem, contact your SAP system administrator.
You can use transaction ST22 (ABAP Dump Analysis) to view and administer
termination messages, especially those beyond their normal deletion
date.
Error analysis
An exception occurred. This exception is dealt with in more detail below
. The exception, which is assigned to the class 'CX_SY_OPEN_SQL_DB', was
neither
caught nor passed along using a RAISING clause, in the procedure
"RKE_WRITE_CE4__BPS1" "(FUNCTION)"
Since the caller of the procedure could not have expected this exception
to occur, the running program was terminated.
The reason for the exception is:
If you use an ABAP/4 Open SQL array insert to insert a record in
the database and that record already exists with the same key,
this results in a termination.
(With an ABAP/4 Open SQL single record insert in the same error
situation, processing does not terminate, but SY-SUBRC is set to 4.)
How to correct the error
The exception must either be prevented, caught within the procedure
"RKE_WRITE_CE4__BPS1"
"(FUNCTION)", or declared in the procedure's RAISING clause.
To prevent the exception, note the following:
Use an ABAP/4 Open SQL array insert only if you are sure that none of
the records passed already exists in the database.
You may able to find an interim solution to the problem
in the SAP note system. If you have access to the note system yourself,
use the following search criteria:
"SAPSQL_ARRAY_INSERT_DUPREC" CX_SY_OPEN_SQL_DBC
"SAPLKED1_WRITE_CE4_BPS1" or "LKED1_WRITE_CE4_BPS1U01"
"RKE_WRITE_CE4__BPS1"
If you cannot solve the problem yourself, please send the
following documents to SAP:
1. A hard copy print describing the problem.
To obtain this, select the "Print" function on the current screen.
2. A suitable hardcopy prinout of the system log.
To obtain this, call the system log with Transaction SM21
and select the "Print" function to print out the relevant
part.
3. If the programs are your own programs or modified SAP programs,
supply the source code.
To do this, you can either use the "PRINT" command in the editor or
print the programs using the report RSINCL00.
4. Details regarding the conditions under which the error occurred
or which actions and input led to the error.Hi ,
you are getting beacuse u are trying to do mass update to database.
Please check that below note are applicable to your system.
Note 453313 - DBIF_RSQL_ERROR_INTERNAL for mass insert
Note 869534 - AFS MRP doesn't work properly with all BOM item categories
Thanks Rishi Abrol -
Backup DC past tombstone and need help replacing it with another DC with the same name and IP
Hey Everyone
We have a single domain in a forest with 2 DCs with AD integrated DNS configured. The primary DC with all the FSMO roles is a VM (Server 2008 R2) and the backup DC is a physical server (Server 2008 non-R2).
The backup DC's hardware is very old and has been giving us a lot of issues where the system would intermittently BSOD, freeze, black screen only etc. and as a result, the server was turned off for a very long time, definitely beyond the default tombstone
lifetime of either 60 or 180 days.
We want to replace this bad backup DC with another physical server which became available as a spare and is much newer and in a working condition hardware wise. We also wish to ultimately give it the same name (FQDN) and IP to basically make it an outright
replacement for the current bad backup DC.
My questions are:
1.) If we are in a position where the bad server could possibly physically boot and start the operating system and have network connectivity, will we be able to use DCPROMO as one would normally do to demote this DC, or will it have to be done forcefully,
while keeping in mind as I said that the DC is way past the tombstone lifetime period?
2.) If it has to be done forcefully, I am aware that the meta data needs to be cleaned up in AD on the working primary DC, although I have never performed such a process before. If this is done, are there any other things I need to look out for or do
before I attempt to replace it with the other server which I will set up wit the same name (FQDN) and IP, then add to the domain, and then lastly promote as per normal using DCPROMO?
I know we will have to upgrade the scema to 2012RM as the replacement backup DC will be running this newer operating system.
Anything else you wish to add or point out to me would be highly appreciated. Thank you in advance.
Regards,
CTVHi,
I would suggest please do the metadata cleanup using the script and then remove object from below DNS console and then run the repadmin /syncall /Aed
https://gallery.technet.microsoft.com/scriptcenter/d31f091f-2642-4ede-9f97-0e1cc4d577f3
Repeat running the vbs script till the wrong/unnecessary dc’s are removed.
Cross check the removal – dsa.msc [ad users and computers] > Domain Controllers OU
Adsiedit.msc
Expand domain partition, select OU=Domain Controllers, make sure only the necessary domain controllers are listed.
Delete the incorrect domain controllers.
Dnsmgmt.msc [Dns Management]
Expand the forward lookup zones\_msdcs folder
i. Make sure only the actual domain controllers are listed, delete wrong Alias recordsremove wrong name server records
ii. Select the container [forward lookup zones\_msdcs.domain.com\dc\_sites_\sitename\_tcp] > delete incorrect _ldap and _kerberos records are listed.
iii. Select the container [forward lookup zones\_msdcs.domain.com\dc\_tcp] and delete incorrect _ldap and _kerberos records
iv. Expand the [forward lookup zones\_msdcs.domain.com\domains\guid\_tcp] and delete incorrect _ldap entries
v. Select [forward lookup zones\_msdcs.domain.com\gc] – delete incorrect HostA records
vi. Expand the [forward lookup zones\_msdcs.domain.com\gc\_sites\sitename\_tcp] – delete incorrect _ldap entries
vii. Select the [forward lookup zones\_msdcs.domain.com\gc\_tcp] – delete incorrect _ldap entries
viii. Select the [forward lookup zones\_msdcs.domain.com\pdc\_tcp] – delete incorrect _ldap entries
Expand the forward lookup zones\domain.com folder
i.
Delete Host(A) records of dc’s which are non-existant.
ii.
Correct the NameServer (NS) records
iii.
Follow steps similar to ’ A ii ‘ >> ‘ A viii’
Dssite.msc [Sites and Services]
Expand the [Sites\Sitename\Servers] – delete incorrect server’s
B. Delete incorrect subnet configurations [Sites\Subnets]
Delete incorrect site links [Sites\IP] -
My iphone / mac no longer recognize they are the same Itunes library. When I try to sync my phone now, it wants to erase everything and replace it with the computers itunes library. I have purchased items on the phone I don't want to erase them from the phone. The phone backs up fine, but won't sync.
File>Devices>Transfer Purchases from "iPhone" and then sync.
-
I have an iCloud email and Yahoo email on my iPhone that is now old as hacked and unused. I can't access anything as it asks for that account info and I don't remember the password etc. How do I delete and replace it with my new iPad email? ! Help..
Welcome to the Apple community.
If you are unable to remember your password, security questions, don’t have access to your rescue address or are unable to reset your password for whatever reason, your only option is to contact AppleCare(or Apple ID Support), upon speaking to an operator you should explain that your problem is related to your Apple ID, this way you will not be charged for assistance, even if you don’t have an AppleCare plan.
Maybe you are looking for
-
Hi, i�ve the following problem using an oracle 9i database import java.io.File; import java.io.FileInputStream; import java.io.FileNotFoundException; import java.io.OutputStream; import java.io.IOException; import java.sql.*; public class prueba publ
-
Random lines around screen and then cannot restart computer
I'm having an issue with my iMac. recently i i will turn it on and after a while there will be random lines across my screen in certain windows. when I move the windows around the line moves with the window. as i open other apps i start getting other
-
Convert Keithley 2400 Driver for Labview 8
Hello. I need someone to convert the Keithley Driver (labview 5.1) for me to use in labview 8.6. I can only use the earlier version of the driver since my program was written based on this driver. Thank you in advance. Attachments: Ke24xx.LLB 3508 K
-
Two Due Transitions from tlhe same Interactive Activity
Hi all, I am implementing a process where I need to send a notification to the user two times. One after 2 days to approve the task. Second after 4 days send a user another notification saying that u have not approved the task and therefore the ticke
-
Can i use my new 2011 21.5 inch imac as a monitor for my ps3?
hey guys well i really want to use my 21.5 inch imac as a monitor for my ps3 i know that there are devices such as the kanex xd and some belkin thingy that converts hdmi to mini display port, but guys i really want to know thanks for your help!! much