Rule base optimezer

Hello,
Do you guys have any idea about this issue.
I am wondering!....In our new server (10g on AIX) the Rule Based optimizer mode shows the cost.
Is it possible..? Today only I found that one... few days back its not shown the cost.
Actually... it is not suppose to show the cost when you use the Rule based optimizer. Am I correct?

Hi,
>>the Rule Based optimizer mode shows the cost.
Where did you get this information from? I think that it wouldn't happen ... unless you actually have been using the cost-based optimization mode (CBO)
SQL> alter session set optimizer_mode=RULE;
Session altered.
SQL> explain plan for select 1 from dual;
Explained.
SQL> set linesize 130
SQL> set pagesize 0
SQL> select * from table(dbms_xplan.display);
Plan hash value: 1550022268
| Id  | Operation        | Name | Rows  | Bytes | Cost  |
|   0 | SELECT STATEMENT |      |       |       |       |
|   1 |  FAST DUAL       |      |       |       |       |
Note
   - rule based optimizer used (consider using cbo)
12 rows selected.
SQL> alter session set optimizer_mode=ALL_ROWS;
Session altered.
SQL> explain plan for select 1 from dual;
Explained.
SQL> select * from table(dbms_xplan.display);
Plan hash value: 1550022268
| Id  | Operation        | Name | Rows  | Bytes | Cost (%CPU)| Time     |
|   0 | SELECT STATEMENT |      |     1 |       |     2 (0)| 00:00:01 |
|   1 |  FAST DUAL       |      |     1 |       |     2 (0)| 00:00:01 |
8 rows selected.Cheers
Legatti

