RSSCategory: BC – ABAP

Edit Tables Directly in SE16 by Using SE16N

| August 12, 2009 | 0 Comments

If you need to edit one table directly without using one SM30 view do these steps: Go to SE16N; Insert table name, press enter; In transaction box on top write “&SAP_EDIT” and press enter; Press F8 and insert line and delete line button will be available. Please be very carefull when doing this, it may [...]

Continue Reading

Default Values for Sales Order by User

| August 6, 2009 | 0 Comments

Sometimes you need to assign default values to one user when entering the sales order. Todo so go to SU01, enter user, click modify and click parameters. Here you have: PID                    Parameter                  Short Description AAT                         ZOR                               Order Type SPA                         0001                               Division VKO                           03                         Sales Organization VTW                          01                         Distribution Channel

Continue Reading

Get user email from RH data in SAP

| July 23, 2009 | 1 Comment

When sending one email, sometimes you use SY-UNAME as reference so this is the desired select: select single usrid usrid_long  from pa0105 where pernr eq SY-UNAME and subty eq 9003 (ASK HR Manager) and begda le sy-datum and endda ge sy-datum. if usrid is empty use usrid_long endselect. And it’s this, any doubts just post

Continue Reading

Send Email SAP Function to External address or distribution list

| July 22, 2009 | 0 Comments

When you need to trigger email from user exit or from your own program you can use this function. You can send it to single email destination or to a distribution list ( SBWP Transaction ). This will only work if SCOT transaction is correctly configured, and this must be made by a System Administrator. Here goes the [...]

Continue Reading

Addin a check box to a SAP Table

| July 16, 2009 | 1 Comment

When you want to make a View of a table and get a check box in one of the fields, tou can use the data element CHKBOX. By doing so, when you use the Table Maintenance Generator, a check box will be added to the maintenance view. Any doubts? Please Comment

Continue Reading

Avoid Deletion of Sales Order and Delivery (VA02 and VL02N )

| June 22, 2009 | 0 Comments

If you want to block these document deletion option by user exit the is a solution. You can simply get to MV45AFZZ (sales order) and MV50AFZ1 (delivery) and place the following code in the FORM userexit_delete_document:  MESSAGE ‘Document delete not allowed’ TYPE ‘I’. CALL TRANSACTION ‘Va01′ AND SKIP FIRST SCREEN. Change the transaction to what [...]

Continue Reading

Message Output access sequence by Shipping Point (INVOICE RD00)

| May 19, 2009 | 2 Comments

When you need to create access sequences. Using fields that are not available in field catalog you can append them to the VBRK Table. For Instance use ZZVSTEL to append to VBRK and then you need to make them available in other tables so you can create an access sequence. These tables are KOMK, KOMG [...]

Continue Reading

Select for all entries

| April 30, 2009 | 1 Comment

When you need to access many records from one internal table is better to use select for all entries. instead of doing this loop at internal-table select * from table where……. endloop. it’s better to SELECT * FROM bkpf INTO CORRESPONDING FIELDS OF TABLE it_bkpf FOR ALL ENTRIES IN it_vbrk WHERE bukrs = it_vbrk-bukrs AND [...]

Continue Reading

Add SAP External Database Connection (DBCO)

| April 28, 2009 | 0 Comments

When you want to set up external database connection, you need to use DBCO Transaction. When using DBCO you are setting up the properties for an external database. REPORT ztest. DATA: BEGIN OF wa, ncust(40) TYPE c, name(35) TYPE c, END OF wa. DATA: dbs TYPE dbcon-con_name. DATA: con(20) TYPE c. DATA : ls_wa LIKE [...]

Continue Reading

Difference between select single and up to 1 row

| April 21, 2009 | 0 Comments

The ‘SELECT SINGLE’ statement selects the first row in the database that it finds that fulfils the ‘WHERE’ clause If this results in multiple records then only the first one will be returned and therefore may not be unique. The ‘SELECT ….*….. UP TO 1 ROWS’ statement is subtly different. The database selects all of the [...]

Continue Reading