Inverse object-group concept
Does Cisco have a way to write an ACL to block the opposite of an object-group?
For example, I want to write an ACL allowing all traffic other than to object-group Corp_Net...
thanks,
ttpm
Hi,
Well usually you build the required ACL from a combination of "permit" and "deny" statement. To my understanding there is no other way to use an "object-group" other than to use it as a source or destination of a permit or deny statement. The contents under the "object-group" will be used, nothing else.
I am not sure what the exact requirement in the above is but I would imagine it would be something like this
access-list ACL remark Deny all traffic to Corp_NET
access-list ACL deny ip any object-group Corp_NET
access-list ACL remark Allow all other traffic
access-list ACL permit ip any any
Naturally the above would a pretty simple example of a situation where you want to block traffic from behind some interface to a corporate network and then allow all other traffic.
- Jouni
Similar Messages
-
Notes on using Object oriented concept in ABAP
Hi ,
I want somes notes on how to use Object oriented concept in ABAP.
Thanks in advance.
ChetanHi, this may help you
OOPs ABAP uses Classes and Interfaces which uses Methods and events.
If you have Java skills it is advantage for you.
There are Local classes as well as Global Classes.
Local classes we can work in SE38 straight away.
But mostly it is better to use the Global classes.
Global Classes or Interfaces are to be created in SE24.
SAP already given some predefined classes and Interfaces.
This OOPS concepts very useful for writing BADI's also.
So first create a class in SE 24.
Define attributes, Methods for that class.
Define parameters for that Method.
You can define event handlers also to handle the messages.
After creation in each method write the code.
Methods are similar to ABAP PERFORM -FORM statements.
After the creation of CLass and methods come to SE38 and create the program.
In the program create a object type ref to that class and with the help of that Object call the methods of that Class and display the data.
Example:
REPORT sapmz_hf_alv_grid .
Type pool for icons - used in the toolbar
TYPE-POOLS: icon.
TABLES: zsflight.
To allow the declaration of o_event_receiver before the
lcl_event_receiver class is defined, decale it as deferred in the
start of the program
CLASS lcl_event_receiver DEFINITION DEFERRED.
G L O B A L I N T E R N A L T A B L E S
*DATA: gi_sflight TYPE STANDARD TABLE OF sflight.
To include a traffic light and/or color a line the structure of the
table must include fields for the traffic light and/or the color
TYPES: BEGIN OF st_sflight.
INCLUDE STRUCTURE zsflight.
Field for traffic light
TYPES: traffic_light TYPE c.
Field for line color
types: line_color(4) type c.
TYPES: END OF st_sflight.
TYPES: tt_sflight TYPE STANDARD TABLE OF st_sflight.
DATA: gi_sflight TYPE tt_sflight.
G L O B A L D A T A
DATA: ok_code LIKE sy-ucomm,
Work area for internal table
g_wa_sflight TYPE st_sflight,
ALV control: Layout structure
gs_layout TYPE lvc_s_layo.
Declare reference variables to the ALV grid and the container
DATA:
go_grid TYPE REF TO cl_gui_alv_grid,
go_custom_container TYPE REF TO cl_gui_custom_container,
o_event_receiver TYPE REF TO lcl_event_receiver.
DATA:
Work area for screen 200
g_screen200 LIKE zsflight.
Data for storing information about selected rows in the grid
DATA:
Internal table
gi_index_rows TYPE lvc_t_row,
Information about 1 row
g_selected_row LIKE lvc_s_row.
C L A S S E S
CLASS lcl_event_receiver DEFINITION.
PUBLIC SECTION.
METHODS:
handle_toolbar FOR EVENT toolbar OF cl_gui_alv_grid
IMPORTING
e_object e_interactive,
handle_user_command FOR EVENT user_command OF cl_gui_alv_grid
IMPORTING e_ucomm.
ENDCLASS.
CLASS lcl_event_receiver IMPLEMENTATION
CLASS lcl_event_receiver IMPLEMENTATION.
METHOD handle_toolbar.
Event handler method for event toolbar.
CONSTANTS:
Constants for button type
c_button_normal TYPE i VALUE 0,
c_menu_and_default_button TYPE i VALUE 1,
c_menu TYPE i VALUE 2,
c_separator TYPE i VALUE 3,
c_radio_button TYPE i VALUE 4,
c_checkbox TYPE i VALUE 5,
c_menu_entry TYPE i VALUE 6.
DATA:
ls_toolbar TYPE stb_button.
Append seperator to the normal toolbar
CLEAR ls_toolbar.
MOVE c_separator TO ls_toolbar-butn_type..
APPEND ls_toolbar TO e_object->mt_toolbar.
Append a new button that to the toolbar. Use E_OBJECT of
event toolbar. E_OBJECT is of type CL_ALV_EVENT_TOOLBAR_SET.
This class has one attribute MT_TOOLBAR which is of table type
TTB_BUTTON. The structure is STB_BUTTON
CLEAR ls_toolbar.
MOVE 'CHANGE' TO ls_toolbar-function.
MOVE icon_change TO ls_toolbar-icon.
MOVE 'Change flight' TO ls_toolbar-quickinfo.
MOVE 'Change' TO ls_toolbar-text.
MOVE ' ' TO ls_toolbar-disabled.
APPEND ls_toolbar TO e_object->mt_toolbar.
ENDMETHOD.
METHOD handle_user_command.
Handle own functions defined in the toolbar
CASE e_ucomm.
WHEN 'CHANGE'.
PERFORM change_flight.
LEAVE TO SCREEN 0.
ENDCASE.
ENDMETHOD.
ENDCLASS.
S T A R T - O F - S E L E C T I O N.
START-OF-SELECTION.
SET SCREEN '100'.
*& Module USER_COMMAND_0100 INPUT
MODULE user_command_0100 INPUT.
CASE ok_code.
WHEN 'EXIT'.
LEAVE TO SCREEN 0.
ENDCASE.
ENDMODULE. " USER_COMMAND_0100 INPUT
*& Module STATUS_0100 OUTPUT
MODULE status_0100 OUTPUT.
DATA:
For parameter IS_VARIANT that is sued to set up options for storing
the grid layout as a variant in method set_table_for_first_display
l_layout TYPE disvariant,
Utillity field
l_lines TYPE i.
After returning from screen 200 the line that was selected before
going to screen 200, should be selected again. The table gi_index_rows
was the output table from the GET_SELECTED_ROWS method in form
CHANGE_FLIGHT
DESCRIBE TABLE gi_index_rows LINES l_lines.
IF l_lines > 0.
CALL METHOD go_grid->set_selected_rows
EXPORTING
it_index_rows = gi_index_rows.
CALL METHOD cl_gui_cfw=>flush.
REFRESH gi_index_rows.
ENDIF.
Read data and create objects
IF go_custom_container IS INITIAL.
Read data from datbase table
PERFORM get_data.
Create objects for container and ALV grid
CREATE OBJECT go_custom_container
EXPORTING container_name = 'ALV_CONTAINER'.
CREATE OBJECT go_grid
EXPORTING
i_parent = go_custom_container.
Create object for event_receiver class
and set handlers
CREATE OBJECT o_event_receiver.
SET HANDLER o_event_receiver->handle_user_command FOR go_grid.
SET HANDLER o_event_receiver->handle_toolbar FOR go_grid.
Layout (Variant) for ALV grid
l_layout-report = sy-repid. "Layout fo report
Setup the grid layout using a variable of structure lvc_s_layo
Set grid title
gs_layout-grid_title = 'Flights'.
Selection mode - Single row without buttons
(This is the default mode
gs_layout-sel_mode = 'B'.
Name of the exception field (Traffic light field) and the color
field + set the exception and color field of the table
gs_layout-excp_fname = 'TRAFFIC_LIGHT'.
gs_layout-info_fname = 'LINE_COLOR'.
LOOP AT gi_sflight INTO g_wa_sflight.
IF g_wa_sflight-paymentsum < 100000.
Value of traffic light field
g_wa_sflight-traffic_light = '1'.
Value of color field:
C = Color, 6=Color 1=Intesified on, 0: Inverse display off
g_wa_sflight-line_color = 'C610'.
ELSEIF g_wa_sflight-paymentsum => 100000 AND
g_wa_sflight-paymentsum < 1000000.
g_wa_sflight-traffic_light = '2'.
ELSE.
g_wa_sflight-traffic_light = '3'.
ENDIF.
MODIFY gi_sflight FROM g_wa_sflight.
ENDLOOP.
Grid setup for first display
CALL METHOD go_grid->set_table_for_first_display
EXPORTING i_structure_name = 'SFLIGHT'
is_variant = l_layout
i_save = 'A'
is_layout = gs_layout
CHANGING it_outtab = gi_sflight.
*-- End of grid setup -
Raise event toolbar to show the modified toolbar
CALL METHOD go_grid->set_toolbar_interactive.
Set focus to the grid. This is not necessary in this
example as there is only one control on the screen
CALL METHOD cl_gui_control=>set_focus EXPORTING control = go_grid.
ENDIF.
ENDMODULE. " STATUS_0100 OUTPUT
*& Module USER_COMMAND_0200 INPUT
MODULE user_command_0200 INPUT.
CASE ok_code.
WHEN 'EXIT200'.
LEAVE TO SCREEN 100.
WHEN'SAVE'.
PERFORM save_changes.
ENDCASE.
ENDMODULE. " USER_COMMAND_0200 INPUT
*& Form get_data
FORM get_data.
Read data from table SFLIGHT
SELECT *
FROM zsflight
INTO TABLE gi_sflight.
ENDFORM. " load_data_into_grid
*& Form change_flight
Reads the contents of the selected row in the grid, ans transfers
the data to screen 200, where it can be changed and saved.
FORM change_flight.
DATA:l_lines TYPE i.
REFRESH gi_index_rows.
CLEAR g_selected_row.
Read index of selected rows
CALL METHOD go_grid->get_selected_rows
IMPORTING
et_index_rows = gi_index_rows.
Check if any row are selected at all. If not
table gi_index_rows will be empty
DESCRIBE TABLE gi_index_rows LINES l_lines.
IF l_lines = 0.
CALL FUNCTION 'POPUP_TO_DISPLAY_TEXT'
EXPORTING
textline1 = 'You must choose a line'.
EXIT.
ENDIF.
Read indexes of selected rows. In this example only one
row can be selected as we are using gs_layout-sel_mode = 'B',
so it is only ncessary to read the first entry in
table gi_index_rows
LOOP AT gi_index_rows INTO g_selected_row.
IF sy-tabix = 1.
READ TABLE gi_sflight INDEX g_selected_row-index INTO g_wa_sflight.
ENDIF.
ENDLOOP.
Transfer data from the selected row to screenm 200 and show
screen 200
CLEAR g_screen200.
MOVE-CORRESPONDING g_wa_sflight TO g_screen200.
LEAVE TO SCREEN '200'.
ENDFORM. " change_flight
*& Form save_changes
Changes made in screen 200 are written to the datbase table
zsflight, and to the grid table gi_sflight, and the grid is
updated with method refresh_table_display to display the changes
FORM save_changes.
DATA: l_traffic_light TYPE c.
Update traffic light field
Update database table
MODIFY zsflight FROM g_screen200.
Update grid table , traffic light field and color field.
Note that it is necessary to use structure g_wa_sflight
for the update, as the screen structure does not have a
traffic light field
MOVE-CORRESPONDING g_screen200 TO g_wa_sflight.
IF g_wa_sflight-paymentsum < 100000.
g_wa_sflight-traffic_light = '1'.
C = Color, 6=Color 1=Intesified on, 0: Inverse display off
g_wa_sflight-line_color = 'C610'.
ELSEIF g_wa_sflight-paymentsum => 100000 AND
g_wa_sflight-paymentsum < 1000000.
g_wa_sflight-traffic_light = '2'.
clear g_wa_sflight-line_color.
ELSE.
g_wa_sflight-traffic_light = '3'.
clear g_wa_sflight-line_color.
ENDIF.
MODIFY gi_sflight INDEX g_selected_row-index FROM g_wa_sflight.
Refresh grid
CALL METHOD go_grid->refresh_table_display.
CALL METHOD cl_gui_cfw=>flush.
LEAVE TO SCREEN '100'.
ENDFORM. " save_changes
chk this blog
/people/vijaybabu.dudla/blog/2006/07/21/topofpage-in-alv-using-clguialvgrid
Reward if helpfull.
Regards Madhu. -
Hi
Forms Builder (9.0.4.2.0) DB - 10gR2
I just want to copy one object group from one form to another.
Only thing source object group also sub classed. I tried copy/paste and drag and drop
It didn't work.
Then I tried copy from the original form which is not sub classed from any. Still didn't work.
What's the concept behind.
rgds
shabarHi Magoo
When check the subclass information of object group
there could see
Object
Object Name - Obj1
Module - Mod1
But I need the same object group (OG1) in form1 to be placed in the Form2.
When I check the Mod1 it's a another Form where it has a object group (Obj1) which is not sub class to any
How could this be done
rgds
shabar -
Hello Cisco!
I've been playing around with EEMs on and off for a few months now, and I'm enjoying it quite a bit! A recent issue at work got me thinking, and I thought I'd try and solve the problem with a new EEM. It's really quite simple, but I'm having trouble getting it to work as intended.
Device Specs:
On a CISCO881-SEC-K9 running:
Embedded Event Manager Version 4.00
Component Versions:
eem: (rel6)1.0.0
eem-gold: (rel1)1.0.2
eem-call-home: (rel2)1.0.4
Problem:
I'd like to create an EEM that checks the IP of a website a few times a day, and cross references the results with the IPs listed in an object group. If the new IP isn't listed, it will add it to the object group. If it is detected, it won't do anything. (I have this e-mailing either way right now, to assist me with debugging)
Reasoning:
I'd like to see if this is something I can do with an EEM. It would be nice to have something dynamically configured to make updates like this. At the end of the day, It mimics a feature on some firewalls. I'd like for this to get around the limitations of a static ACL entry. I haven't looked into TCL scripting, as It would be a new language that I'd have to learn. The beauty of EEM, is that it builds off of what a technician already knows. If you understand IOS, EEM is relatively easy to pickup and run with.
Side Note: If you see something in my script that could be consolidated, or just doesn't make much sense; please let me know. There is a really good chance that I don't know of the alternative method. This is especially true in terms of my regular expression knowledge. That's an ongoing battle :)
Thanks in advance everyone.
Your assistance and constructive criticism is more than welcome and is greatly appreciated.
Here is what I have right now:
event manager applet update_my_object_group
event timer cron cron-entry "* * * * *" maxrun 9999999
action 1.0 cli command "enable"
action 1.1 cli command "ping www.google.com"
action 1.2 wait 5
action 1.3 regexp "to ([0-9.]+)," "$_cli_result" match new_ip
action 1.4 cli command "show object-group self_building"
action 1.5 regexp "([0-9.]+)" "$_cli_result" match current_ips
action 2.0 if $new_ip ne "$current_ips"
action 3.0 cli command "conf t"
action 3.1 cli command "object-group network self_building"
action 3.3 cli command "host $new_ip"
action 3.4 cli command "end"
action 3.5 cli command "show object-group self_building"
action 3.6 regexp "([0-9.]+)" "$_cli_result" match new_current_ips
action 4.1 mail server "$_email_server" to "$gmail" from "$_email_from" subject "EEM: Successfully Updated Object Group" body "Added new IP: $new_ip\n to Object Group: self_building\n $current_ips"
action 5.0 else
action 5.1 mail server "$_email_server" to "$gmail" from "$_email_from" subject "EEM: Object Group Failure" body "I couldn't update the object group: self_building. Debug:\n New IP: $new_ip\nCurrent: $current_ips\nWhat it is now: $new_current_ips"
action 5.2 end
Here is an example I built up for a single ACL. Same concept, just a single line gets updated. I was using this as a reference for my object group script.
event manager applet update_my_acl
event timer cron cron-entry "0 * * * *" maxrun 9999999
action 1.0 cli command "enable"
action 1.1 cli command "ping www.msn.com"
action 1.2 wait 5
action 1.3 regexp "to ([0-9.]+)," "$_cli_result" match new_ip
action 1.4 cli command "show access-lists | sec test_acl"
action 1.5 regexp "10 permit tcp any host ([0-9.]+) eq www" "$_cli_result" match current_ip
action 2.0 if $new_ip ne "$current_ip"
action 3.0 cli command "conf t"
action 3.1 cli command "ip access-list extended test_acl"
action 3.2 cli command "no 10"
action 3.3 cli command "10 permit tcp any host www.msn.com eq www"
action 3.4 cli command "end"
action 4.0 cli command "show access-lists | sec test_acl"
action 4.1 mail server "$_email_server" to "$_email_to" from "$_email_from" subject "EEM: Successfully Updated ACL" body "New IP: $new_ip\nOld IP: $current_ip"
action 5.0 else
action 5.1 mail server "$_email_server" to "$_email_to" from "$_email_from" subject "EEM: ACL NOT updated" body "New IP: $new_ip\nOld IP: $current_ip"
action 5.2 endThanks for the review!
Well, it's technically "working", but not in the way that it's designed. It checks the object group, but it only finds the first IP listed. I'll provide you with the object group it's generated so far, and what I'm receiving in my e-mails.
(I don't think my regular expressions are working correctly.)
The Object Group:
object-group network self_building
host 10.9.8.20
host 74.125.225.114
host 173.194.46.115
host 74.125.225.148
host 173.194.46.116
host 173.194.46.112
host 74.125.225.81
host 74.125.225.83
host 173.194.46.84
host 74.125.225.17
host 74.125.225.20
host 173.194.46.80
host 74.125.225.19
host 173.194.46.83
host 173.194.46.114
host 74.125.225.116
host 74.125.225.51
host 74.125.225.52
host 173.194.46.113
host 74.125.225.145
host 74.125.225.144
host 74.125.225.49
host 74.125.225.82
host 74.125.225.146
host 74.125.225.84
host 74.125.225.112
host 173.194.46.82
host 173.194.46.81
host 74.125.225.18
Here are the successful e-mails sent to me. As you'll see, I've had the EEM include the $current_ips in the e-mail. This should be all of the IPs in the group, but it's just the first one listed (found). So, because it doesn't match, it adds the newly found IP to the group.
But, as you can see in my emails, that IP has been found before and added already. The desired behavior is it for it to see that the entry already exists, and not apply it.
Edit: Thought this would help:
Step 1: Ping www.google.com.
Step 2: Use regular expression to capture the IP found.
Step 3: Run a show command, and find all of the IPs currently listed inside the object group: self_building
Step 4: Cross reference the newly found IP, with the IPs found in the object group.
Step 5: If it's already there, then discard it and end the EEM.
Step 5 (a) If it's not there, then add it to the object group, and then end the EEM.
Thanks again! -
Need help to modify a report written using Field-Groups Concept. - Part1
Hello ABAP Experts,
I need your help to modify the following report with following requirement as I have least knowledge
about the field-group concept. Thats is the reason, I am pasting the whole code. As it is part of our
production requirement. I really appreciate your help, If its sent modifying the code required.
Modification required in the report.
To allow the sales representatives to see billed shipments and open orders for the current month.
1) Selection Screen Changes:
u2022 Add selection by Sales group and Customer group
u2022 Add sort by: 3. Ship-to / Material
u2022 Add another selection box
[ ] Open Orders and Shipments with the current month
2) For the new selection box, subtotal sales quantity and delivery quantity.
If delivered, make the sales quantity zero in the subtotal
Current report displays, in Selection Screen
Sales org:
Person Name:
Material:
Plant:
Sales Office:
Ship to Name:
Ship to Number:
Sorts Report by : 1. Person Name 2. Material
Check Boxes : 1. Open Orders 2. Delayed Orders.
report zorder LINE-SIZE 170
LINE-COUNT 58
MESSAGE-ID zv
NO STANDARD PAGE HEADING.
TABLES:
cdhdr, "Change Doc Header
cdpos, "Change Doc Item
kna1, "Customer master
likp, "Delivery Header
lips, "Delivery Item
*lips, "Delivery Item
zvbpa_lfa1, "Vendor Master
makt, "Material Desc
t001w, "Plant
tvkbt, "Sales Office
tvko, "Sales Organizations
vbak, "Sales Header
vbap, "Sales Item
zvvbak, "Sales Hdr - Time calc
vbup, "Item status
vbep, "Sales Schedule Line
vbfa, "Flow documents
vbpa, "Partners
vbrk, "Billing Header
vbrp. "Billing Item
SELECT-OPTIONS:
s_vkorg FOR vbak-vkorg OBLIGATORY,
s_ernam FOR vbak-ernam,
s_matnr FOR vbap-matnr,
s_werks FOR vbap-werks,
s_vkbur FOR vbak-vkbur,
s_name1 FOR kna1-name1,
s_kunnr FOR kna1-kunnr.
SELECTION-SCREEN ULINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(49) text-c20.
PARAMETERS: p_sort TYPE n DEFAULT '1'.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 19(40) text-022.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 19(40) text-023.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 19(40) text-024.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN COMMENT 19(40) text-070.
SELECTION-SCREEN ULINE.
SELECTION-SCREEN BEGIN OF BLOCK b20 WITH FRAME.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS:p_open AS CHECKBOX DEFAULT 'X'.
SELECTION-SCREEN COMMENT 5(48) text-072.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS:p_delay AS CHECKBOX DEFAULT 'X'.
SELECTION-SCREEN COMMENT 5(48) text-073.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN END OF BLOCK b20.
DATA:
vbeln(11), "Document number
cancel_dt TYPE d, "Cancellation Date
BEGIN OF tabkey, "Tabkey
mandant LIKE sy-mandt,
vbeln LIKE vbap-vbeln,
posnr LIKE vbap-posnr,
END OF tabkey,
name1_sp1 LIKE lfa1-name1, "Sales Carrier Name
name1_sp2 LIKE lfa1-name1, "Delivery Carrier Name
datum-1 TYPE d, "Current Dt Less 1
datum-14 TYPE d, "Current Dt Less 14
datum-90 TYPE d, "Current Dt Less 90
rpt_hdr1(170), "Report Header 1
rpt_hdr2(170), "Report Header 2
rpt_hdr3(170), "Report Header 3
cb_hdr1(170), "Control Break Header 1
line_pos1 TYPE i, "Line Print Position HDR1
line_pos2 TYPE i, "Line Print Position HDR2
line_pos3 TYPE i, "Line Print Position DET2
status, "Order Status
open, "Open Order
delayed VALUE 'D', "Delayed Order
v_comp(30). "Company Text Field
DATA: v_flagh2. " Flag for header 2 & 3
DATA: ls_comwa LIKE vbco6. "Structure for flow information
DATA: t_vbfa_tab TYPE STANDARD TABLE OF vbfa WITH HEADER LINE."Itab
for flow information
data: g_trans_id type vttk-tdlnr. "get transport id from flow
information
data v_sales_org_cpimex type vkorg value '3300'.
FIELD-GROUPS:
header,
order.
INSERT
status "Status
vbak-vkbur "Sales Office
vbak-ernam "Created By
kna1-kunnr "Customer
kna1-name1 "Customer Name
vbap-matnr "Material
vbap-werks "Plant
vbep-lddat "Load Dt
vbap-vbeln "Sales Document
INTO header.
INSERT
kna1-ort01 "City
kna1-regio "Region
likp-traid "Transport ID
lips-vbeln "Delivery Document
lips-ntgew "Net Wt
lips-gewei "Unit of Weight
vbap-kwmeng "Order Qty
vbap-vrkme "Sales Unit
vbak-bstnk "Customer PO
vbak-erdat "Sales Create Dt
vbak-ihrez "PO Release
vbak-vdatu "Req Delivery Dt
vbak-vzeit "Req Delivery Time
vbfa-vbeln "Goods issue doc
vbrk-vbeln "Billing Document
name1_sp1 "Sales Carrier
name1_sp2 "Delivery Carrier
INTO order.
INITIALIZATION.
AT SELECTION-SCREEN.
IF NOT p_sort BETWEEN 1 AND 2.
MESSAGE e022 WITH p_sort.
ENDIF.
* Report 1 or more of cancelled, delayed or open
IF p_open IS INITIAL AND
p_delay IS INITIAL.
MESSAGE e023.
ENDIF.
START-OF-SELECTION.
* Load Company Name
WRITE 'XYZ INC'(000) TO v_comp.
* Calculate Date Range
datum-1 = sy-datum - 1.
datum-14 = sy-datum - 14.
datum-90 = sy-datum - 90.
* Compose Parameter Header
PERFORM parm_hdr.
** Compose Report Header
v_flagh2 = 1.
PERFORM data_selection.
END-OF-SELECTION.
* Determine Sort
CASE p_sort.
WHEN 1.
SORT BY status vbak-ernam kna1-name1 kna1-kunnr
vbep-lddat vbap-vbeln.
WHEN 2.
SORT BY status vbap-matnr vbap-werks vbep-lddat
vbap-vbeln.
ENDCASE.
LOOP.
AT NEW status.
CASE status.
WHEN delayed.
WRITE 'Delayed Orders'(061) TO rpt_hdr1.
WHEN OTHERS.
WRITE 'Open Orders'(062) TO rpt_hdr1.
ENDCASE.
NEW-PAGE.
ENDAT.
AT NEW vbak-ernam.
IF p_sort = 1.
CLEAR cb_hdr1.
WRITE 'CAA:'(064) TO cb_hdr1.
WRITE vbak-ernam TO cb_hdr1+5.
NEW-PAGE.
ENDIF.
ENDAT.
AT NEW vbap-matnr.
IF p_sort = 2.
CLEAR makt.
SELECT SINGLE * FROM makt
WHERE spras = sy-langu AND
matnr = vbap-matnr.
CLEAR cb_hdr1.
WRITE 'Material:'(042) TO cb_hdr1.
WRITE vbap-matnr TO cb_hdr1+10.
WRITE makt-maktx TO cb_hdr1+21.
NEW-PAGE.
ENDIF.
ENDAT.
AT NEW vbap-werks.
AT order.
RESERVE 3 LINES.
SKIP 1.
NEW-LINE.
* Indicate new open item
WRITE vbap-vbeln TO vbeln.
* Find Transport ID
* Fill the structure LS_COMWA
ls_comwa-mandt = sy-mandt.
ls_comwa-vbeln = vbap-vbeln.
CALL FUNCTION 'RV_ORDER_FLOW_INFORMATION'
EXPORTING
comwa = ls_comwa
TABLES
vbfa_tab = t_vbfa_tab.
IF sy-subrc EQ 0.
READ TABLE t_vbfa_tab WITH KEY vbtyp_n = '8'.
IF sy-subrc EQ 0.
SELECT SINGLE tdlnr INTO g_trans_id
FROM vttk WHERE tknum = t_vbfa_tab-vbeln.
CONDENSE g_trans_id.
ENDIF.
ENDIF.
IF vbak-erdat >= datum-1.
vbeln+10 = 'N'.
ENDIF.
CASE p_sort.
WHEN 1.
WRITE 1 vbak-vkbur.
WRITE 8 kna1-name1.
WRITE 44 vbeln.
WRITE 56 vbap-matnr.
WRITE:
75 vbap-kwmeng LEFT-JUSTIFIED,
vbap-vrkme,
100 vbak-bstnk,
vbak-ihrez,
134 vbak-vdatu,
vbak-vzeit,
154 vbep-lddat.
WRITE 166 vbap-werks.
NEW-LINE.
WRITE:
5 kna1-ort01,
41 kna1-regio.
IF name1_sp2 IS INITIAL.
WRITE:
45 name1_sp1,
ELSE.
WRITE 45 name1_sp2.
IF name1_sp1 = name1_sp2.
WRITE ' '.
ELSE.
WRITE '*'.
ENDIF.
ENDIF.
IF vbak-vkorg = v_sales_org_cpimex .
WRITE 81 g_trans_id.
ELSE.
WRITE 81 likp-traid.
ENDIF.
WRITE:
102 lips-vbeln,
115 lips-ntgew NO-ZERO LEFT-JUSTIFIED,
lips-gewei,
140 vbfa-vbeln,
152 vbrk-vbeln.
WHEN 2.
WRITE 1 vbak-ernam.
WRITE 14 vbak-vkbur.
WRITE 21 kna1-name1.
WRITE 57 vbeln.
WRITE:
69 vbap-kwmeng LEFT-JUSTIFIED,
vbap-vrkme,
92 vbak-bstnk,
vbak-ihrez,
126 vbak-vdatu,
vbak-vzeit,
146 vbep-lddat.
WRITE 162 vbap-werks.
NEW-LINE.
WRITE:
5 kna1-ort01,
41 kna1-regio.
IF name1_sp2 IS INITIAL.
WRITE:
45 name1_sp1,
ELSE.
WRITE 45 name1_sp2.
IF name1_sp1 = name1_sp2.
WRITE ' '.
ELSE.
WRITE '*'.
ENDIF.
ENDIF.
IF vbak-vkorg = v_sales_org_cpimex .
WRITE 81 g_trans_id.
ELSE.
WRITE 81 likp-traid.
ENDIF.
WRITE:
102 lips-vbeln,
115 lips-ntgew NO-ZERO LEFT-JUSTIFIED,
lips-gewei,
140 vbfa-vbeln,
152 vbrk-vbeln.
ENDCASE.
ENDAT.
ENDLOOP.
* FORM PARM_HDR *
FORM parm_hdr.
WRITE 'Program selections'(101) TO rpt_hdr1.
WRITE 'Sign'(102) TO rpt_hdr1+29.
WRITE 'Option'(103) TO rpt_hdr1+34.
WRITE 'From'(104) TO rpt_hdr1+41.
WRITE 'To'(105) TO rpt_hdr1+77.
ENDFORM. "PARM_HDR
* FORM RPT_HDR *
FORM rpt_hdr.
CASE p_sort.
WHEN 1. "When sort by CAA
WRITE 1'SOff'(066).
WRITE 8'Customer'(009).
WRITE 44'Sales Doc'(010).
WRITE 56'Material'(031).
WRITE 75'Sales Qty'(011).
WRITE 100'Customer PO'(012).
WRITE 134'Req.Del.Dt & Tm'(014).
WRITE 154'Load Dt'(015).
WRITE 166'Plnt'(016).
NEW-LINE.
WRITE 5'City'(017).
WRITE 41'Reg'(069).
WRITE 45'Carrier'(018).
WRITE 81'Transport ID'(019).
WRITE 102'Dlvry Doc'(021).
WRITE 115'Dlvry Qty'(025).
WRITE 140'PGI Doc'(026).
WRITE 152'Billng Doc'(027).
WHEN 2. "When sort by Material
WRITE 1'Created By'(008).
WRITE 14'SOff'(066).
WRITE 21'Customer'(009).
WRITE 57'Sales Doc'(010).
WRITE 69'Sales Qty'(011).
WRITE 92'Customer PO'(012).
WRITE 126'Req.Del.Dt & Tm'(014).
WRITE 146'Load Dt'(015).
WRITE 162'Plnt'(016).
NEW-LINE.
WRITE 5'City'(017).
WRITE 41'Reg'(069).
WRITE 45'Carrier'(018).
WRITE 81'Transport ID'(019).
WRITE 102'Dlvry Doc'(021).
WRITE 115'Dlvry Qty'(025).
WRITE 140'PGI Doc'(026).
WRITE 152'Billng Doc'(027).
ENDCASE.
ENDFORM. "RPT_HDR
INCLUDE zrpthdri.
WRITE:
/ rpt_hdr1.
ULINE.
IF v_flagh2 <> 0.
PERFORM rpt_hdr. "Write secondary header
ULINE.
* Control Break Header
WRITE / cb_hdr1.
ENDIF.
Continued in Part-2
Thanks a ton in advance.
Mythili Sharma
Edited by: Mythili sharma on Mar 30, 2009 3:32 AM
Edited by: Rob Burbank on Mar 30, 2009 10:46 AMHello ABAP Experts,
I need your help to modify the following report with following requirement as I have least knowledge about the field-group concept. Thats is the reason, I am pasting the whole code. As it is part of our production requirement. I really appreciate your help, If its sent modifying the code required.
Modification required in the report.
To allow the sales representatives to see billed shipments and open orders for the current month.
1) Selection Screen Changes:
u2022 Add selection by Sales group and Customer group
u2022 Add sort by: 5. Ship-to / Material
u2022 Add another selection box
[ ] Open Orders and Shipments with the current month
2) For the new selection box, subtotal sales quantity and delivery quantity.
If delivered, make the sales quantity zero in the subtotal
Current report displays, in Selection Screen
Sales org:
Person Name:
Material:
Plant:
Sales Office:
Ship to Name:
Ship to Number:
Sorts Report by :
1. Person Name
2. Material
3. Plant
4. Sales Office
Check Boxes :
1. Open Orders
2. Delayed Orders
3.Cancelled Orders
PLEASE DOWNLOAD THE COMPLETE REPORT FROM THE FOLLOWING LINK
<< Link removed >>
It would be a great help, If the program is modified according to the requirement and snd it back through send space and send link, even if u send the necessary changes to be done in the report is also appreciable.
Thanks a ton in adanvce
Mythili
I wanted to close this thread as I could not put my question in a proper format. So please reply in the new thread which is posted.
Edited by: Mythili sharma on Mar 30, 2009 2:16 PM
Edited by: Rob Burbank on Mar 30, 2009 4:24 PM -
Hi all, I feel confuse on object oriented.
Basic, I get change to developer some online form. I use java bean , Servlet, JSTL and Mysql. In my java bean I only have the attribute set and get pattern. I just wonder I put my delete , search and update action on Servlet , not in the java bean , is that means that Is not object oriented enough? How to improve it ?
thank you!Thank you for the reply, I did use some of the Spring in my Project, but only limit in flower control , such as simple spring + acegi , a lot of control still in servlet. I also try some other new stuff like display tag , but that only work on if your jsp page is out of the WEB-INF. I also go through some tutorials on JSF , but not time to figure out how JSF work with acegi yet.
1 mention the display tag and JSF just try to explain, I looking for a new framework. But don?t want the whole framework to tire me up. For example in simple servlet I can use ? /WEB-INF/ + target to send my flower to any JSP page depend on the link that I click , but I don?t how to handle it spring. May be I did not get the real concept of spring yet. I looking for some framework that allow me to use new technology , but still allow me to use some old technology , like servlet then I can finish my project on time.
But what is the relation between web framework and object oriented concept?? -
Implementing "object-group service"
Running 8.2(3) on an ASA 5510
I have created the two following object groups.
object-group service gatewayTCP tcp
port-object eq 88
port-object eq 135
port-object eq 445
port-object eq ldaps
port-object eq 3268
port-object eq 3269
object-group service gatewayTCP-UDP tcp-udp
port-object eq domain
port-object eq 389
port-object eq 464
port-object range 49152 65535
I have run into an issue with "domain" working in the tcp-udp type. The following access-list does not work without explicitly calling out "domain" for both TCP and UDP. Everywhere I looked I appear to be doing it right so what am I missing. Does "permit tcp" need to be "permit ip" to cover both tcp and udp? I found one article with someone suggestiong just make it "permit tcp" and it will work. Not in a position to test at the moment so figured I'd ask here. Want to be sure I'm not getting bit anywhere else related to these object groups in case I am not implementing them correctly?
access-list dmzAccess extended permit tcp host 172.26.11.10 host 10.16.11.203 object-group gatewayTCP
access-list dmzAccess extended permit tcp host 172.26.11.10 host 10.16.11.203 object-group gatewayTCP-UDP
Is this a bug with service object groups? Is there some place I need to enable this feature?Hi,
Have you tried configuring it like this
object-group service GATEWAY-SERVICES
service-object tcp eq 88
service-object tcp eq 135
service-object tcp eq 445
service-object tcp eq ldaps
service-object tcp eq 3268
service-object tcp eq 3269
service-object tcp eq 53
service-object udp eq 53
service-object tcp eq 389
service-object udp eq 389
service-object tcp eq 464
service-object udp eq 464
service-object tcp range 49152 65535
service-object udp eq 49152 65535
access-list dmzAccess permit object-group GATEWAY-SERVICES host 172.26.11.10 host 10.16.11.203
I am not sure if it was only after software 8.3+ that the command under the actual "object-group" was of format "service-object tcp source" / "service-object tcp destination" (or the same for UDP)
- Jouni -
Object-group with network-object containing an IP address range
Hello,
Does the ASA treat an object-group with a network-object containing a range of IP addresses as a netmask? For example, I can apply this configuration without the ASA throwing any errors though the configuration calls for a 'net mask':
object-group network test
network-object 192.168.0.0 192.168.63.255
network-object-group mode commands/options:
A.B.C.D Enter an IPv4 network mask
sh run ob id test
object-group network test
network-object 192.168.0.0 192.168.63.255
I found that in the documentation it requires a netmask as oppose to a range. Is this a bug in the code? I am running code version 8.0(5)23 on a 5520. If this is not a bug how does the ASA treat this type of configuration when applied to an access list? When I ran a quick packet trace and denied access from that range it looks like the ASA doesn't read that configuration properly. Thank you.
-JohnHello,
Thank you for your replies. In code version 8.0(5)23, it appears I am able to define a "range" of IP addresses as in:
192.168.0.0 192.168.63.255 as opposed to defining a range with a netmask like 192.168.0.0 255.255.192.0.
With the "range" of IP address applied to the "object-group network test" with sub command "network-object 192.168.0.0 192.168.63.255" the ASA does not pick up on said "range" when this object group is applied to a DENY access list. It only reads it properly when the netmask is attached, which is the correct configuration, as in: "network-object 192.168.0.0 255.255.192.0".
To clarify, I mean range as in 192.168.0.0 - 192.168.63.255.
Hope this helps to understand. I am just curious as to why this is even able to be applied in such a way or if it is a bug in this particular code version? I can also confirm that this can be done in code version 8.4(2). See below snippets of my configuration in the 8.4(2) code version:
access-list 101 line 3 extended deny ip object-group testmask any 0x577f55a8
access-list 101 line 3 extended deny ip 192.168.0.0 192.168.63.255 any (hitcnt=0) 0x0623b0c4
access-list 101 line 4 extended permit tcp any any eq 89 (hitcnt=1) 0x36f1e5cd
Packet trace results in allowing the "range" of IP address:
Result:
input-interface: outside
input-status: up
input-line-status: up
output-interface: dmztest
output-status: up
output-line-status: up
Action: allow
Now with the "correct" configuration:
access-list 101 line 3 extended deny ip object-group testmask any 0x577f55a8
access-list 101 line 3 extended deny ip 192.168.0.0 255.255.192.0 any (hitcnt=1) 0xa31c6bbd
access-list 101 line 4 extended permit tcp any any eq 89 (hitcnt=1) 0x36f1e5cd
Result:
input-interface: outside
input-status: up
input-line-status: up
output-interface: dmztest
output-status: up
output-line-status: up
Action: drop
Drop-reason: (acl-drop) Flow is denied by configured rule
Thank you.
-John -
Subclass webutil object group problem
Hi,
I am using 10g form.
I download the webutil demo and got a form called WU_TEST_106 in which there is
a object group called WEBUTIL.
Then I create a new form and drag the object group WEBUTIL of the form
WU_TEST_106 to the object group of the new form and choose 'subclass'.
When I check the content of the WEBUTIL data block in the new form, there
is no items there.
There should be some bean area such as WEBUTIL_FILE_FUNCTIONS and
WEBUTIL_HOST_FUNCTIONS etc.
Anyone can help ?
IvanDo not subclass WEBUTIL from another form. In folder <DevSuiteHome>\forms there should exist file webutil.olb. Open this file directly in Form Builder using
File | Open
and subclass the objects contained within.
Eric Adamson
Lansing, Michigan -
ORA-23326: object group "PUBLIC","REPG" is quiesced
I am using Oracle 9i Enterprise Manager.
I have two servers with databases isb.city and rwp.rawat. I completed the whole process of Multimaster Replication. I am working on the SCOTT schema as test. Right now I am working on LAN.
Two servers are connected with each other. I am facing two problems:
1) When I try following command, it shows no rows on both servers:
SQL>SELECT DBLINK FROM DBA_REPSITES WHERE GNAME = 'repg';
no rows selected
2) When I try to insert data in the tables, it doesn't allow it and give following:
ORA-23326: object group "PUBLIC","REPG" is quiesced
I already made changes in init.ora and changed spfile file as well accordingly.
What is wrong with my setup?Try this:
1. SELECT DBLINK FROM DBA_REPSITES WHERE GNAME = 'REPG';
2. You should change init.ora or spfile (database is using one of them):
show parameter pfile will show you if you are using spfile or not
execute RESUME_MASTER_ACTIVITY to unquisce replication group
Best Regards
Krystian Zieja / mob -
Is it possible to nest object groups in froms?
Title says it all, but to explain further - I'd like to create some object groups and the objects I'd like to include within these groups are themselves objects groups.
Is that possible?No - But you could subclass an object group and then add extra children to it.
-
Need documents of ABAP Object Oriented concepts
Hi,
I need materials on ABAP Object Oriented Concepts to learn.
If you have any good documents which covers all the topics of ABAP OO then please send me to [email protected]
Thanks in advance.
Regards,
ChandruChandra,
Very good sites with docs.
http://esnips.com/doc/2c76dc57-e74a-4539-a20e-29383317e804/OO-abap.pdf
http://esnips.com/doc/92be4457-1b6e-4061-92e5-8e4b3a6e3239/Object-Oriented-ABAP.ppt
http://esnips.com/doc/448e8302-68b1-4046-9fef-8fa8808caee0/abap-objects-by-helen.pdf
http://esnips.com/doc/39fdc647-1aed-4b40-a476-4d3042b6ec28/class_builder.ppt
Pls. reward if useful... -
I have an ASA 5510 and have just started using object-groups which are super handy in theory, but not working in reality. I have a service object-group with a mix of tcp, icmp, and udp ports. Let's call it Sample_Port_Group. I'm trying to apply it to my dmz_access_in ACL. Here's the line giving me problems:
access-list dmz_access_in extended permit object-group Sample_Port_Group 192.168.1.1 any
The asa throws up an error between 192.168.1.1 and any. When I put up a ? after Sample_Port_Group, it gives me the option of putting in an IP address, any, etc. When I put in a ? after 192.168.1.1, it only gives me the option of putting in an IP address.
Going off these posts:
- http://www.cisco.com/en/US/products/hw/vpndevc/ps2030/products_tech_note09186a00800d641d.shtml
- http://www.cisco.com/en/US/docs/security/asa/asa81/config/guide/nwaccess.html
Those posts gave me the impression my line was possible, especially the "access-list outsideacl extended permit object-group myaclog interface inside any" line, which is at the end of the 2nd article linked.
What am I doing wrong?
Thanks in advance for any help.Hi Adam!
You are doing it right, you are just missing on little keyword.
The line should be as this:
access-list dmz_access_in extended permit object-group Sample_Port_Group host 192.168.1.1 any
or you could specify the subnetmask as:
access-list dmz_access_in extended permit object-group Sample_Port_Group 192.168.1.1 255.255.255.255 any
Regards -
CSCut57898 - C897 ACL object-group leak/miss for BGP tcp 179 / causing deny
We appear to be seeing this bug, or something very similar, on a 3845 running 15.1(4)M9 (c3845-adventerprisek9-mz.151-4.M9.bin), and a 3945 running 15.1(1)T (c3900e-universalk9-mz.SPA.151-1.T.bin). On both platforms traffic that should be (and most often is) matching an object-group ACE is sometimes "falling through" that ACE and hitting ACEs below the object-group based ACE that it should have matched. Depending on the ACEs in question, this sometimes results in traffic that should be permitted falling into a later deny, or more troubling, traffic that should be denied falling into a subsequent permit.
I am particularly curious to know if this may be related to http://tools.cisco.com/security/center/viewAlert.x?alertId=37423 and https://tools.cisco.com/bugsearch/bug/CSCun21071 and whether there is a fix.
Anyone who is working on this is welcome to contact me directly. I have crystal clear logging of traffic falling through ACEs on these systems, and I would be happy to assist in any way I can. I would really like to get this problem solved, it is causing me a great deal of grief and frustration.We appear to be seeing this bug, or something very similar, on a 3845 running 15.1(4)M9 (c3845-adventerprisek9-mz.151-4.M9.bin), and a 3945 running 15.1(1)T (c3900e-universalk9-mz.SPA.151-1.T.bin). On both platforms traffic that should be (and most often is) matching an object-group ACE is sometimes "falling through" that ACE and hitting ACEs below the object-group based ACE that it should have matched. Depending on the ACEs in question, this sometimes results in traffic that should be permitted falling into a later deny, or more troubling, traffic that should be denied falling into a subsequent permit.
I am particularly curious to know if this may be related to http://tools.cisco.com/security/center/viewAlert.x?alertId=37423 and https://tools.cisco.com/bugsearch/bug/CSCun21071 and whether there is a fix.
Anyone who is working on this is welcome to contact me directly. I have crystal clear logging of traffic falling through ACEs on these systems, and I would be happy to assist in any way I can. I would really like to get this problem solved, it is causing me a great deal of grief and frustration. -
Object-groups created with the CLI don't appear in the ANM Config>Devices>Security>Object Groups as they should and ACLs using these groups are displayed incorrectly. SYNC and upgrading to ANM v2.1 hasn't resolved the issue. Object-groups created with ANM don't have this problem. Is this a bug or is there some other way to import/sync the config to ANM?
Hello,
No, haven't heard a thing yet. I have learned a bit more though about the symptoms. Some contexts aren't affected by the bug at all. The ACL using the group and the group itself was imported and is displayed correctly by ANM. But they only have a couple of simple object groups and a single line ACL referencing the groups, while the broken contexts have many large object groups and large ACLs. So, maybe it's related to size or complexity.
I plan to open a TAC Case when I get a minute. I use the CLI to build the contexts and don't use the GUI much, but other people who maintain the servers do.
Maybe you are looking for
-
How difficult can it be to get a phone line instal...
First of all, for a communications company, BT are shockingly bad at communicating with their customers! We ordered a home move for our phone line and Infinity services back at the start of Dec, and had an activation date of 19th Dec. The engineer du
-
Can someone please help my iphone 4 is stuffed after ios 7.1 update?
Hi everyone I have a friend who accidentally press on the new ios 7.1 update and now my iphone 4 is stuffed up. My list of problems are: Home button doesn't even work it use to work fine with ios 7.0.6 The battery drains so easily It keeps telling me
-
The backups mentioned above only back up NEW photos I took and put them on my cloud. My PC wouldn't recognize my phone without updating to IOS 7. I did some chores and came back to my phone and I have an error message on my iPhone screen. When I l
-
Problems with .pdf as an email attachment
All of a sudden, I am having problems attaching my email newsletter (5 pages .pdf combined in one), this is in Yahoo email or gmail. I've been doing it for a few years with no problem. It just won't load.
-
How to display a button with an icon?
Hi, I'd like to display an SAP-icon on a button. In this thread How can I show an Icon in the tapStripItem-title? Thomas Jung gave the following example: > I don't know if this definetely works with tabstrips > items but it does work with buttons and