‎2008 Dec 03 2:48 PM
Hi,
I am writing a small program to update tavle TVARV. I don't want to use UPDATE TVARV statement,
is there any FM or Transaction I can use?
Thanks.
‎2008 Dec 03 2:50 PM
Hello,
Use Modify statement to store the variant the TVARV table.
Thanks,
Jayant
‎2008 Dec 03 2:53 PM
Hello,
Instead of using the TVARV table, you can use the table TVARVC.
If no record found then use INSERT statement to create a entry in table i.e. first time you execute your report, from the next time use MODIFY statement to update the values in the table.
Hope it helps.
Thanks,
Jayant
‎2008 Dec 03 3:02 PM
Have a look at FM RS_VARIANT_CHANGE
And please search before asking.
Rob
‎2008 Dec 03 3:20 PM
Hi everyone,
Thanks for your reply.
Sorry I didn't make the question clear.
I have an variable 'AUCIO' in table TVARV already, it's used to update the post period parameter
of program RKO7KO8G. I wrote a small program to update the table TVARV.
TABLES: T009B.
DATA: gv_low(3) type c,
GV_PERIV LIKE T009B-PERIV VALUE 'Z1',
GV_PERIOD LIKE T009B-POPER.
CALL FUNCTION 'DATE_TO_PERIOD_CONVERT'
EXPORTING
I_DATE = SY-DATUM
I_PERIV = GV_PERIV
IMPORTING
E_BUPER = GV_PERIOD.
select single low into gv_low from tvarv
where name = 'AUCIO' and type = 'P'.
if gv_low ne gv_period.
update tvarv set low = gv_period
where name = 'AUCIO' and type = 'P'.
commit work.
endif.
The thing is, use UPDATE or INSERT, MODIFY statements is considered dangerous, so I'm
look some other ways to update the table, either through FM or transaction. Can anybody
give me suggestion?
Thanks.
‎2008 Dec 03 3:29 PM
‎2008 Dec 03 3:39 PM
‎2008 Dec 03 3:42 PM
It's not documented, but if you search the forum, you'll probably find some pointers on how to use it.
Rob