Similar Messages

  • Oracle ODBC Driver 10.02.00.04 sqora32.dll with /*+ RULE */ base hints

    Hi Everybody,
    I have a problem with SQL queries with /*+ RULE */ base hints being posted to an Oracle database. I have reason to believe that these queries are generated by the Oracle ODBC Driver itself. Although I don't have a performance problem per se, I need to reduce these hints to a minimum so we can fine-tune the database as a whole.
    * The views that are hit are always the same: All_Objects, All_Arguments, All_Synonyms,
    * We are using Oracle ODBC driver 10.02.00.04 for Windows, the database server is a RS6000 with AIX and Oracle 10g,
    * Aside Oracle Development tools, there are no applications, reports or similar gadgets that query the tables described above.
    I would really appreciate any help about this issue.
    Here is an example of the type of queries that I'm writing about:
    SELECT /*+ RULE */ '', b.owner, decode (b.object_type, 'PACKAGE', CONCAT( CONCAT (b.object_name, '.'), a.object_name), b.object_name), NULL, NULL, NULL, NULL, decode (b.object_type, 'PACKAGE', decode(a.position, 0, 2, 1, 1, 0), decode(b.object_type, 'PROCEDURE', 1, 'FUNCTION', 2, 0))
    FROM ALL_ARGUMENTS a, ALL_OBJECTS b
    WHERE ( b.object_type = 'PROCEDURE' OR b.object_type = 'FUNCTION' ) AND b.object_id = a.object_id AND (a.sequence=1 OR a.sequence=0) AND b.OBJECT_NAME = 'MYTABLE' AND b.OWNER = 'MYSCHEMA' UNION
    SELECT /*+ RULE */ '', b.owner,b.object_name,NULL, NULL, NULL, NULL,decode(b.object_type, 'PROCEDURE', 1, 'FUNCTION', 2, 0)
    FROM ALL_OBJECTS b
    WHERE (b.object_type = 'PROCEDURE' OR b.object_type = 'FUNCTION') AND b.OBJECT_NAME = 'MYTABLE' AND b.OWNER = 'MYSCHEMA' UNION
    SELECT /*+ RULE */ distinct '', a.owner,CONCAT(CONCAT (a.package_name, '.'), a.object_name),NULL, NULL, NULL, NULL,decode(a.position, 0, 2, 1, 1, 0)
    FROM ALL_ARGUMENTS a
    WHERE (a.sequence=1 OR a.sequence=0) AND a.OBJECT_NAME = 'MYTABLE' AND a.OWNER = 'MYSCHEMA' ORDER BY 2,3
    Best Regards,
    Manuel
    Edited by: user10165637 on Jul 28, 2009 1:29 PM

    Hi Greg,
    Thank you for your answer. One of the things that we did when we migrated to Oracle 10g was to ensure that the "Disable Rule Base Hints" flag, located in the "Work-arounds" tab in the ODBC DSN window is checked. We previously refreshed all Microsoft's Access databases to use this new DSN connection. Still, the hints are there.
    However... we may have been able to link these calls to these Oracle System Catalog views, with a custom application that launces Crystal Reports.
    Although we all know that Crystal Reports also caches ODBC DSN configuration settings, I must say that these same Crystal Reports do not generate hints when called from their InfoView server.
    We will proceed to modify the custom application, overridding the dissable rule-base hint work-around with the string "DRH=T" on the connection string. Next week we will know if this works.
    Best Regards,
    Manuel

  • Partitioning on Oracle 8.0.6 (rule base vs. cost base)

    At my current engagement, we are using Oracle Financials 11.0.3 on Oracle 8.0.5 which uses rule-based optimizer. However, it is been planned to upgrade the database from Oracle 8.0.5 to Oracle 8.0.6 as well as implement Oracle partitioning. With this in mind, we are concerned about possible performance issues that the implementation of partitioning may cause since RBO does not recognize it.
    We agree that the RBO will see a non-partitioned table the same as a partitioned. In this scenario where you gain the most is with backup/recoverability and general maintenance of the partitioned table.
    Nevertheless, we have a few questions:
    When implementing partitions, will the optimizer choose to go with Cost base vs. Rule base for these partitioned tables?
    Is it possible that the optimizer might get confused with this?
    If this change form RBO to CBO does occur, the application could potential perform poorly because of the way it has been written.
    Please provide any feedback.
    thanks in advance.

    If the CBO is invoked when accessing these tables, you may run into problems.
    - You'll have to analyze your tables & ensure that the statistics are kept up to date.
    - It's possible that any SQL statements which invoke the CBO rather than the RBO will have different performance characteristics. The SYSTEM data dictionary tables, for example, must use the RBO or their performance suffers dramatically. Most of the time, the CBO beats the RBO, but applications which have been heavily tuned with the RBO may have problems with the CBO.
    - Check your init.ora to see what optimizer mode you're in. If you're set to CHOOSE, the CBO will be invoked whenever statistics are available on the table(s) involved. If you choose RULE, you'll only invoke the CBO when the RBO encounters situations it doesn't have rules for.
    Justin

  • Can we access two different Siebel BO in Same OPA Rule Base

    Hi all,
    can we access two different BO's from same rule base.
    what i means is,can we pass siebel data to OPA Rule Base from two different BO's .
    Thank you for your help in advance.

    There are two approaches to do this and they both involve making some small changes on the Siebel side.
    You can create an Integration Object which contains all the business components that you want to send to OPA if you are using an Integration Object mapping.
    If you would prefer to use a Business Object mapping then you will have to create a new Business Object which combines the BCs of all the Business Objects that you want to send to OPA.
    As you can see, although one approach involves Integration Objects and one involves Business Objects they both work by creating a single object which is an amalgamation of the information that you want to send to OPA.
    Cheers
    Frank

  • Rule Base Engine

    Folks,
    In an enterprise system, the rules are variable in a year and they may change. The rules and data are somehow dynamic. The dynamic data exists in a RDBMS but about the rules, I want to put them in a Rule Base Engine. If they are hard coded, the system is not flexible again the changes. One solution is to use the rules behine an interface and after any changes, we can implement the related interface to get the goal. but I have a question! Is there any other way to abstract the rules in an engine or some thing like that ?
    Any comment is welcome,
    Amin Emami

    You can implement a rules engine using the Interpreter Pattern in Java from scratch in a few days.
    Checkout the GOF Design Patterns book for the pure pattern, or the Applied Java Patterns for a more practical example.
    You can use this pattern to Interpret your rules file from a free form text document but then you need to implement a tokeniser & parser, which takes time. So a good alternative is to use XML.
    You can use your projects existing DAO to access the database.

  • Rule base issue

    Hi there,
    I've been building a rule base and when I test the following rules and select "Aggregate Format" as the preferred family of format, it concludes that the product does not meet the preference requirements for Standard, Horizontal, or Linear formats since the preferred family of format is Aggregate. Clearly, it should meet the preference requirements but there must be an issue with my rules. Any ideas on how to solve this issue? what tests to run?
    the product meets the preference requirements for Standard, Horizontal, or Linear formats if
        (1) the product’s first choice is the Standard, Horizontal, and Linear formats or
            (2) the manufacturer's product = “able to use multiple format styles” and
            (2) the preferred family of format = “Standard, Horizontal or Linear”
        (1) the product’s first choice is the Aggregate Format – Different Kinds of Foods and does not meet the requirements
           (2) the manufacturer's product = “able to use multiple format styles” and
           (2) the preferred family of format = “Aggregate Format” and
    (2)the most suitable NFT format figure is not Figure 10.1 and
    (2)the most suitable NFT format figure is not Figure 10.2 and
    (2)the most suitable NFT format figure is not Figure 10.3 and
    (2)the most suitable NFT format figure is not Figure 10.4 and
    (2)the most suitable NFT format figure is not Figure 10.5 and
    (2)the most suitable NFT format figure is not Figure 10.6 and
    (2)the most suitable NFT format figure is not Figure 11.1 and
    (2)the most suitable NFT format figure is not Figure 11.2 and
    (2)the most suitable NFT format figure is not Figure 11.3 and
    (2)the most suitable NFT format figure is not Figure 11.4 and
    (2)the most suitable NFT format figure is not Figure 11.5 and
    (2)the most suitable NFT format figure is not Figure 11.6

    Since the rule contains both AND and OR clauses, OPA needs to know how they are combined.
    By default, there are the grouping operators ALL (or BOTH) to group premises joined by AND, and ANY (or EITHER), to group premises joined by OR.
    However, it is also possible to replace the grouping attributes with new attributes. This seems to be what has been misleading you.
    When applying grouping operators to your rule, you would get:
    the product meets the preference requirements for Standard, Horizontal, or Linear formats if
        (1) the product’s first choice is the Standard, Horizontal, and Linear formats or
            all
            (2) the manufacturer's product = “able to use multiple format styles” and
            (2) the preferred family of format = “Standard, Horizontal or Linear”
        (1) the product’s first choice is the Aggregate Format – Different Kinds of Foods and does not meet the requirements
            all
            (2)the manufacturer's product = “able to use multiple format styles” and
            (2)the preferred family of format = “Aggregate Format” and
    (2)the most suitable NFT format figure is not Figure 10.1 and
    (2)the most suitable NFT format figure is not Figure 10.2 and
    (2)the most suitable NFT format figure is not Figure 10.3 and
    (2)the most suitable NFT format figure is not Figure 10.4 and
    (2)the most suitable NFT format figure is not Figure 10.5 and
    (2)the most suitable NFT format figure is not Figure 10.6 and
    (2)the most suitable NFT format figure is not Figure 11.1 and
    (2)the most suitable NFT format figure is not Figure 11.2 and
    (2)the most suitable NFT format figure is not Figure 11.3 and
    (2)the most suitable NFT format figure is not Figure 11.4 and
    (2)the most suitable NFT format figure is not Figure 11.5 and
    (2)the most suitable NFT format figure is not Figure 11.6
    but since you have omitted the grouping operators, OPA would have interpreted the level (1) clauses as intermediate attributes. This could be misleading.
    Try to split the rule in multiple rules. This is likely to help you debug this rule.

  • Error compiling Rule base in 10.4.4

    Hi ,
    I am facing an error while compiling (using Build and Debug option) OPA rule base in OPM 10.4.4 version.
    The rule base was originally built in 10.4.2 and it gets successfully complied in 10.4.2 version.
    Error code: OPA - E00088 ( Unknown attribute)
    Could you please help me with this.
    Let me know if you need additional details.
    Thank you
    Chetan Jain

    Where are you seeing "Error code: OPA - E00088 ( Unknown attribute)"? Is it the 'Error List' in OPM? Often the errors there are clickable and will take you to what's causing the error, e.g. when there's an interview screen causing an error, clicking the error in the Error List usually opens the problem interview screen (in your case it sounds like an attribute not a screen though).
    The other thing I'd try is narrowing down the cause of the problem. For example, is there a particular rule document which won't compile?
    Cheers,
    Jasmine

  • Converting to ASA rules base

    I am just about to start on a project where we are moving from Old Cyberguard firewalls to ASA 5520 firewalls, I was wondering if anyone has a rule base converstion tool that would be able to do a lot of the basic work? And so of the NAT conversions?

    Hello Glenn
    To be honest with you I do not think there is a convertion tool from that firewall to our ASA.
    I would recommend to read and analize the configuration guides for the ASA or if you have any question related to the ASA setup let us know.
    We will be more than glad to help!!
    Regards,
    Do rate all the helpful posts
    Julio

  • Rule base optimizer in 9i and 10g

    Hi
    All,
    I just upgraded databses from oracle 9.2.0.6 to 10.2.0.3.
    I think as i know oracle 10g no more support rule based optimzer ( correct me if i am wrong)
    but some of the script have rule optimizer hint over there. If i keep as it is will it give me error or I need to change something.
    Thanks,
    Vishal

    what should i do? should i keep as it is?
    RBO is obsoleted in 10g , but hint RULE still work i.e it will not error out.
    Check execution plan with and without hint , if execution plan look better without hint,
    go for it. Keeping as it is , will not harm , but data increase/change drastically in underlying table of query , in that case CBO might give you better execution plan then with rule hint.

  • Rule Bases Check and CTP Settings

    Dear Experts,
       I want to run Rule based ATP and CTP together in the system. As far as i know the system of each of these are typicAl and i am not able to run both together. Please guide me for any settings to be maintained to run the same.
    Thanks

    Prashant,
    First, make sure RBA works, and CTP works, independently.  I won't go into setup for each of these, which are pretty extensive all on their own.
    I don't know what you are using for rules, so I will give you some general ideas.  You will have to decide how you want it to work.  For RBA & CTP, it usually makes most sense to run RBA immediately, and when none of the RBA proposals give a solution, then you execute production (CTP).  If you were to invoke production first, you will typically find a solution immediately and never get to the RBA step.  The trick is to have RBA call production on the last step of the last rule.
    So, in IMG>APO>GATP>General Settings>Maintain Check instructions do product check first (well, unless you are doing allocation, but that is another story).  Tick Activate RBA, start immediately.  This gets RBA running first.  It will do all the product checks you have configured in your RBA.  Set the Production part as 'Availability check only, no production'.  A bit counter-intuitive sounding, thanks SAP!
    Logically, the final rule you determine (after failure of all previous rules) will be a location determination rule,  where the system decides where you are going to manufacture the parts. (you should already have determined product and version).  On the final location determination rule, you assign a location determination activity (which you defined in /SAPAPO/RBA04>Profiles and Parameters>Location determination activities).  Within the Location determination activity, you invoke production. Within the activity, you define Start Production as  'Availability check first, then production', on the assumption that you haven't checked this location yet for standard product check.
    This is one way to use both RBA and CTP.  There are probably others, but I have used this successfully.
    Rgds,
    DB49

  • Rule based ATP is not working for Components

    Hi All,
    Our requirement is to do availability check through APO for Sales order created in ECC,so we are using gATP.
    Requirement: We are creating salesorder for BOM header (Sales BOM) and avaialbility check should happen for components i.e. Product avalaibility & Rule based substitution.
    Issue: Product availiabilty is working for components but rules based substituion is working,  mean Rules are not getting determind for components.
    Settings:
    - Header doesnot exist in APO and compnents do exist in APO
    - Availability check is not enabled for header item category and enabled for Item category for components
    - Rules have been created for Components in APO
    - Rule base ATP is activated in Check instructions
    We have also tried MATP for this i.e. PPM created in APO but still didn't get the desired result.
    If we create salesorder for the component material directly then Rule based ATP is happening, so for components Rule based ATP is not working.
    How do we enable enable Rulesbased ATP for components, i mean is there any different way to do the same.
    Thanks for help.
    Regards,
    Jagadeesh

    Hi Jagdeesh,
    If you are creating BOM in ECC and CIFing PPM of FG/Header material to APO, I think you need to CIF Header material, too, with material integration model.
    Please include header material in you integration models for material, SO and ATP check as well.
    For component availability check, you can use MATP; but for MATP, FG should be in APO. You need not to CIF any receipts of FG (stock, planned orders, POs etc), so that MATP will be triggered directly. Then maintaining Rules for RMs will enable to select available RMs according to the rule created.
    Regards,
    Bipin

  • Partitioning on Oracle 8i (Rule Based vs. Cost Based)

    At my current engagement, we are using Oracle Financials 11.0.3 on Oracle 8.0.6. The application uses rule-based optimizer. The client wants to implement Oracle partitioning. With this in mind, we are concerned about possible performance issues that the implementation of partitioning may cause since RBO does not recognize it.
    We agree that the RBO will see a non-partitioned table the same as a partitioned. In this scenario where you gain the most is with backup/recoverability and general maintenance of the partitioned table.
    Nevertheless, we have a few questions:
    When implementing partitions, will the optimizer choose to go with Cost base vs. Rule base for these partitioned tables?
    Is it possible that the optimizer might get confused with this?
    Could it degrade performance at the SQL level?
    If this change from RBO to CBO does occur, the application could potential perform poorly because of the way it has been written.
    Please provide any feedback.
    Thanks in advance.

    If the CBO is invoked when accessing these tables, you may run into problems.
    - You'll have to analyze your tables & ensure that the statistics are kept up to date.
    - It's possible that any SQL statements which invoke the CBO rather than the RBO will have different performance characteristics. The SYSTEM data dictionary tables, for example, must use the RBO or their performance suffers dramatically. Most of the time, the CBO beats the RBO, but applications which have been heavily tuned with the RBO may have problems with the CBO.
    - Check your init.ora to see what optimizer mode you're in. If you're set to CHOOSE, the CBO will be invoked whenever statistics are available on the table(s) involved. If you choose RULE, you'll only invoke the CBO when the RBO encounters situations it doesn't have rules for.
    Justin

  • Use of decision table in Oracle Business Rule

    hello,
    I am using Oracle Business Rule beta version to develop a rule base application.
    I want to know that how i can make use of table to make decision on the basis of table data .
    thanx
    saleem

    hello,
    I am using Oracle Business Rule beta version to develop a rule base application.
    I want to know that how i can make use of table to make decision on the basis of table data .
    thanx
    saleem

  • PI Alert configuration rule definition

    Hello,
    On my PI production system I want to cretae a rule base on the adapter type (RWB  - Alert configuration),
    unfortunately i can olly choose between * and MessagingSystem. On my test and dev systems I have all the adapters in the "combo box" : *, AS2, CIDX, RFC, OFT_X31, SOAP ....
    Does someone Know what I have to do to see all the adapters type ?
    Thank you
    Fabrice

    Do you have any other interfaces running in production?
    if this is the first then i guess Post installation steps might have some problem like registration of Adapter Engine in SLD...
    Check with basis...
    HTH
    Rajesh

  • Rule Based System

    Hi all,
    I am currently working on a project which required to Implemented 500-600 rules in the System. Some of them are global Rules and some are just module level rules.
    Is there any pattern exist for Rule Based System?
    Thanks in Advance
    Rashmikant

    Just 1 pattern?
    The short answer: No.
    The longer (though still short answer):
    A rules engine is not the easiest thing to implement, just 2 or 3 classes don't hack it if you're working with a dynamic rule base that is steered based on input/ouput and states.
    There are rules engines for sale and there also a few opensource, look on the internet, use your best best friend.

Maybe you are looking for