Association rules java code

Hi
I am trying to run the demo java code for the association rules
but it doesn't import everything. The following imports give
an error.
import javax.datamining.ExecutionHandle;
import javax.datamining.ExecutionState;
import javax.datamining.ExecutionStatus;
import javax.datamining.JDMException;
import javax.datamining.MiningAlgorithm;
import javax.datamining.MiningFunction;
import javax.datamining.NamedObject;
import javax.datamining.SortOrder;
import javax.datamining.association.AssociationModel;
import javax.datamining.association.AssociationSettings;
Any ideas?
Thank u very much
K

------SOLVED-----

Similar Messages

  • Association rules Java API (non-transactional data)

    Hi
    I am looking at the demo java program (dmardemo.java) for association rules.
    This iconverts the data from transactional format to non by using a nested column.
    In my case the data are already non-transactional do I have to create a nested column or the model can be build based on the original columns?
    Thank u
    Kate

    Hi Kate,
    Here is what we provide for ODM 10.2 (thanks to Kathy from our doc team in compiling this for me).
    The following are db docs provided by Oracle, with sections noted that contain more info on transformations.
    You can go to this link to view them: http://www.oracle.com/pls/db102/homepage
    Concepts - Chapter 2 (general data prep)
    Application Developer's Guide - Chapters 2 (general data prep), 5 (text transformation), and 7 (Java data prep).
    Java API Reference (javadoc)
    PL/SQL Packages and Types Reference -- DBMS_DATA_MINING_TRANSFORM. In 10.2, the source code is still available.
    Here are a few more sources:
    Sample programs (The source code and embedded comments are quite helpful)
    View this at: http://www.oracle.com/technology/products/bi/odm/index.html
    ODMr Tutorial -- Chapter 2
    View this at: http://www.oracle.com/technology/products/bi/odm/odminer.html
    There is also a book on the java api that is out.
    You can go to Amazon and check it out:
    http://www.amazon.com/Java-Data-Mining-architecture-implementation/dp/0123704529/sr=8-1/qid=1172519948/ref=pd_bbs_sr_1/105-8560904-8042036?ie=UTF8&s=books
    In ODM 11, there have been alot of improvements related to transformations, but I can say anything about that until ODM 11 is released.
    Thanks, Mark

  • Association Rules - dmardemo.java - DisplayAssociationRules method

    Hi, friends!
    I'm making some changes in the sample Java demo for the Association Rules - dmardemo.java. I've created another method which contains the name of the model just created before and in this same method, I call the method to display the association rules detected:
    public static void restoreRules(String modelNome) throws JDMException {
    m_modelName = modelNome;
    model = (AssociationModel)m_dmeConn.retrieveObject(
    m_modelName, NamedObject.model);
    displayAssociationRules(model);
    In another class, which is a GUI, I'm trying to call that method to restore all the rules found in the mining process and display them in a jTable Swing component. For this, I've tried to adapt the main method (displayAssocationRules) to do this, as follows:
    public static Object displayAssociationRules(AssociationModel model)
    throws JDMException {
    // DISPLAY TOP-10 ASSOCIATION RULES
    Object[] obj = new Object[5];
    int contador = 0;
    // 1. Set order by confidence DESC, support DESC
    OraRulesFilter filter = (OraRulesFilter) m_filterFactory.create();
    filter.setOrderingCondition(
    new RuleProperty[] { RuleProperty.confidence, RuleProperty.support},
    new SortOrder[] { SortOrder.descending, SortOrder.descending }
    // 2. Set to return the first 10 rules only
    filter.setMaxNumberOfRules(10);
    // 3. Retrieve rules
    Collection rules = model.getRules(filter);
    Iterator iRules = rules.iterator();
    while( iRules.hasNext() )
    OraAssociationRule rule = (OraAssociationRule) iRules.next();
    obj[0] = rule.getRuleIdentifier();
    //System.out.print( "Rule " + rule.getRuleIdentifier() + ": " );
    Itemset antecedent = rule.getAntecedent();
    //obj[1] = antecedent.getItems();
    Object[] ante_items = antecedent.getItems();
    // sort the items in antecedent to produce deterministic order of items
    TreeSet sortedSet = new TreeSet();
    for(int i = 0; i < obj.length; i++)
    sortedSet.add(ante_items);
    obj[1] = ante_items;
    Iterator sortedI = sortedSet.iterator();
    /*while(sortedI.hasNext())
    System.out.print(sortedI.next() + " ");*/
    Itemset consequent = rule.getConsequent();
    Object[] cons_items = consequent.getItems();
    obj[2] = cons_items;
    obj[3] = m_df.format(rule.getSupport());
    obj[4] = m_df.format(rule.getConfidence());
    /*System.out.println("==> " + cons_items[0] + " (support=" +
    m_df.format(rule.getSupport()) + ", confidence=" + m_df.format(rule.getConfidence()) + ")" );*/
    return obj;
    Some parts of the old code are present in that for you to compare what I've done. However, it's not working. What should I do to see the rules generated in the process in a jTable?
    Regards
    Luis

    As you can see in the code above, I've split the code into two parts. However, a problem is happening when I try to restore the rules to the GUI.
    "Exception in thread "AWT-EventQueue-0" javax.datamining.JDMIllegalArgumentException: The required argument objectName is null. Supply a non-null value."
    It says that I'm not passing any parameters to the method. But, as you can see, in the first method I've created, I took the name of the model and transfers it for the method displayAssociationRules as a AssociationModel objet.
    In the GUI, in an event for the button "Restore Rules", I've put this code below:
    String modelo = Principal.getModelName(); // where Principal is the main GUI class for the execution of the process.
    dmardemo.restoreRules(modelo);// I call the method in the dmardemo class to restore the rules having a String (modelo) as its parameter. That's when the problem happens. Is the argument really null, as the error message says?
    Regards
    Luis

  • Clean Java Code No SQL

    Has anyone concidered putting all SQL outside the java source code. A properties file seems rather limited so why not xml?
    My goal for posting this topic is to have the JDBC community provide input and suggestions for the given scenario.
    A java app performs a certain task involving a DB the application is ported to another environment and the DB changes and the SQL for the action changes.
    How would you define the SQL outside of the code and how would the java code interpret it, including SQL that is dynamically build using class properties or return values from class methods.
    Thanks for reading this,
    Phil

    upsidedown7 said
    in other words, in about 15 meta data tables,
    you enter your logical data model,
    and click which field(s) to search on, and with is
    editable, the user, and user groups, and it
    builds the application for you.And if one really wants to get away from the advantages of using a database one can use a OO database. Supposedly POET allows one to use any backend database (or at least Oracle and MS SQL Server.) So one doesn't even need to deal with tables or fields. It is all just objects.
    It is always helpful to actually code a database from scratch. Doing so makes it obvious that a database needs to keep track of tables, and table names, and fields and field names and field types, etc. That is all 'meta-data'.
    It makes it more obvious that creating meta data is just duplicating what a database already does.
    And once one starts using a database to store meta-data and to store data in a form that is not consistent with the database model, one looses all advantages associated with a database. Like speed. Like seperation of the data model from the implementation model. Like allowing for different data striping models, archiving models and a slew of other useful tools that have come from 50 years of database technology.
    And then there is migration. Add one field to your model for version 2 and now you have load the entire database in to memory, restructure the data model, and then lay that data back down. A chore that takes a couple of minutes or less in SQL using a relational layout can require a dedicate programmer several weeks to program and can take 12 hours to run on a client side only system (and be impossible on a server side system.)
    Have you ever wondered why OO databases have not taken over the world even though they have been around for more than 10 years. Java didn't even exist when the first OO databases were already in the 2nd generation. And yet there is almost no market for them.
    Consider how many languages, and process control models have been implemented and discarded in the last 50 years. And yet the relational model is stronger than ever. There has to be a reason.
    i have moved all my users to using only
    UPPERCASE data. since i have a rule of
    no stored proceedures and triggers in my db's.And that is a good thing?
    What does that have to do with stored procs?
    using this, we were able to port a single application
    to SQL Server 7, DB anywhere, and Oracle 8i in
    4 days. the application had 121 tables. we had
    a slight problem with dates, but we hammered that
    out.The vast majority of applications will never use a different database. When they do it will be a complete switch.
    Will your method work with 8000 tables (as someone suggested on this forum that they were running?)
    At one company I worked for a single table contained something like 100 million rows (actually for performance reasons we had to break it into 3 tables as archived by date.)
    Will your method work with 100 million rows? That database was 250 gigs and was growing at a rate of 400 meg a day. And they were planing on doubling that rate (and one estimate put it up to 10 times.) How long would it take to store 400,000 rows, every day, using your method? How long would it take to do the accumlation reports that could easily touch 30 million records?
    This isn't to say that your solution isn't correct for your application. If the fields (not the data but the fields) change constantly day to day and your users can get by with the other constraints you have made then it is a good solution.
    But as a general solution I would guess it has some serious flaws. And I for one would never want to handle the migration issue.

  • Association Rules Error - Numeric argument "{0}" is invalid

    I am running the sample association rules code on some different data (have changed the properties file to point at my data). The system is generating the association rules (I can see them in the database), but when it gets to the display step, I get the follow exception:
    oracle.dmt.odm.MiningObjectException: Numeric argument "{0}" is invalid. Value must be {1}.
    at oracle.dmt.odm.rule.RuleComponent.<init>(RuleComponent.java:37)
    at oracle.dmt.odm.internal.rule.ARMiningRuleCursor.getNextRule(ARMiningRuleCursor.java:127)
    at Sample_AssociationRules.printRuleSet(Sample_AssociationRules.java:352)
    at Sample_AssociationRules.displayAssociationRules(Sample_AssociationRules.java:381)
    at Sample_AssociationRules.main(Sample_AssociationRules.java:171)
    I am running 9.2.0.1.0 on Windows XP and haven't applied any patches yet.
    Any help appreciated,
    James

    Please repost on the PL/SQL OTN forum. This forum is XMLDB functionality specific.

  • Error: ORA-03113 while executing complex java code from Oracle PL/SQL

    Hi,
    I am trying to execute a complex java code from Oracle PL/SQL. The classes were resolved successfully. But in the middle of execution, I am getting the following error:
    ERROR:
    ORA-03114: not connected to ORACLE
    begin
    ERROR at line 1:
    ORA-03113: end-of-file on communication channel
    Process ID: 13685
    Session ID: 21 Serial number: 20
    Is there a way to debug the Java classes loaded into oracle? Or is there any utility to find out why the connection was lost?
    Regards,
    Saravana

    Hi Saravana:
    You could use simply System.out.println(..) at your Java code and see the output at the .trc files generated for your Oracle session.
    Or better than this adding Java Util Logging messages at your code, to see how to use JUL API at the OJVM please see this blog post [Using JUL API inside the OJVM|http://marceloochoa.blogspot.com/2007/11/getting-logging-entering-exiting-and.html].
    Best regards, Marcelo.
    PD: ora-0600 generally are associated with RDBMS bugs, but these bugs can be bypassed by replacing the code which throws the exception by other with a workaround.

  • Error while sending Email through Java Code in OIM

    Hi All,
    I have created a java code using tcEmailNotificationUtil, and integrated the same with the adapter.
    I am triggering this adapter when an approval process gets completed.
    As soon as the approval process gets completed my email task is triggering but the task is getting rejected.
    I have checked my system configuration for mail server settings.Everything seems working fine.
    Can you please help me in this issue how to debug?
    Thanks in advance.

    Hi,
    Here is my log file:
    DEBUG,25 Apr 2011 10:40:00,099,[XELLERATE.SERVER] - Class/Method: QuartzWrapper/insertTaskHistory left.
    DEBUG,25 Apr 2011 10:40:00,099,[XELLERATE.SCHEDULER.TASK] - Class/Method: SchedulerBaseTask/run entered.
    DEBUG,25 Apr 2011 10:40:00,099,[XELLERATE.SCHEDULER.TASK] - Class/Method: ReIssueAuditMessage/execute entered.
    DEBUG,25 Apr 2011 10:40:00,099,[XELLERATE.SCHEDULER.TASK] - Class/Method: ReIssueAuditMessage/initialize entered.
    DEBUG,25 Apr 2011 10:40:00,099,[XELLERATE.SCHEDULER.TASK] - Class/Method: SchedulerBaseTask/getAttribute entered.
    DEBUG,25 Apr 2011 10:40:00,099,[XELLERATE.SCHEDULER.TASK] - Class/Method: SchedulerBaseTask/getAttribute left.
    DEBUG,25 Apr 2011 10:40:00,099,[XELLERATE.SCHEDULER.TASK] - Class/Method: SchedulerBaseTask/getUtility entered.
    DEBUG,25 Apr 2011 10:40:00,099,[XELLERATE.SCHEDULER.TASK] - Class/Method: SchedulerBaseTask/getUtility left.
    DEBUG,25 Apr 2011 10:40:00,099,[XELLERATE.ACCOUNTMANAGEMENT] - Class/Method: tcUtilityFactory/getRemoteUtility - Data: moUtil - Value: Thor.API.Operations.tcAuditOperationsClient
    DEBUG,25 Apr 2011 10:40:00,099,[XELLERATE.SCHEDULER.TASK] - Class/Method: ReIssueAuditMessage/initialize left.
    DEBUG,25 Apr 2011 10:40:00,099,[XELLERATE.SCHEDULER.TASK] - Class/Method: ReIssueAuditMessage/processAllByIdentifier entered.
    DEBUG,25 Apr 2011 10:40:00,099,[XELLERATE.SCHEDULER.TASK] - Class/Method: SchedulerBaseTask/isStopped entered.
    DEBUG,25 Apr 2011 10:40:00,099,[XELLERATE.SCHEDULER.TASK] - Class/Method: SchedulerBaseTask/isStopped left.
    DEBUG,25 Apr 2011 10:40:00,100,[XELLERATE.DATABASE] - select A.* from (select aud_jms_key, aud_class, identifier from aud_jms order by aud_jms_key) A where rownum <= ?
    INFO,25 Apr 2011 10:40:00,101,[XELLERATE.PERFORMANCE] - Query: DB: 1, LOAD: 0, TOTAL: 1
    DEBUG,25 Apr 2011 10:40:00,102,[XELLERATE.SCHEDULER.TASK] - Class/Method: SchedulerBaseTask/isStopped entered.
    DEBUG,25 Apr 2011 10:40:00,102,[XELLERATE.SCHEDULER.TASK] - Class/Method: SchedulerBaseTask/isStopped left.
    DEBUG,25 Apr 2011 10:40:00,102,[XELLERATE.SCHEDULER.TASK] - Class/Method: SchedulerBaseTask/isStopped entered.
    DEBUG,25 Apr 2011 10:40:00,102,[XELLERATE.SCHEDULER.TASK] - Class/Method: SchedulerBaseTask/isStopped left.
    DEBUG,25 Apr 2011 10:40:00,102,[XELLERATE.SCHEDULER.TASK] - Class/Method: ReIssueAuditMessage/execute left.
    DEBUG,25 Apr 2011 10:40:00,102,[XELLERATE.SCHEDULER.TASK] - Class/Method: SchedulerBaseTask/run left.
    DEBUG,25 Apr 2011 10:40:00,102,[XELLERATE.SCHEDULER.TASK] - Class/Method: SchedulerBaseTask/isSuccess entered.
    DEBUG,25 Apr 2011 10:40:00,102,[XELLERATE.SCHEDULER.TASK] - Class/Method: SchedulerBaseTask/isSuccess left.
    DEBUG,25 Apr 2011 10:40:00,102,[XELLERATE.SERVER] - Class/Method: SchedulerTaskLocater /removeLocalTask entered.
    DEBUG,25 Apr 2011 10:40:00,102,[XELLERATE.SERVER] - Class/Method: SchedulerTaskLocater /removeLocalTask left.
    DEBUG,25 Apr 2011 10:40:00,102,[XELLERATE.SERVER] - Class/Method: QuartzWrapper/updateStatusToInactive entered.
    DEBUG,25 Apr 2011 10:40:00,104,[XELLERATE.SERVER] - Class/Method: QuartzWrapper/updateStatusToInactive left.
    DEBUG,25 Apr 2011 10:40:00,104,[XELLERATE.SERVER] - Class/Method: QuartzWrapper/updateTaskHistory entered.
    DEBUG,25 Apr 2011 10:40:00,106,[XELLERATE.SERVER] - Class/Method: QuartzWrapper/updateTaskHistory left.
    DEBUG,25 Apr 2011 10:40:00,106,[XELLERATE.SERVER] - Clearing Security Associations with thread executing Scheduled task
    DEBUG,25 Apr 2011 10:40:00,106,[XELLERATE.SERVER] - Class/Method: QuartzWrapper/run left.
    DEBUG,25 Apr 2011 10:40:00,106,[XELLERATE.SERVER] - Class/Method: QuartzWrapper/execute left.
    and I just wanted to ensure that my coding part is also fine.
    Posting the code even:
    tcDataProvider ioDatabase = new tcDataBaseClient();
    tcEmailNotificationUtil sendMail = new tcEmailNotificationUtil(ioDatabase);
    sendMail.setBody("Sample Message");
    sendMail.setSubject("subject");
    sendMail.setFromAddress("fromemailaddress");
    sendMail.sendEmail("recepient");
    Thanks in Advance.

  • Java code in jsp source files is not allowed in ojsp.next mode.

    Hi,
    I’m working on WC Spaces Customization library “com.acme.custom.webcenter.spaces.war”. From time to time, when I deploy the library to WC Server, it errors out.
    weblogic.management.DeploymentException: Cannot undeploy library Extension-Name: com.acme.custom.webcenter.spaces, Specification-Version: 11.1.1, Implementation-Version: 11.1.1.2.113 from server WC_Spaces, because the following deployed applications reference it: webcenter-rest.war, spaces.war, sharepoint-servlet.war, webcenter-rss.war
    If I try to login the Spaces, I get “Java code in jsp source files is not allowed in ojsp.next mode.” Should I stop the Spaces server before the deployment? In this case, other people won’t have accesses to Spaces? The deployment error doesn’t happen all the time.
    oracle.jsp.parse.JavaCodeException: Line # 6, oracle.jsp.parse.JspParseTagScriptlet@5b9864ca
    Error: Java code in jsp source files is not allowed in ojsp.next mode.
    at oracle.jsp.parse.JspParseTagCore.createNode(JspParseTagCore.java:263)
    at oracle.jsp.parse.JspUtils.createChildNodes(JspUtils.java:2489)
    at oracle.jsp.parse.JspParseTagFile.createTree(JspParseTagFile.java:475)
    at oracle.jsp.parse.OracleJsp2Java.transformImpl(OracleJsp2Java.java:535)
    at oracle.jsp.parse.OracleJsp2Java.transform(OracleJsp2Java.java:593)
    at oracle.jsp.runtimev2.JspPageCompiler.attemptCompilePage(JspPageCompiler.java:691)
    at oracle.jsp.runtimev2.JspPageCompiler.compileBothModes(JspPageCompiler.java:490)
    at oracle.jsp.runtimev2.JspPageCompiler.parseAndGetTreeNode(JspPageCompiler.java:457)
    at oracle.jsp.runtimev2.JspPageInfo.compileAndLoad(JspPageInfo.java:624)
    at oracle.jsp.runtimev2.JspPageTable.compileAndServe(JspPageTable.java:645)
    at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:385)
    at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:802)
    at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:726)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
    Buildfile: C:\JDeveloper\mywork\LamwWebCenterSpacesExtensions\WebCenterSpacesSharedLibExtension\build.xml
    =======
    init-wls:
    deploy-shared-lib:
    [echo] ----------------------------
    [echo] C:\JDeveloper\mywork\myuserconfigfile.secure C:\JDeveloper\mywork\myuserkeyfile.secure claptd01:7001 C:\JDeveloper\mywork\XxxWebCenterSpacesExtensions/WebCenterSpacesSharedLibExtension/deploy/exploded WC_Spaces com.acme.custom.webcenter.spaces
    [exec]
    [exec] CLASSPATH=C:\oracle\MIDDLE~1.5\patch_wls1035\profiles\default\sys_manifest_classpath\weblogic_patch.jar;C:\oracle\MIDDLE~1.5\patch_jdev1111\profiles\default\sys_manifest_classpath\weblogic_patch.jar;C:\oracle\MIDDLE~1.5\JDK160~1\lib\tools.jar;C:\oracle\MIDDLE~1.5\WLSERV~1.3\server\lib\weblogic_sp.jar;C:\oracle\MIDDLE~1.5\WLSERV~1.3\server\lib\weblogic.jar;C:\oracle\MIDDLE~1.5\modules\features\weblogic.server.modules_10.3.5.0.jar;C:\oracle\MIDDLE~1.5\WLSERV~1.3\server\lib\webservices.jar;C:\oracle\MIDDLE~1.5\modules\ORGAPA~1.1/lib/ant-all.jar;C:\oracle\MIDDLE~1.5\modules\NETSFA~1.0_1/lib/ant-contrib.jar;.;%JAVA_HOME\jre\lib;C:\Apache\apache-cxf\lib;C:\Apache\apache-cxf\lib\cxf-manifest.jar;.\build\classes;C:\Program Files\Java\jre6\lib\ext\QTJava.zip;C:\oracle\MIDDLE~1.5\ORACLE~1/modules/oracle.jrf_11.1.1/jrf-wlstman.jar;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\lib\ADF-SH~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\lib\ADFSCR~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\lib\mdswlst.jar;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\AUDITW~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\IGFWLS~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\jps-wlst.jar;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\jrf-wlst.jar;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\OAMAP_~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\OAMAUT~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\ossoiap.jar;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\OSSOIA~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\OVDWLS~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\SSLCON~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\wsm-wlst.jar
    [exec]
    [exec] PATH=C:\oracle\MIDDLE~1.5\patch_wls1035\profiles\default\native;C:\oracle\MIDDLE~1.5\patch_jdev1111\profiles\default\native;C:\oracle\MIDDLE~1.5\WLSERV~1.3\server\native\win\32;C:\oracle\MIDDLE~1.5\WLSERV~1.3\server\bin;C:\oracle\MIDDLE~1.5\modules\ORGAPA~1.1\bin;C:\oracle\MIDDLE~1.5\JDK160~1\jre\bin;C:\oracle\MIDDLE~1.5\JDK160~1\bin;C:\Program Files\PHP52\;C:\Program Files\Common Files\OTG;C:\oracle\product\10.2.0\client_1\bin;C:\oracle\ora_adi\bin;C:\PROGRA~1\REFLEC~1;C:\Program Files\Reflection;C:\Program Files\Oracle\jre\1.1.8\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;E:\MSSQL7\BINN;C:\Program Files\ATI Technologies\ATI.ACE\Core-Static;C:\Program Files\Common Files\Roxio Shared\DLLShared\;C:\Program Files\ATI Technologies\ATI.ACE\;C:\Program Files\Microsoft SQL Server\80\Tools\BINN;C:\Program Files\Microsoft SQL Server\80\Tools\Binn\;C:\Program Files\Microsoft SQL Server\90\Tools\binn\;C:\WINDOWS\system32\WindowsPowerShell\v1.0;C:\glassfish3\jdk\bin;C:\Program Files\TortoiseSVN\bin;C:\Program Files\Vim\vim73;c:\apache\ant\bin;c:\jboss\bin;C:\Apache\apache-cxf\bin;C:\glassfish\bin;C:\Program Files\QuickTime\QTSystem\;C:\oracle\MIDDLE~1.5\WLSERV~1.3\server\native\win\32\oci920_8
    [exec]
    [exec] Your environment has been set.
    [exec]
    [exec] CLASSPATH=C:\oracle\MIDDLE~1.5\patch_wls1035\profiles\default\sys_manifest_classpath\weblogic_patch.jar;C:\oracle\MIDDLE~1.5\patch_jdev1111\profiles\default\sys_manifest_classpath\weblogic_patch.jar;C:\oracle\MIDDLE~1.5\JDK160~1\lib\tools.jar;C:\oracle\MIDDLE~1.5\WLSERV~1.3\server\lib\weblogic_sp.jar;C:\oracle\MIDDLE~1.5\WLSERV~1.3\server\lib\weblogic.jar;C:\oracle\MIDDLE~1.5\modules\features\weblogic.server.modules_10.3.5.0.jar;C:\oracle\MIDDLE~1.5\WLSERV~1.3\server\lib\webservices.jar;C:\oracle\MIDDLE~1.5\modules\ORGAPA~1.1/lib/ant-all.jar;C:\oracle\MIDDLE~1.5\modules\NETSFA~1.0_1/lib/ant-contrib.jar;.;%JAVA_HOME\jre\lib;C:\Apache\apache-cxf\lib;C:\Apache\apache-cxf\lib\cxf-manifest.jar;.\build\classes;C:\Program Files\Java\jre6\lib\ext\QTJava.zip;C:\oracle\MIDDLE~1.5\ORACLE~1/modules/oracle.jrf_11.1.1/jrf-wlstman.jar;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\lib\ADF-SH~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\lib\ADFSCR~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\lib\mdswlst.jar;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\AUDITW~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\IGFWLS~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\jps-wlst.jar;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\jrf-wlst.jar;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\OAMAP_~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\OAMAUT~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\ossoiap.jar;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\OSSOIA~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\OVDWLS~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\SSLCON~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\wsm-wlst.jar;C:\oracle\MIDDLE~1.5\utils\config\10.3\config-launch.jar;C:\oracle\MIDDLE~1.5\WLSERV~1.3\common\derby\lib\derbynet.jar;C:\oracle\MIDDLE~1.5\WLSERV~1.3\common\derby\lib\derbyclient.jar;C:\oracle\MIDDLE~1.5\WLSERV~1.3\common\derby\lib\derbytools.jar;;
    [exec]
    [exec] Initializing WebLogic Scripting Tool (WLST) ...
    [exec]
    [exec] Welcome to WebLogic Server Administration Scripting Shell
    [exec]
    [exec] Type help() for help on available commands
    [exec]
    [exec]
    [exec] Deploy started at Wed Mar 28 12:25:08 2012
    [exec]
    [exec] Connecting to t3://claptd01:7001 with userid weblogic ...
    [exec] Successfully connected to Admin Server 'AdminServer' that belongs to domain 'base_domain'.
    [exec]
    [exec] Warning: An insecure protocol was used to connect to the
    [exec] server. To ensure on-the-wire security, the SSL port or
    [exec] Admin port should be used instead.
    [exec]
    [exec] Location changed to edit tree. This is a writable tree with
    [exec] DomainMBean as the root. To make changes you will need to start
    [exec] an edit session via startEdit().
    [exec]
    [exec] For more help, use help(edit)
    [exec] You already have an edit session in progress and hence WLST will
    [exec] continue with your edit session.
    [exec]
    [exec] Starting an edit session ...
    [exec] Started edit session, please be sure to save and activate your
    [exec] changes once you are done.
    [exec] Deploying application from C:\JDeveloper\mywork\XxxWebCenterSpacesExtensions\WebCenterSpacesSharedLibExtension\deploy\exploded\com.acme.custom.webcenter.spaces.war to targets WC_Spaces (upload=true) ...
    [exec] <Mar 28, 2012 12:25:10 PM EDT> <Info> <J2EE Deployment SPI> <BEA-260121> <Initiating deploy operation for application, com.acme.custom.webcenter.spaces [archive: C:\JDeveloper\mywork\XxxWebCenterSpacesExtensions\WebCenterSpacesSharedLibExtension\deploy\exploded\com.acme.custom.webcenter.spaces.war], to WC_Spaces .>
    [exec] You have an edit session in progress, hence WLST will not
    [exec] block for your deployment to complete.
    [exec] Started the Deployment of Application. Please refer to the returned WLSTProgress object or variable LAST to track the status.
    [exec]
    [exec] ### ### ###: Deploy done
    [exec]
    [exec] 0
    [exec]
    [exec] ### ### ###: Status of Deploy
    [exec]
    [exec] Current Status of your Deployment:
    [exec] Deployment command type: deploy
    [exec] Deployment State : running
    [exec] Deployment Message : [Deployer:149140]The task cannot be processed further until the current edit session is activated. When this occurs, task processing will continue. The user can exit the deployer tool without affecting the task.
    [exec]
    [exec]
    [exec] ### ### ###: Saving
    [exec]
    [exec] Saving all your changes ...
    [exec] Saved all your changes successfully.
    [exec]
    [exec] ### ### ###: Activating
    [exec]
    [exec] Activating all your changes, this may take a while ...
    [exec] The edit lock associated with this edit session is released
    [exec] once the activation is completed.
    [exec] This Exception occurred at Wed Mar 28 12:25:18 EDT 2012.
    [exec] weblogic.management.DeploymentException: Cannot undeploy library Extension-Name: com.acme.custom.webcenter.spaces, Specification-Version: 11.1.1, Implementation-Version: 11.1.1.2.113 from server WC_Spaces, because the following deployed applications reference it: webcenter-rest.war, spaces.war, sharepoint-servlet.war, webcenter-rss.war
    [exec]      at weblogic.deploy.event.DeploymentEventManager.sendVetoableDeploymentEvent(DeploymentEventManager.java:337)
    [exec]      at weblogic.deploy.internal.targetserver.operations.AbstractOperation.fireVetoableDeploymentEvent(AbstractOperation.java:781)
    [exec]      at weblogic.deploy.internal.targetserver.operations.AbstractOperation.prepare(AbstractOperation.java:216)
    [exec]      at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentPrepare(DeploymentManager.java:747)
    [exec]      at weblogic.deploy.internal.targetserver.DeploymentManager.prepareDeploymentList(DeploymentManager.java:1216)
    [exec]      at weblogic.deploy.internal.targetserver.DeploymentManager.handlePrepare(DeploymentManager.java:250)
    [exec]      at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.prepare(DeploymentServiceDispatcher.java:159)
    [exec]      at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doPrepareCallback(DeploymentReceiverCallbackDeliverer.java:171)
    [exec]      at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$000(DeploymentReceiverCallbackDeliverer.java:13)
    [exec]      at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$1.run(DeploymentReceiverCallbackDeliverer.java:46)
    [exec]      at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:528)
    [exec]      at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
    [exec]      at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)
    [exec] Caused by: weblogic.deploy.event.DeploymentVetoException: Cannot undeploy library Extension-Name: com.acme.custom.webcenter.spaces, Specification-Version: 11.1.1, Implementation-Version: 11.1.1.2.113 from server WC_Spaces, because the following deployed applications reference it: webcenter-rest.war, spaces.war, sharepoint-servlet.war, webcenter-rss.war
    [exec]      at weblogic.application.library.LibraryDeploymentListener.verifyLibrary(LibraryDeploymentListener.java:123)
    [exec]      at weblogic.application.library.LibraryDeploymentListener.vetoableApplicationActivate(LibraryDeploymentListener.java:58)
    [exec]      at weblogic.application.library.LibraryDeploymentListener.vetoableApplicationDeploy(LibraryDeploymentListener.java:64)
    [exec]      at weblogic.deploy.event.VetoableDeploymentEvent$2.notifyListener(VetoableDeploymentEvent.java:70)
    [exec]      at weblogic.deploy.event.DeploymentEventManager.sendVetoableDeploymentEvent(DeploymentEventManager.java:335)
    [exec] None
    [exec] #########################################################
    [exec] ##### Deployment Failed #########
    [exec] ##### Contact support with Exception Stack #########
    [exec] #########################################################
    [exec]
    [exec]
    [exec] Exiting WebLogic Scripting Tool.
    [exec]
    [exec] <Mar 28, 2012 12:25:18 PM EDT> <Warning> <JNDI> <BEA-050001> <WLContext.close() was called in a different thread than the one in which it was created.>
    [echo] ----------------------------
    [echo] Restarting the app
    [echo] ----------------------------
    [exec]
    [exec] CLASSPATH=C:\oracle\MIDDLE~1.5\patch_wls1035\profiles\default\sys_manifest_classpath\weblogic_patch.jar;C:\oracle\MIDDLE~1.5\patch_jdev1111\profiles\default\sys_manifest_classpath\weblogic_patch.jar;C:\oracle\MIDDLE~1.5\JDK160~1\lib\tools.jar;C:\oracle\MIDDLE~1.5\WLSERV~1.3\server\lib\weblogic_sp.jar;C:\oracle\MIDDLE~1.5\WLSERV~1.3\server\lib\weblogic.jar;C:\oracle\MIDDLE~1.5\modules\features\weblogic.server.modules_10.3.5.0.jar;C:\oracle\MIDDLE~1.5\WLSERV~1.3\server\lib\webservices.jar;C:\oracle\MIDDLE~1.5\modules\ORGAPA~1.1/lib/ant-all.jar;C:\oracle\MIDDLE~1.5\modules\NETSFA~1.0_1/lib/ant-contrib.jar;.;%JAVA_HOME\jre\lib;C:\Apache\apache-cxf\lib;C:\Apache\apache-cxf\lib\cxf-manifest.jar;.\build\classes;C:\Program Files\Java\jre6\lib\ext\QTJava.zip;C:\oracle\MIDDLE~1.5\ORACLE~1/modules/oracle.jrf_11.1.1/jrf-wlstman.jar;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\lib\ADF-SH~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\lib\ADFSCR~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\lib\mdswlst.jar;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\AUDITW~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\IGFWLS~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\jps-wlst.jar;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\jrf-wlst.jar;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\OAMAP_~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\OAMAUT~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\ossoiap.jar;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\OSSOIA~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\OVDWLS~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\SSLCON~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\wsm-wlst.jar
    [exec]
    [exec] PATH=C:\oracle\MIDDLE~1.5\patch_wls1035\profiles\default\native;C:\oracle\MIDDLE~1.5\patch_jdev1111\profiles\default\native;C:\oracle\MIDDLE~1.5\WLSERV~1.3\server\native\win\32;C:\oracle\MIDDLE~1.5\WLSERV~1.3\server\bin;C:\oracle\MIDDLE~1.5\modules\ORGAPA~1.1\bin;C:\oracle\MIDDLE~1.5\JDK160~1\jre\bin;C:\oracle\MIDDLE~1.5\JDK160~1\bin;C:\Program Files\PHP52\;C:\Program Files\Common Files\OTG;C:\oracle\product\10.2.0\client_1\bin;C:\oracle\ora_adi\bin;C:\PROGRA~1\REFLEC~1;C:\Program Files\Reflection;C:\Program Files\Oracle\jre\1.1.8\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;E:\MSSQL7\BINN;C:\Program Files\ATI Technologies\ATI.ACE\Core-Static;C:\Program Files\Common Files\Roxio Shared\DLLShared\;C:\Program Files\ATI Technologies\ATI.ACE\;C:\Program Files\Microsoft SQL Server\80\Tools\BINN;C:\Program Files\Microsoft SQL Server\80\Tools\Binn\;C:\Program Files\Microsoft SQL Server\90\Tools\binn\;C:\WINDOWS\system32\WindowsPowerShell\v1.0;C:\glassfish3\jdk\bin;C:\Program Files\TortoiseSVN\bin;C:\Program Files\Vim\vim73;c:\apache\ant\bin;c:\jboss\bin;C:\Apache\apache-cxf\bin;C:\glassfish\bin;C:\Program Files\QuickTime\QTSystem\;C:\oracle\MIDDLE~1.5\WLSERV~1.3\server\native\win\32\oci920_8
    [exec]
    [exec] Your environment has been set.
    [exec]
    [exec] CLASSPATH=C:\oracle\MIDDLE~1.5\patch_wls1035\profiles\default\sys_manifest_classpath\weblogic_patch.jar;C:\oracle\MIDDLE~1.5\patch_jdev1111\profiles\default\sys_manifest_classpath\weblogic_patch.jar;C:\oracle\MIDDLE~1.5\JDK160~1\lib\tools.jar;C:\oracle\MIDDLE~1.5\WLSERV~1.3\server\lib\weblogic_sp.jar;C:\oracle\MIDDLE~1.5\WLSERV~1.3\server\lib\weblogic.jar;C:\oracle\MIDDLE~1.5\modules\features\weblogic.server.modules_10.3.5.0.jar;C:\oracle\MIDDLE~1.5\WLSERV~1.3\server\lib\webservices.jar;C:\oracle\MIDDLE~1.5\modules\ORGAPA~1.1/lib/ant-all.jar;C:\oracle\MIDDLE~1.5\modules\NETSFA~1.0_1/lib/ant-contrib.jar;.;%JAVA_HOME\jre\lib;C:\Apache\apache-cxf\lib;C:\Apache\apache-cxf\lib\cxf-manifest.jar;.\build\classes;C:\Program Files\Java\jre6\lib\ext\QTJava.zip;C:\oracle\MIDDLE~1.5\ORACLE~1/modules/oracle.jrf_11.1.1/jrf-wlstman.jar;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\lib\ADF-SH~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\lib\ADFSCR~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\lib\mdswlst.jar;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\AUDITW~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\IGFWLS~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\jps-wlst.jar;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\jrf-wlst.jar;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\OAMAP_~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\OAMAUT~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\ossoiap.jar;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\OSSOIA~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\OVDWLS~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\SSLCON~1.JAR;C:\oracle\MIDDLE~1.5\ORACLE~1\common\wlst\RESOUR~1\wsm-wlst.jar;C:\oracle\MIDDLE~1.5\utils\config\10.3\config-launch.jar;C:\oracle\MIDDLE~1.5\WLSERV~1.3\common\derby\lib\derbynet.jar;C:\oracle\MIDDLE~1.5\WLSERV~1.3\common\derby\lib\derbyclient.jar;C:\oracle\MIDDLE~1.5\WLSERV~1.3\common\derby\lib\derbytools.jar;;
    [exec]
    [exec] Initializing WebLogic Scripting Tool (WLST) ...
    [exec]
    [exec] Welcome to WebLogic Server Administration Scripting Shell
    [exec]
    [exec] Type help() for help on available commands
    [exec]
    [exec]
    [exec] Redeploy of Spaces Application started at Wed Mar 28 12:25:21 2012
    [exec]
    [exec] Connecting to t3://claptd01:7001 with userid weblogic ...
    [exec] Successfully connected to Admin Server 'AdminServer' that belongs to domain 'base_domain'.
    [exec]
    [exec] Warning: An insecure protocol was used to connect to the
    [exec] server. To ensure on-the-wire security, the SSL port or
    [exec] Admin port should be used instead.
    [exec]
    [exec] Redeploying application webcenter ...
    [exec] <Mar 28, 2012 12:25:28 PM EDT> <Info> <J2EE Deployment SPI> <BEA-260121> <Initiating redeploy operation for application, webcenter#11.1.1.4.0 [archive: null], to WC_Spaces .>
    [exec] [Deployer:149140]The task cannot be processed further until the current edit session is activated. When this occurs, task processing will continue. The user can exit the deployer tool without affecting the task.
    [exec] ..........................................Failed to redeploy the application with status failed
    [exec] Current Status of your Deployment:
    [exec] Deployment command type: redeploy
    [exec] Deployment State : failed
    [exec] Deployment Message : java.lang.Exception: [DeploymentService:290036]Deployment for request id '1332951945158' is deferred since target 'WC_Spaces' is disconnected.
    [exec] No stack trace available.
    [exec] None
    [exec] #########################################################
    [exec] ##### ReDeploy Spaces Failed #########
    [exec] ##### Contact support with Exception Stack #########
    [exec] #########################################################
    [exec]
    [exec]
    [exec] Exiting WebLogic Scripting Tool.
    [exec]
    [exec] <Mar 28, 2012 12:27:34 PM EDT> <Warning> <JNDI> <BEA-050001> <WLContext.close() was called in a different thread than the one in which it was created.>
    BUILD SUCCESSFUL
    Total time: 2 minutes 31 seconds
    Edited by: 891549 on Mar 29, 2012 12:01 PM

    I don't think that this error is based on ojsp.next mode. The first error I see is that the application can't be undeployed. After that you get the 'ava code in jsp source files is not allowed in ojsp.next mode.' error. As you said this only happens sometimes which also point to an other problem and not to the jsp error.
    Have you ask this on the {forum:id=354} forum?
    For me it's more a deployment/redeployment question.
    Timo

  • SQL in JSP - do I use JAVA code in % ... % or SQL Tag Library ??

    I have a small web app that makes needs to make about 12 SQL queries in a JSP and am trying to figure out what is the best way to do this
    I had initially coded this using plain JAVA code in the JSP as follows :-
    <%
    Connection conn = null;
    Statement st = null;
    ResultSet rs = null;
    try {
    st = conn.createStatement();
    rs = st.executeQuery("select .........");
    %>
    But then I came across the SQL Tag Library in an article and wonder if this is more efficient code?
    If so does anyone have a pointer to a good intro to these tags as they look complicated (I only am doing queries on the SQL database, no inserts or updates)

    Sometimes you've gotta do what you've gotta do.
    My rule is "no scriptlets".
    If you MUST access a database from a JSP, the only right way to do it is to use JSTL <sql> tags.
    %

  • Need JAVA code to create OIM ITresource-connection values are in a csv file

    Hi,
    Could any one plz help me with the java code used / tested before to create OIM IT resource dynamically, for the reference. IT resource parameter (connection) values in a .csv file, where in I've multiple environments.
    Thanks,
    Ramesh
    Edited by: user13267745 on Aug 19, 2010 12:37 AM

    Hi Gregg,
    You can create one transformation from the DataStore to itself.  In the "Technical" rules group, set 0RECORDMODE = 'X' (before image) or 'R' (reverse).  Therefore, when you execute its corresponding DTP, all existing records shouldl be set to zero.
    Then, as a second step, you can execute the DTP which is related to the transformation between the DataStore and the DataSource, thus loading the new records.
    I hope this helps you.
    Regards,
    Maximiliano

  • Where to put java code - Best Practice

    Hello. I am working with the Jdeveloper 11.2.2. I am trying to figure out the best practice for where to put code. After reviewing http://docs.oracle.com/cd/E26098_01/web.1112/e16182.pdf it seemed like the application module was the preferred spot (although many of the examples in the pdf are in main methods). After coding a while though, I noticed that there were quite a few libraries imported, and wondered whether this would impact performance.
    I reviewed postings on the forum, especially Re: Access service method (client interface) programmatically . This link mentions accessing code from a backing bean -- and the gist of the recommendations seems to be to use the data control to drag it to the JSF, or use the bindings to access code.
    My interest lies in where to put java code in the first place; In the View Object, Entity Object, and Am object, backing bean.....other?
    I can outline several best guesses about where to put code and the pros and cons:
    1. In the application module
    Pros: Centralized location for code makes development and support more simple as there are not multiple access points. Much like a data control centralizes services, the application module can act as a conduit for different pieces of code you have in objects in your model.
    Cons: Everything in one place means the application module becomes bloated. I am not sure how memory works in java -- if the app module has tons of different libraries are they all called when even a simple query re-execute method is called? Memory hog?
    2. Write code in the objects it affects. If you are writing code that accesses a view object, write it in a view object. Then make it visible to the client.
    pros: The code is accessed via fewer conduits (for example, I would expect that if you call the application module from a JSF backing bean, then the application module calls the view object, you have three different pieces of code --
    conts: The code gets spread out, harder to locate etc.
    I would greatly appreciate your thoughts on the matter.
    Regards,
    Stuart
    Edited by: Stuart Fleming on May 20, 2012 5:25 AM
    Edited by: Stuart Fleming on May 20, 2012 5:27 AM

    First point here is when you say "where to put the java code" and you're referring to ADF BC, the point is you put "business logic java code" in the ADF Business Components. It's fine of course to have Java code in the ViewController layer that deals with the UI layer. Just don't put business logic in the UI layer, and don't put UI logic in the model layer. In your 2 examples you seem to be considering the ADF BC layer only, so I'll assume you mean business logic java code only.
    Meanwhile I'm not keen on the term best practice as people follow best practices without thinking, typically best practices come with conditions and people forget to apply them. Luckily you're not doing that here as you've thought through the pros and cons of each (nice work).
    Anyway, back on topic and off my soap box, as for where to put your code, my thoughts:
    1) If you only have 1 or 2 methods put it in the AppModuleImpl
    2) If you have hundreds of methods, or there's a chance #1 above will morph into #2, split the code up between the AppModuleImpl, ViewImpl and ViewRowImpls. Why? Because your AM will become overloaded with hundreds of methods making it unreadable. Instead put the code where it should logically go. Methods that work on a specific VO row go into the associated ViewRowImpl, methods that work across rows in a VO go into the ViewImpl, and methods that work across VOs in the associated AppModuleImpl.
    To be honest which you ever option you choose, one thing I do recommend as a best practice is be consistent and document the standard so your other programmers know.
    Btw there isn't an issue about loading lots of libraries/imports into a class, it has no runtime cost. However if your methods require lots of class variables, then yes this will have a memory cost.
    On a side note if you're interested in more ideas around how to build ADF apps correctly think about joining the "ADF EMG", a free online forum which discusses ADF architecture, best practices (cough), deployment architectures and more.
    Regards,
    CM.

  • Association Rule : Settings in PL/SQL

    I've developed a model in ODM GUI for association rules.
    I'm now looking to develop the same in PL/SQL.
    I need to know how to specify the case id that has 2 attributes (CUST_ID and TIME_ID) and I have the PROD_ID as the ITEM ID. I have the following settings table and PLSQL
    BEGIN
    INSERT INTO assoc_sample_settings (setting_name, setting_value) VALUES
    (dbms_data_mining.algo_name, dbms_data_mining.ALGO_APRIORI_ASSOCIATION_RULES);
    INSERT into assoc_sample_settings (setting_name, setting_value) VALUES
    (dbms_data_mining.prep_auto, dbms_data_mining.prep_auto_on);
    INSERT into assoc_sample_settings (setting_name, setting_value) VALUES
    (ODMS_ITEM_ID_COLUMN_NAME, ‘PROD_ID’);
    END;
    DBMS_DATA_MINING.CREATE_MODEL(
    model_name => 'ASSOC_MODEL_2',
    mining_function => dbms_data_mining.association,
    data_table_name => 'SH.SALES',
    case_id_column_name => ‘CUST_ID, TIME_ID’,
    target_column_name => null,
    settings_table_name => 'assoc_sample_settings');
    Is this correct? for setting the CASE ID to 'CUST_ID, TIME_ID', is this correct and/or in the correct place
    Also the setting of the PROD_ID also correct?
    Do I need to use the ODMS_ITEM_VALUE_COLUMN_NAME setting ?

    Thank you for your reply, but it is still not working. There is the code that I have used for setting up and running. What is missing or incorrect with the following. The data is from the SH.SALES table.
    Settings Table
    BEGIN
    INSERT INTO assoc_sample_settings (setting_name, setting_value) VALUES
    (dbms_data_mining.algo_name, dbms_data_mining.ALGO_APRIORI_ASSOCIATION_RULES);
    INSERT into assoc_sample_settings (setting_name, setting_value) VALUES
    (dbms_data_mining.prep_auto, dbms_data_mining.prep_auto_off);
    INSERT into assoc_sample_settings (setting_name, setting_value) VALUES
    (dbms_data_mining.ODMS_ITEM_ID_COLUMN_NAME, ‘PROD_ID’);
    COMMIT;
    END;
    Create the view
    CREATE VIEW ASSOC_DATA_V AS (
    SELECT RANK() OVER (ORDER BY CUST_ID, TIME_ID) CASE_ID, t.*
    FROM SH.SALES t );
    Create the model
    BEGIN
    DBMS_DATA_MINING.CREATE_MODEL(
    model_name => 'ASSOC_MODEL_2',
    mining_function => DBMS_DATA_MINING.ASSOCIATION,
    data_table_name => 'ASSOC_DATA_V',
    case_id_column_name => ‘CASE_ID’,
    target_column_name => null,
    settings_table_name => 'assoc_sample_settings');
    END;
    BEGIN
    ERROR at line 1:
    ORA-40104: invalid training data for model build
    ORA-06512: at "SYS.DBMS_DATA_MINING", line 1798
    ORA-06512: at line 2
    Any ideas what is causing this?

  • Association Rules problem

    Hello,
    I have a problem with making association rules in Oracle 10g ODM. The problem is as follows:
    I have my test dataset for testing assoc. rules. I used that dataset before for testing assoc. rules models with Oracle 9i ODM release (9.2.0.4). And I have found significant number of rules within that dataset when I used Oracle 9i ODM (9.2.0.4.).
    But when I use Oracle 10g ODM to build an association rules model with the same set of parameters (min. support, min. confidence and max. rule length) I've got 0 rules.
    I can't find where is the problem, so I think that there is some sort of bug within Oracle 10g ODM.
    Does anyone have similar experience or have some explanation for this?
    Thnx in advance,
    Ivan

    What version of Data Miner are you using?
    If you are using the api directly, are you using the
    java or pl/sql api.
    Thanks, MarkI've been using Java API.
    I've continued my investigation of the mentioned problem and I have found that DMS throws following exception:
    ORA-38605: FI not enough memory (stringK) for candidate generation(stringK)
    Cause: There was insufficient available memory for candidate generation.
    Suggested action from Metalink is:
    In workarea_size_policy='manual' mode, set ficarea_size to a reasonably larger value. Or, in workarea_size_policy='auto' mode, set pga_aggregate_target to a reasonably larger value
    And I've increased the size of my SGA more than three times (from 128 to 512 MB), set work_area_policy=auto and set pga_aggregate_target to 20% of SGA .
    After that I've got following exception:
    ORA-40101: Data Mining System Error ODM_ASSOCIATION_MODEL-BUILD--20010
    ORA-06512: at "SYS.DBMS_SYS_ERROR", line 105
    ORA-06512: at "DMSYS.ODM_ASSOCIATION_RULE_MODEL", line 150
    ORA-06512: at "DMSYS.ODM_ASSOCIATION_RULE_MODEL", line 1299
    ORA-01452: cannot CREATE UNIQUE INDEX; duplicate keys found
    ORA-06512: at "DMSYS.ODM_ASSOCIATION_RULE_MODEL", line 1364
    ORA-06512: at line 1
    DMS throws this exception after longer time of task execution.
    Now, I don't know what to do further.
    I repeat that with the same dataset and same model parameters (support, confidence and max. rule length) I've got significant number of rules with ODMS within Oracle 9i database (9.2.0.4).
    Thnx,
    Ivo

  • Can a java code interact with trigger

    Hi guyz ,
    is there any way by which a trigger can interact with JDBC ?
    I want to check the database each time its updated and if some condition is violated , the info((row from table which has voilated some rule) is passed to java code which can then take necessary action . Can anyone help me out in this because i am not aware of any way by which a trigger can interact with java code .
    Regards,
    Nikhi

    nikhil456123 wrote:
    Hi guyz ,
    is there any way by which a trigger can interact with JDBC ?
    I want to check the database each time its updated and if some condition is violated , the info((row from table which has voilated some rule) is passed to java code which can then take necessary action . Can anyone help me out in this because i am not aware of any way by which a trigger can interact with java code .Note that even though it might be possible you might want to consider that it isn't necessarily a good idea.
    Say the action is "send email". Then every time an insert/update/delete occurs then an email is sent. That would obviously slow down those operations a lot. Not to mention that if 1000 inserts occur then someone is going to get 1000 emails.
    There can be alternatives that are much better.

  • Color names in Java code format.  Looking for the 216 safe colors.

    Color names and associated values are available in HTML format; I am looking for such a list in Java code.
    thanks for any help.

    // Since I could not find it, I pasted it up myself.
    // Since I think it is useful and cool, I am sharing it.
    import java.awt.Color;
    Java class of the standard non-standard "safe" browser colors.
    View and choose colors grouped by color at
    <http://halflife.ukrpack.net/csfiles/help/colors.shtml>
    or others.
    Colors in this alpha ordered list are presumed to correspond.
    public class Colors {
    public static final Color AliceBlue = rgb("F0F8FF");
    public static final Color AntiqueWhite = rgb("FAEBD7");
    public static final Color Aqua = rgb("00FFFF");
    public static final Color Aquamarine = rgb("7FFFD4");
    public static final Color Azure = rgb("F0FFFF");
    public static final Color Beige = rgb("F5F5DC");
    public static final Color Bisque = rgb("FFE4C4");
    public static final Color Black = rgb("000000");
    public static final Color BlanchedAlmond = rgb("FFEBCD");
    public static final Color Blue = rgb("0000FF");
    public static final Color BlueViolet = rgb("8A2BE2");
    public static final Color Brown = rgb("A52A2A");
    public static final Color BurlyWood = rgb("DEB887");
    public static final Color CadetBlue = rgb("5F9EA0");
    public static final Color Chartreuse = rgb("7FFF00");
    public static final Color Chocolate = rgb("D2691E");
    public static final Color Coral = rgb("FF7F50");
    public static final Color CornflowerBlue = rgb("6495ED");
    public static final Color Cornsilk = rgb("FFF8DC");
    public static final Color Crimson = rgb("DC143C");
    public static final Color Cyan = rgb("00FFFF");
    public static final Color DarkBlue = rgb("00008B");
    public static final Color DarkCyan = rgb("008B8B");
    public static final Color DarkGoldenRod = rgb("B8860B");
    public static final Color DarkGray = rgb("A9A9A9");
    public static final Color DarkGreen = rgb("006400");
    public static final Color DarkKhaki = rgb("BDB76B");
    public static final Color DarkMagenta = rgb("8B008B");
    public static final Color DarkOliveGreen = rgb("556B2F");
    public static final Color Darkorange = rgb("FF8C00");
    public static final Color DarkOrchid = rgb("9932CC");
    public static final Color DarkRed = rgb("8B0000");
    public static final Color DarkSalmon = rgb("E9967A");
    public static final Color DarkSeaGreen = rgb("8FBC8F");
    public static final Color DarkSlateBlue = rgb("483D8B");
    public static final Color DarkSlateGray = rgb("2F4F4F");
    public static final Color DarkTurquoise = rgb("00CED1");
    public static final Color DarkViolet = rgb("9400D3");
    public static final Color DeepPink = rgb("FF1493");
    public static final Color DeepSkyBlue = rgb("00BFFF");
    public static final Color DimGray = rgb("696969");
    public static final Color DodgerBlue = rgb("1E90FF");
    public static final Color Feldspar = rgb("D19275");
    public static final Color FireBrick = rgb("B22222");
    public static final Color FloralWhite = rgb("FFFAF0");
    public static final Color ForestGreen = rgb("228B22");
    public static final Color Fuchsia = rgb("FF00FF");
    public static final Color Gainsboro = rgb("DCDCDC");
    public static final Color GhostWhite = rgb("F8F8FF");
    public static final Color Gold = rgb("FFD700");
    public static final Color GoldenRod = rgb("DAA520");
    public static final Color Gray = rgb("808080");
    public static final Color Green = rgb("008000");
    public static final Color GreenYellow = rgb("ADFF2F");
    public static final Color HoneyDew = rgb("F0FFF0");
    public static final Color HotPink = rgb("FF69B4");
    public static final Color IndianRed = rgb("CD5C5C");
    public static final Color Indigo = rgb("4B0082");
    public static final Color Ivory = rgb("FFFFF0");
    public static final Color Khaki = rgb("F0E68C");
    public static final Color Lavender = rgb("E6E6FA");
    public static final Color LavenderBlush = rgb("FFF0F5");
    public static final Color LawnGreen = rgb("7CFC00");
    public static final Color LemonChiffon = rgb("FFFACD");
    public static final Color LightBlue = rgb("ADD8E6");
    public static final Color LightCoral = rgb("F08080");
    public static final Color LightCyan = rgb("E0FFFF");
    public static final Color LightGoldenRodYellow = rgb("FAFAD2");
    public static final Color LightGrey = rgb("D3D3D3");
    public static final Color LightGreen = rgb("90EE90");
    public static final Color LightPink = rgb("FFB6C1");
    public static final Color LightSalmon = rgb("FFA07A");
    public static final Color LightSeaGreen = rgb("20B2AA");
    public static final Color LightSkyBlue = rgb("87CEFA");
    public static final Color LightSlateBlue = rgb("8470FF");
    public static final Color LightSlateGray = rgb("778899");
    public static final Color LightSteelBlue = rgb("B0C4DE");
    public static final Color LightYellow = rgb("FFFFE0");
    public static final Color Lime = rgb("00FF00");
    public static final Color LimeGreen = rgb("32CD32");
    public static final Color Linen = rgb("FAF0E6");
    public static final Color Magenta = rgb("FF00FF");
    public static final Color Maroon = rgb("800000");
    public static final Color MediumAquaMarine = rgb("66CDAA");
    public static final Color MediumBlue = rgb("0000CD");
    public static final Color MediumOrchid = rgb("BA55D3");
    public static final Color MediumPurple = rgb("9370D8");
    public static final Color MediumSeaGree = rgb("3CB371");
    public static final Color MediumSlateBlue = rgb("7B68EE");
    public static final Color MediumSpringGreen = rgb("00FA9A");
    public static final Color MediumTurquoise = rgb("48D1CC");
    public static final Color MediumVioletRed = rgb("C71585");
    public static final Color MidnightBlue = rgb("191970");
    public static final Color MintCream = rgb("F5FFFA");
    public static final Color MistyRose = rgb("FFE4E1");
    public static final Color Moccasin = rgb("FFE4B5");
    public static final Color NavajoWhite = rgb("FFDEAD");
    public static final Color Navy = rgb("000080");
    public static final Color OldLace = rgb("FDF5E6");
    public static final Color Olive = rgb("808000");
    public static final Color OliveDrab = rgb("6B8E23");
    public static final Color Orange = rgb("FFA500");
    public static final Color OrangeRed = rgb("FF4500");
    public static final Color Orchid = rgb("DA70D6");
    public static final Color PaleGoldenRod = rgb("EEE8AA");
    public static final Color PaleGreen = rgb("98FB98");
    public static final Color PaleTurquoise = rgb("AFEEEE");
    public static final Color PaleVioletRed = rgb("D87093");
    public static final Color PapayaWhip = rgb("FFEFD5");
    public static final Color PeachPuff = rgb("FFDAB9");
    public static final Color Peru = rgb("CD853F");
    public static final Color Pink = rgb("FFC0CB");
    public static final Color Plum = rgb("DDA0DD");
    public static final Color PowderBlue = rgb("B0E0E6");
    public static final Color Purple = rgb("800080");
    public static final Color Red = rgb("FF0000");
    public static final Color RosyBrown = rgb("BC8F8F");
    public static final Color RoyalBlue = rgb("4169E1");
    public static final Color SaddleBrown = rgb("8B4513");
    public static final Color Salmon = rgb("FA8072");
    public static final Color SandyBrown = rgb("F4A460");
    public static final Color SeaGreen = rgb("2E8B57");
    public static final Color SeaShell = rgb("FFF5EE");
    public static final Color Sienna = rgb("A0522D");
    public static final Color Silver = rgb("C0C0C0");
    public static final Color SkyBlue = rgb("87CEEB");
    public static final Color SlateBlue = rgb("6A5ACD");
    public static final Color SlateGray = rgb("708090");
    public static final Color Snow = rgb("FFFAFA");
    public static final Color SpringGreen = rgb("00FF7F");
    public static final Color SteelBlue = rgb("4682B4");
    public static final Color Tan = rgb("D2B48C");
    public static final Color Teal = rgb("008080");
    public static final Color Thistle = rgb("D8BFD8");
    public static final Color Tomato = rgb("FF6347");
    public static final Color Turquoise = rgb("40E0D0");
    public static final Color Violet = rgb("EE82EE");
    public static final Color VioletRed = rgb("D02090");
    public static final Color Wheat = rgb("F5DEB3");
    public static final Color White = rgb("FFFFFF");
    public static final Color WhiteSmoke = rgb("F5F5F5");
    public static final Color Yellow = rgb("FFFF00");
    public static final Color YellowGreen = rgb("9ACD32");
    public Colors() {  }
    private static Color rgb(String hexValue){
    return(new Color(
    Integer.parseInt(hexValue.substring(0, 2), 16),
    Integer.parseInt(hexValue.substring(2, 4), 16),
    Integer.parseInt(hexValue.substring(4), 16)));

Maybe you are looking for

  • How to Fatch value of CIN  condition Type in PO

    Hi All,          I have fatched  data for MM condition type From KONV but now i also want to fatch data of Condition Type ( CIN ) of PO , which related to Tax Code and appears in invoice tab of PO item details.          Please show me the way... Than

  • Using an external ethernet hard disk to store photos

    I would like to use an external hard disk to view my photos with iphoto from different macs connected to the ethernet external hardisk Is it possible? and how should I set my machines? thanks , Luciano

  • Getting a single line from a JTextArea

    I have a JTextArea with a fixed size. I've used the .setLineWrap(true) and .setWrapStyleWord(true) on this JTextArea, so when the user types in some text, that's longer that the JTextArea, it will wrap unto the next line. I need to get each visible l

  • Catching an exception in an JSF page

    Hi, I have made the following example: In my jsf page I have: <a4j:commandButton id="save" action="#{settings.save}" reRender="attributes" /> <h:outputLabel value="Save" for="save" /> <table width="100%" cellpadding="0" cellspacing="0"> <!-- <tr> <td

  • Network DR test causes Exchange DAG network to fail (Failover Cluster Manager reports comms errors)

    We have a DAG configured between 2 mailbox servers, one in each of our main data centres. Our comms team recently performed a DR test between our 2 data centres, switiching from the main production link to the backup link. During this outage the Fail