Got exception while using a command parameter in subreport

Hi All,
I've make a report with some subreport full ODBC based(master report and all the sub report have a ODBC database source).
The main report has a parameter 'a'. I linkened the parameter 'a' from the main report to the sub report and used it as a parameter at the command (query).There are no problems when I work at the crystal designer.
For my purposes i need to change the datasource at runtime to JDBC. If i try to change at runtime the dasource using the standard ChangeDataSource method (the same in CRJavaHelper.java file) i've got the exeception :
JRCCommunicationAdapter:  detected an exception: java.lang.NullPointerException
        at com.crystaldecisions.reports.reportdefinition.ParameterFieldDefinition.qJ(Unknown Source)
        at com.crystaldecisions.reports.reportdefinition.ParameterFieldDefinition.qL(Unknown Source)
The Problem is because the subreport use the parameter  as a command
After that I tried Ted solution mentioned in the thread:
Runtime Change datasource problem with JDBC report
but with no success, after that i continued investigating and i found that the report parameter field defined inside the command of the subreport was changed and no more linked to the subreport parameter field.
Thanks
Shehab

Hi All,
I've make a report with some subreport full ODBC based(master report and all the sub report have a ODBC database source).
The main report has a parameter 'a'. I linkened the parameter 'a' from the main report to the sub report and used it as a parameter at the command (query).There are no problems when I work at the crystal designer.
For my purposes i need to change the datasource at runtime to JDBC. If i try to change at runtime the dasource using the standard ChangeDataSource method (the same in CRJavaHelper.java file) i've got the exeception :
JRCCommunicationAdapter:  detected an exception: java.lang.NullPointerException
        at com.crystaldecisions.reports.reportdefinition.ParameterFieldDefinition.qJ(Unknown Source)
        at com.crystaldecisions.reports.reportdefinition.ParameterFieldDefinition.qL(Unknown Source)
The Problem is because the subreport use the parameter  as a command
After that I tried Ted solution mentioned in the thread:
Runtime Change datasource problem with JDBC report
but with no success, after that i continued investigating and i found that the report parameter field defined inside the command of the subreport was changed and no more linked to the subreport parameter field.
Thanks
Shehab

Similar Messages

  • Exception while using unit of work commit

    Hi,
    I have using this code to create a object
    KbAdAlerts alert = new KbAdAlerts();
    alert.setAlertId(kmData.getAlertId());
    alert.setAlertDesc(kmData.getOutcome());
    alert.setAlertLastRevisionDate(KmUtils.convertReviewDate(kmData.getReviewDate()));
    alert.setAlertType(kmData.getAlertType());
    System.out.println("Alert Object :" + alert);
    KbAdAlerts alertClone = (KbAdAlerts) uow.registerObject(alert);
    System.out.println("Clone Alert:" + alertClone);
    uow.printRegisteredObjects();
    uow.commit();
    I am getting exception while using uow.commit(). I have gone into alert object and everything seems to be fine.
    Could you help me in this issue.
    Thanks,
    Ashish
    Exception [TOPLINK-4002] (Oracle TopLink - 10g Release 3 (10.1.3.0.0) (Build 060118)): oracle.toplink.exceptions.DatabaseException
    Internal Exception: java.sql.SQLException: ORA-01400: cannot insert NULL into ("AD_OWNER"."KB_AD_ALERTS"."ALERT_ID")
    Error Code: 1400
    Call:insert into kb_ad_alerts(alert_id, alert_desc, alert_type, alert_last_revision_date)
    values
    (NULL, NULL, NULL, NULL)
    Query:InsertObjectQuery(oracle.ccr.admin.model.KbAdAlerts@6108)
         at oracle.toplink.exceptions.TopLinkException.<init>(TopLinkException.java:46)
         at oracle.toplink.exceptions.DatabaseException.<init>(DatabaseException.java:50)
         at oracle.toplink.exceptions.DatabaseException.sqlException(DatabaseException.java:282)
         at oracle.toplink.internal.databaseaccess.DatabaseAccessor.executeDirectNoSelect(DatabaseAccessor.java:658)
         at oracle.toplink.internal.databaseaccess.DatabaseAccessor.executeNoSelect(DatabaseAccessor.java:707)
         at oracle.toplink.internal.databaseaccess.DatabaseAccessor.basicExecuteCall(DatabaseAccessor.java:496)
         at oracle.toplink.internal.databaseaccess.DatabaseAccessor.executeCall(DatabaseAccessor.java:442)
         at oracle.toplink.publicinterface.UnitOfWork.executeCall(UnitOfWork.java:1603)
         at oracle.toplink.internal.queryframework.DatasourceCallQueryMechanism.executeCall(DatasourceCallQueryMechanism.java:117)
         at oracle.toplink.internal.queryframework.DatasourceCallQueryMechanism.executeCall(DatasourceCallQueryMechanism.java:103)
         at oracle.toplink.internal.queryframework.DatasourceCallQueryMechanism.insertObject(DatasourceCallQueryMechanism.java:238)
         at oracle.toplink.internal.queryframework.DatabaseQueryMechanism.insertObject(DatabaseQueryMechanism.java:355)
         at oracle.toplink.internal.queryframework.DatabaseQueryMechanism.insertObjectForWrite(DatabaseQueryMechanism.java:433)
         at oracle.toplink.queryframework.InsertObjectQuery.executeCommit(InsertObjectQuery.java:60)
         at oracle.toplink.internal.queryframework.DatabaseQueryMechanism.performUserDefinedWrite(DatabaseQueryMechanism.java:622)
         at oracle.toplink.internal.queryframework.DatabaseQueryMechanism.performUserDefinedInsert(DatabaseQueryMechanism.java:586)
         at oracle.toplink.internal.queryframework.DatabaseQueryMechanism.insertObjectForWriteWithChangeSet(DatabaseQueryMechanism.java:479)
         at oracle.toplink.queryframework.WriteObjectQuery.executeCommitWithChangeSet(WriteObjectQuery.java:110)
         at oracle.toplink.internal.queryframework.DatabaseQueryMechanism.executeWriteWithChangeSet(DatabaseQueryMechanism.java:259)
         at oracle.toplink.queryframework.WriteObjectQuery.executeDatabaseQuery(WriteObjectQuery.java:47)
         at oracle.toplink.queryframework.DatabaseQuery.execute(DatabaseQuery.java:603)
         at oracle.toplink.queryframework.DatabaseQuery.executeInUnitOfWork(DatabaseQuery.java:519)
         at oracle.toplink.queryframework.ObjectLevelModifyQuery.executeInUnitOfWorkObjectLevelModifyQuery(ObjectLevelModifyQuery.java:100)
         at oracle.toplink.queryframework.ObjectLevelModifyQuery.executeInUnitOfWork(ObjectLevelModifyQuery.java:72)
         at oracle.toplink.publicinterface.UnitOfWork.internalExecuteQuery(UnitOfWork.java:2532)
         at oracle.toplink.publicinterface.Session.executeQuery(Session.java:981)
         at oracle.toplink.publicinterface.Session.executeQuery(Session.java:938)
         at oracle.toplink.internal.sessions.CommitManager.commitNewObjectsForClassWithChangeSet(CommitManager.java:240)
         at oracle.toplink.internal.sessions.CommitManager.commitAllObjectsWithChangeSet(CommitManager.java:161)
         at oracle.toplink.publicinterface.Session.writeAllObjectsWithChangeSet(Session.java:3123)
         at oracle.toplink.publicinterface.UnitOfWork.commitToDatabase(UnitOfWork.java:1242)
         at oracle.toplink.publicinterface.UnitOfWork.commitToDatabaseWithChangeSet(UnitOfWork.java:1330)
         at oracle.toplink.publicinterface.UnitOfWork.commitRootUnitOfWork(UnitOfWork.java:1097)
         at oracle.toplink.publicinterface.UnitOfWork.commit(UnitOfWork.java:865)
         at oracle.ccr.admin.model.FeedbackServices.writeFeedback(FeedbackServices.java:116)
         at oracle.ccr.admin.view.AlertDetails.updateTables(AlertDetails.java:834)
         at oracle.ccr.admin.view.AlertDetails.commandButton1_action(AlertDetails.java:822)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:585)
         at com.sun.faces.el.MethodBindingImpl.invoke(MethodBindingImpl.java:126)
         at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:72)
         at oracle.adf.view.faces.component.UIXCommand.broadcast(UIXCommand.java:211)
         at oracle.adf.view.faces.component.UIXCollection.broadcast(UIXCollection.java:94)
         at oracle.adf.view.faces.component.UIXTable.broadcast(UIXTable.java:205)
         at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:267)
         at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:381)
         at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:75)
         at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:200)
         at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:90)
         at javax.faces.webapp.FacesServlet.service(FacesServlet.java:197)
         at com.evermind.server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:64)
         at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._invokeDoFilter(AdfFacesFilterImpl.java:367)
         at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._doFilterImpl(AdfFacesFilterImpl.java:336)
         at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl.doFilter(AdfFacesFilterImpl.java:196)
         at oracle.adf.view.faces.webapp.AdfFacesFilter.doFilter(AdfFacesFilter.java:87)
         at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:629)
         at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:376)
         at com.evermind.server.http.HttpRequestHandler.doProcessRequest(HttpRequestHandler.java:870)
         at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:451)
         at com.evermind.server.http.HttpRequestHandler.serveOneRequest(HttpRequestHandler.java:218)
         at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:119)
         at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:112)
         at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run(ServerSocketReadHandler.java:260)
         at oracle.oc4j.network.ServerSocketAcceptHandler.procClientSocket(ServerSocketAcceptHandler.java:230)
         at oracle.oc4j.network.ServerSocketAcceptHandler.access$800(ServerSocketAcceptHandler.java:33)
         at oracle.oc4j.network.ServerSocketAcceptHandler$AcceptHandlerHorse.run(ServerSocketAcceptHandler.java:831)
         at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
         at java.lang.Thread.run(Thread.java:595)

    Hi,
    I am having a similar problem that results in this stack trace. The funny thing is that it occurs after a session.logout/login and re-read of the object I'm trying to update. The other thing is that if I remove objects from the transaction it just happens somewhere else - on a different object/descriptor. I am attempting to upgrade from 9.03 runtime to the 10.0.3.1 builder/runtime. I am connecting to a Sybase 12.5 db.
    Any ideas on this one?
    Thanks,
    Bret
    This is the sql that is found in the DatasourceCallQueryMechanism. We are not using any custom SQL.
    SQLCall(INSERT INTO Invoice (id, description, billingAddress, customerNote, invoiceNumber, startDate, stopDate, sentDate, commitDate, customerId, dueDate) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?))
    java.lang.NullPointerException
         at oracle.toplink.internal.queryframework.DatasourceCallQueryMechanism.insertObject(DatasourceCallQueryMechanism.java:213)
         at oracle.toplink.internal.queryframework.StatementQueryMechanism.insertObject(StatementQueryMechanism.java:156)
         at oracle.toplink.internal.queryframework.StatementQueryMechanism.insertObject(StatementQueryMechanism.java:170)
         at oracle.toplink.internal.queryframework.DatabaseQueryMechanism.insertObjectForWrite(DatabaseQueryMechanism.java:426)
         at oracle.toplink.queryframework.InsertObjectQuery.executeCommit(InsertObjectQuery.java:65)
         at oracle.toplink.queryframework.InsertObjectQuery.executeCommitWithChangeSet(InsertObjectQuery.java:75)
         at oracle.toplink.internal.queryframework.DatabaseQueryMechanism.executeWriteWithChangeSet(DatabaseQueryMechanism.java:251)
         at oracle.toplink.queryframework.WriteObjectQuery.executeDatabaseQuery(WriteObjectQuery.java:47)
         at oracle.toplink.queryframework.DatabaseQuery.execute(DatabaseQuery.java:620)
         at oracle.toplink.queryframework.DatabaseQuery.executeInUnitOfWork(DatabaseQuery.java:542)
         at oracle.toplink.queryframework.ObjectLevelModifyQuery.executeInUnitOfWorkObjectLevelModifyQuery(ObjectLevelModifyQuery.java:100)
         at oracle.toplink.queryframework.ObjectLevelModifyQuery.executeInUnitOfWork(ObjectLevelModifyQuery.java:72)
         at oracle.toplink.publicinterface.UnitOfWork.internalExecuteQuery(UnitOfWork.java:2578)
         at oracle.toplink.publicinterface.Session.executeQuery(Session.java:988)
         at oracle.toplink.publicinterface.Session.executeQuery(Session.java:945)
         at oracle.toplink.internal.sessions.CommitManager.commitNewObjectsForClassWithChangeSet(CommitManager.java:243)
         at oracle.toplink.internal.sessions.CommitManager.commitAllObjectsForClassWithChangeSet(CommitManager.java:218)
         at oracle.toplink.internal.sessions.CommitManager.commitAllObjectsWithChangeSet(CommitManager.java:174)
         at oracle.toplink.publicinterface.Session.writeAllObjectsWithChangeSet(Session.java:3177)
         at oracle.toplink.publicinterface.UnitOfWork.commitToDatabase(UnitOfWork.java:1282)
         at oracle.toplink.publicinterface.UnitOfWork.commitToDatabaseWithChangeSet(UnitOfWork.java:1370)
         at oracle.toplink.publicinterface.UnitOfWork.commitRootUnitOfWork(UnitOfWork.java:1137)
         at oracle.toplink.publicinterface.UnitOfWork.commit(UnitOfWork.java:905)
         at com.tbs.database.DBBroker.mergeSingleObject(DBBroker.java:288)
         at com.tbs.database.DBBroker.merge(DBBroker.java:235)
         at com.tbs.database.DBBrokerSetInvoker.merge(DBBrokerSetInvoker.java:73)
         at com.tbs.database.TbsDataSource.merge(TbsDataSource.java:353)
    /////////////////////////////////

  • Invalid_path exception while using UTL_FILE.FOPEN

    Hi
    I am getting invalid_path exception while using the UTL_FILE.fopen subprogram. I tried finding out the reason but could not solve it. Please help.
    Below is my piece of code.
    create directory utldr as 'e:\utldir';
    declare
    f utl_file.file_type;
    s varchar2(200);
    begin
    dbms_output.put_line('1');
    f := utl_file.fopen('UTLDR','utlfil.txt','r');
    dbms_output.put_line('2');
    utl_file.get_line(f,s);
    dbms_output.put_line('3');
    utl_file.fclose(f);
    dbms_output.put_line('4');
    dbms_output.put_line(s);
    exception
    when utl_file.invalid_path then
    dbms_output.put_line('invalid_path');
    end;
    the result is:
    1
    invalid_path

    I am executing it from sys. The same user who created the directory.
    The output is as below:
    SELECT * FROM dba_directories
    OWNER     DIRECTORY_NAME     DIRECTORY_PATH
    SYS     MEDIA_DIR      d:\avale\rel4\demo\schema\product_media\
    SYS     LOG_FILE_DIR     d:\avale\rel4\assistants\dbca\logs\
    SYS     DATA_FILE_DIR     d:\avale\rel4\demo\schema\sales_history\
    SYS     EMP_DIR     E:\Oracle Directory
    SYS     REMOTED     \\10.1.1.12\oracle directory
    SYS     UTLDR     e:\utldir
    SELECT * FROM dba_tab_privs WHERE table_name='UTLDR'
    GRANTEE     OWNER     TABLE_NAME     GRANTOR     PRIVILEGE     GRANTABLE     HIERARCHY
    PUBLIC     SYS     UTLDR     SYS     READ     NO     NO

  • Exception while using Nested types in Oracle

    Hi All,
    I am getting an exception while trying to use Nested types in Oracle. The same thing works in other systems. So it might be some problem with my configuration. Can anyone please help me out with this one. Thanks in advance..
    java.sql.SQLException: Internal Error
    at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:112)
    at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:146)
    at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:208)
    at oracle.jdbc.oracore.OracleTypeCOLLECTION.initCollElemTypeName(OracleTypeCOLLECTION.java:1074)
    at oracle.jdbc.oracore.OracleTypeCOLLECTION.getAttributeType(OracleTypeCOLLECTION.java:1107)
    at oracle.jdbc.oracore.OracleNamedType.getFullName(OracleNamedType.java:81)
    at oracle.jdbc.oracore.OracleNamedType.getFullName(OracleNamedType.java:68)
    at oracle.sql.TypeDescriptor.initSQLName(TypeDescriptor.java:237)
    at oracle.sql.TypeDescriptor.getName(TypeDescriptor.java:198)
    at oracle.sql.StructDescriptor.getClass(StructDescriptor.java:1105)
    at oracle.sql.STRUCT.toJdbc(STRUCT.java:574)
    at oracle.jdbc.oracore.OracleTypeUPT.unpickle81UPT(OracleTypeUPT.java:502)
    at oracle.jdbc.oracore.OracleTypeUPT.unpickle81rec(OracleTypeUPT.java:456)
    at oracle.jdbc.oracore.OracleTypeCOLLECTION.unpickle81ImgBodyElements(OracleTypeCOLLECTION.java:1011)
    at oracle.jdbc.oracore.OracleTypeCOLLECTION.unpickle81ImgBody(OracleTypeCOLLECTION.java:952)
    at oracle.jdbc.oracore.OracleTypeCOLLECTION.unpickle81(OracleTypeCOLLECTION.java:764)
    at oracle.jdbc.oracore.OracleTypeCOLLECTION.unlinearizeInternal(OracleTypeCOLLECTION.java:243)
    at oracle.jdbc.oracore.OracleTypeCOLLECTION.unlinearize(OracleTypeCOLLECTION.java:217)
    at oracle.sql.ArrayDescriptor.toJavaArray(ArrayDescriptor.java:891)
    at oracle.sql.ARRAY.getArray(ARRAY.java:315)
    at weblogic.jdbc.wrapper.Array_oracle_sql_ARRAY.getArray(Unknown Source)
    Regards,
    Praveen G S

    Ok .. i got around this issue myself ..
    For others who might have had to face the same problem, let me tell them the problem that i had... i ll b happy if it helps someone ...
    The issue was improper privleges of the Nested Types in the schema to which my server was connecting. Once proper privelges were given, everything started working just fine ...

  • Dabase link while using copy command in Oracle 9i

    Hi,
    Is it must to have a database link while copying data between two databases in Oracle 9i using COPY command?
    I am using the copy command like following:
    SQL> copy from xxx/xxx@xyz to abc/abc@stu insert Table using select * from Table
    Database link is always required in Oracle 9i to copy data ?
    rgds,
    Karna

    When you use the copy command, all you need is that both databases are in the tnsnames.ora file and you can commect using the username/password#sid string. The copy command doesn't use the DBlink.

  • Security Exception while using OIM client API with Webcenter

    Hi,
    We are using OIM 11g Client api for creating user from our WebCenter portal application. But we are getting security as well as no such service exception while calling login from the OIM client.
    Exception::
    oracle.iam.platform.utils.NoSuchServiceException: java.lang.reflect.InvocationTargetException
         at oracle.iam.platform.OIMClient.getServiceDelegate(OIMClient.java:197)
         at oracle.iam.platform.OIMClient.getService(OIMClient.java:174)
         at oracle.iam.platform.OIMClient.loginSessionCreated(OIMClient.java:209)
         at oracle.iam.platform.OIMClient.login(OIMClient.java:136)
         at oracle.iam.platform.OIMClient.login(OIMClient.java:114)
    Caused by: java.lang.reflect.InvocationTargetException
         at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
         at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
         at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
         at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
         at oracle.iam.platform.OIMClient.getServiceDelegate(OIMClient.java:193)
    Caused by: java.lang.SecurityException: [Security:090398]Invalid Subject: principals=[weblogic, Administrators]
         at weblogic.rjvm.ResponseImpl.unmarshalReturn(ResponseImpl.java:234)
    oracle.iam.platform.utils.NoSuchServiceException: java.lang.reflect.InvocationTargetException
    Client Code::
    System.setProperty("java.security.auth.login.config", "Path to authwl.conf");
    System.setProperty("OIM.AppServerType", "weblogic");
    env = new Hashtable();
    env.put(OIMClient.JAVA_NAMING_FACTORY_INITIAL,"weblogic.jndi.WLInitialContextFactory");
    env.put(OIMClient.JAVA_NAMING_PROVIDER_URL, "t3://host:14000/oim");
    client = new OIMClient(env);
    try {
    client.login(OIMUserName, OIMPassword);
    } catch (LoginException e) {
    e.printStackTrace();
    The exception is coming after executing the login code (not login exception).We logged into our application using weblogic user(even for any other user in OID,shared by OIM, is having same behaviour). The code is being executed from integrated webogic server and oim_server is running on a different server under a separate domain.
    Please suggest.
    Thanks

    There are files needed in your project.
    from the <OIMHOME>/config folder_
    xl.policy
    authwl.conf
    log.properties
    from the <OIMHOME>/ext folder_
    commons-logging.jar
    jakarta-oro-2.0.8.jar
    javagroups-all.jar
    jhall.jar
    log4j-1.2.8.jar
    mail.jar
    oscache.jar
    spring.jar
    wlfullclient.jar
    from the <OIMHOME>/lib folder_
    iam-platform-auth-client.jar
    iam-platform-context.jar
    iam-platform-pluginframework.jar
    iam-platform-utils.jar
    oimclient.jar
    XellerateClient.jar
    xlAPI.jar
    xlDataObjectBeans.jar
    xlUtils.jar
    xlVO.jar

  • Getting Errors while using IMPDP command in UNIX

    Hi All,
    My work involves Refreshing of DB with latest Data. For this i am using IMPDP command to import the data. But Every time during refresh i will get errors saying like "oracle Generated Errors Oracle Not available".
    I don't know what is the reason for getting this error, and that too my db goes down after this error. Again i will startup the db , and i will try my luck to complete the process.
    so please tell me what are the actual problems that might cause the IMPDP to be failed.
    with one advise , i have stopped my listener and done the importing, Interestingly this time IMPDP works without errors. But this is also not always working.
    But i feel that every time starting and stopping the listener is not the correct solution.
    so please help me in this regard.
    Regards
    Naveen R.

    The error i am getting is...
    UDI-03113: operation generated ORACLE error 3113
    ORA-03113: end-of-file on communication channel
    Process ID: 6208
    Session ID: 346 Serial number: 298
    UDI-03114: operation generated ORACLE error 3114
    ORA-03114: not connected to ORACLE
    [user1@node1 cpt]$
    DB version is 11.1.0.6.0
    os is.. Red Hat Linux

  • Coppy commit while using copy command

    I am seeing the following message when I used Copy command in Oracle 9i.
    Array fetch/bind size is 15 (arraysize is 15)
    Will commit when done (coppycommit is 0)
    Maximum long size is 80 (long is 80)
    Could someone tell what does it mean and is there any harm with coppycommit being ZERO ? If so how we could change it ?
    DBA was telling the following:
    In using the copy command in oracle, not specifying 'arraysize' and 'copycommit' attributes for large records will blow up the rollback segment and return errors.
    thanks,
    Karna

    SQL> show copycommit
    copycommit 0
    SQL>
    SQL> set copycommit 5000
    SQL>
    SQL> show copycommit
    copycommit 5000
    SQL>
    SQL> show arraysize
    arraysize 15
    SQL>
    SQL> set arraysize 100
    SQL>
    SQL> show arraysize
    arraysize 100
    SQL>
    SQL> show long
    long 80
    SQL>
    SQL> set long 40000
    SQL>
    SQL> show long
    long 40000
    SQL>You rollback size must be in suitably sized for the type of work you are doing. A commit in batches may or may not avoid blowing the rollback segments. A commit in batches does not gurantee not to blowup the RBS.

  • Error while using "ant" command in weblogic6.1

    Hi,
    when I try to build the build.xml file in Weblogic 6.1 using "ant" command in
    samples\ejb20\basic\ContainerManaged
    I'm getting the following error. Pls help me out
    Error
    compile_ejb:
    [javac] Compiling 4 source files to D:\bea\wlserver6.1\samples\examples\ejb2
    0\basic\containerManaged\build
    [javac] D:\bea\wlserver6.1\samples\examples\ejb20\basic\containerManaged\Acc
    ount.java:17: cannot access java.lang.Object
    [javac] bad class file: D:\JDK1.4\JRE\lib\rt.jar(java/lang/Object.class)
    [javac] class file has wrong version 48.0, should be 47.0
    [javac] Please remove or make sure it appears in the correct subdirectory of
    the classpath.
    [javac] public interface Account extends EJBObject {
    [javac] ^
    [javac] 1 error
    BUILD FAILED
    Please Help me out
    Thanks & Regards
    Venki

    Weblogic 6.1 does not support JDK 1.4. Use 1.3

  • Datatype problem while using copy command

    Hi all,
    I an using copy command to copy data
    SQL> copy from xyz/abc@xxx to aaa/sss@aaa create Table1(Name,duration) using select * from Table2The problme is in Table2 duration is like 4.5,but when after copying in Table1 it is coming as 4 .
    Could someone help me in fixing this ?
    rgds,
    Karna

    try not defining the columns first, the create will do that.
    copy from xyz/abc@xxx to aaa/sss@aaa create Table1 using select * from Table2
    I am assuming the table2 only contains the two columns.

  • Exception while using Tomahawk

    I am using tomahawk datalist in a page. All works fine and data is also displaying on the page but i am getting the following exception:
    SEVERE: Error while serving resource: prototype.PrototypeResourceLoader/prototype.js, message : null
    ClientAbortException: java.net.SocketException: Connection reset by peer: socket write error
         at org.apache.catalina.connector.OutputBuffer.doFlush(OutputBuffer.java:327)
         at org.apache.catalina.connector.OutputBuffer.flush(OutputBuffer.java:293)
         at org.apache.catalina.connector.Response.flushBuffer(Response.java:537)
         at org.apache.catalina.connector.ResponseFacade.flushBuffer(ResponseFacade.java:276)
         at org.apache.myfaces.renderkit.html.util.DefaultAddResource.serveResource(DefaultAddResource.java:560)
         at org.apache.myfaces.webapp.filter.ExtensionsFilter.doFilter(ExtensionsFilter.java:125)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
         at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
         at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
         at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
         at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
         at java.lang.Thread.run(Thread.java:595)
    Caused by: java.net.SocketException: Connection reset by peer: socket write error
         at java.net.SocketOutputStream.socketWrite0(Native Method)
         at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92)
         at java.net.SocketOutputStream.write(SocketOutputStream.java:136)
         at org.apache.coyote.http11.InternalOutputBuffer.realWriteBytes(InternalOutputBuffer.java:746)
         at org.apache.tomcat.util.buf.ByteChunk.flushBuffer(ByteChunk.java:433)
         at org.apache.coyote.http11.InternalOutputBuffer.flush(InternalOutputBuffer.java:304)
         at org.apache.coyote.http11.Http11Processor.action(Http11Processor.java:991)
         at org.apache.coyote.Response.action(Response.java:182)
         at org.apache.catalina.connector.OutputBuffer.doFlush(OutputBuffer.java:322)
         ... 19 more
    Nov 27, 2008 4:44:03 PM org.apache.myfaces.webapp.filter.ExtensionsFilter doFilter
    SEVERE: Exception wile retrieving addResource
    java.lang.IllegalStateException
         at org.apache.catalina.connector.ResponseFacade.sendError(ResponseFacade.java:418)
         at org.apache.myfaces.renderkit.html.util.DefaultAddResource.serveResource(DefaultAddResource.java:583)
         at org.apache.myfaces.webapp.filter.ExtensionsFilter.doFilter(ExtensionsFilter.java:125)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
         at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
         at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
         at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
         at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
         at java.lang.Thread.run(Thread.java:595)

    ohh i got something new...
    When i delploy my project and run it for the first time it says:
    Nov 27, 2008 8:39:13 PM org.apache.myfaces.shared_tomahawk.config.MyfacesConfig getBooleanInitParameter
    INFO: No context init parameter 'org.apache.myfaces.PRETTY_HTML' found, using default value true
    Nov 27, 2008 8:39:13 PM org.apache.myfaces.shared_tomahawk.config.MyfacesConfig getBooleanInitParameter
    INFO: No context init parameter 'org.apache.myfaces.ALLOW_JAVASCRIPT' found, using default value true
    Nov 27, 2008 8:39:13 PM org.apache.myfaces.shared_tomahawk.config.MyfacesConfig getBooleanInitParameter
    INFO: No context init parameter 'org.apache.myfaces.DETECT_JAVASCRIPT' found, using default value false
    Nov 27, 2008 8:39:13 PM org.apache.myfaces.shared_tomahawk.config.MyfacesConfig getBooleanInitParameter
    INFO: No context init parameter 'org.apache.myfaces.AUTO_SCROLL' found, using default value false
    Nov 27, 2008 8:39:13 PM org.apache.myfaces.shared_tomahawk.config.MyfacesConfig getStringInitParameter
    INFO: No context init parameter 'org.apache.myfaces.ADD_RESOURCE_CLASS' found, using default value org.apache.myfaces.renderkit.html.util.DefaultAddResource
    Nov 27, 2008 8:39:13 PM org.apache.myfaces.shared_tomahawk.config.MyfacesConfig getBooleanInitParameter
    INFO: No context init parameter 'org.apache.myfaces.CHECK_EXTENSIONS_FILTER' found, using default value true
    Nov 27, 2008 8:39:14 PM org.apache.myfaces.renderkit.html.util.MyFacesResourceLoader getLastModified
    SEVERE: Unparsable lastModified : @lastModified@
    But everything runs fine on the page but after that when i refresh the page i got the exception, mentioned above

  • Bad Record MAC. exception while using urlConnection.getInputStream()

    All,
    In my SAP J2EE instance, from filter I am trying to do get data from an url (protocol is https).
    For this I am using urlInstance.openConnection() after that urlConnection.getInputStream() and then reading from this input stream.
    When I use http protocol, everything works fine. But with https, during urlConnection.getInputStream(), I get an exception saying "Bad Record MAC".
    I tried to execute the same code in a standalone java program. It went fine with both http and https.
    I get this error only when I run in SAP J2EE instance and only with https.
    From the exception trace, I can see that while running in J2ee engine, the URLConnection instance is org.w3c.www.protocol.http.HttpURLConnection.
    When I run a standalone program from command prompt, the instance is com.ibm.net.ssl.www.protocol.https.r. This runs without any issues.
    I understand that these instances are different due to different URLStreamHandlerFactory instances.
    But I didnt set the factory instance in either of the programs.
    1. Is the exception I get is simply bcoz of instance org.w3c.www.protocol.http.HttpURLConnection?
    2. In that case how can I change the factory instance in j2ee engine?
    Please help.
    Thanks.
    Edited by: Who-Am-I on Nov 28, 2009 7:54 AM

    May be my question is too complex to understand. Let me put it simple.
    After upgrading to NW 7.01 SP5, an existing communication between SAP J2EE engine and a 3rd party software is not working.
    After a lot of debuggin I came to know that its happening at the filter we implemented to route the requests through the 3rd party authentication system.
    At the filter exception is coming from org.w3c.www.protocol.http.HttpURLConnection.getInputStream.
    This instance of HTTPURLConnection given by protocol handler factory(implementation of URLStreamHandlerFactory) which SAP is considering by default. I want to replace this protocol handler with another handler as I see no problems running the same program outside SAP J2EE instance.
    Can we change this protocol handler factory? Where can we change it?

  • Exception while using RSA BSAFE CryptoJ in Weblogic 7.0 (SP2)

    I need to verify the digital signature in the application (Web Tier - Servlet)
    and i have got the RSA - BSafe license and tried using the RSA API and this works
    fine in the stand alone environment. (weblogic.jar is not part of the classpath).
    I have tried the same program in the Weblogic environment the BSAFE jar's are
    kept in the classpath prior to weblogic.jar and while starting the server i am
    getting the following exception and server continues to start. (Security configuration
    doesn't changed)
    =============================================
    <18/02/2004 16:59:46> <Alert> <WebLogicServer> <000297> <Inconsistent security
    configuration, java.lang.NoSuchMethodError>
    java.lang.NoSuchMethodError
    at com.rsa.jsafe.JA_AlgID.berDecode(JA_AlgID.java:94)
    at com.rsa.jsafe.JA_AlgID.berDecodeAlgID(JA_AlgID.java:29)
    at com.rsa.certj.cert.X509Certificate.setSignatureAlgorithm(X509Certificate.java:893)
    at com.rsa.certj.cert.X509Certificate.setInnerDER(X509Certificate.java:764)
    at com.rsa.certj.cert.X509Certificate.setCertBER(X509Certificate.java:428)
    at com.rsa.certj.cert.X509Certificate.<init>(X509Certificate.java:328)
    at com.rsa.certj.cert.X509Certificate.<init>(X509Certificate.java:306)
    at utils.ValidateCertChain.convertChain(ValidateCertChain.java:258)
    at utils.ValidateCertChain.validateServerCertChain(ValidateCertChain.java:304)
    at weblogic.security.service.SSLManager.getServerCertificate(SSLManager.java:316)
    at weblogic.t3.srvr.SSLListenThread.<init>(SSLListenThread.java:154)
    at weblogic.t3.srvr.SSLListenThread.<init>(SSLListenThread.java:122)
    at weblogic.t3.srvr.T3Srvr.initializeListenThreads(T3Srvr.java:1548)
    at weblogic.t3.srvr.T3Srvr.resume(T3Srvr.java:891)
    at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:300)
    at weblogic.Server.main(Server.java:32)
    <18/02/2004 16:59:46> <Emergency> <Security> <090034> <Not listening for SSL,
    java.io.IOException: Inconsistent security configuration, null.>
    <18/02/2004 16:59:47> <Notice> <WebLogicServer> <000355> <Thread "ListenThread.Default"
    listening on port 7001, ip address 127.0.0.1>
    <18/02/2004 16:59:47> <Notice> <Management> <141030> <Starting discovery of Managed
    Server... This feature is on by default, you may turn this off by passing -Dweblogic.management.discover=false>
    <18/02/2004 16:59:47> <Notice> <WebLogicServer> <000331> <Started WebLogic Admin
    Server "IMTServer" for domain "IMTDomain" running in Development Mode>
    <18/02/2004 16:59:47> <Notice> <WebLogicServer> <000365> <Server state changed
    to RUNNING>
    <18/02/2004 16:59:47> <Notice> <WebLogicServer> <000360> <Server started in RUNNING
    mode>
    ==========================================
    If the weblogic.jar set first in the classpath and BSAFE jar's kept in the last
    the Signature verification fails and iam getting the following exception
    ========================================================
         at com.rsa.jsafe.crypto.ar.f(Unknown Source)
         at com.rsa.jsafe.crypto.c7.a(Unknown Source)
         at com.rsa.jsafe.crypto.b1.a(Unknown Source)
         at com.rsa.jsafe.crypto.av.f(Unknown Source)
         at com.rsa.jsafe.crypto.at.e(Unknown Source)
         at com.rsa.jsafe.provider.JS_Signature.engineVerify(Unknown Source)
         at java.security.Signature$Delegate.engineVerify(Unknown Source)
         at java.security.Signature.verify(Unknown Source)
    ==========================================================
    I believe that there seems to be different versions of BSAFE products. Could you
    please suggests that in what way i can overcome this issue. Is it possible to
    use the BSAFE jar only for the specific application (web application) without
    disturbing weblogic envrionment.
    Reponses are highly appreciated.

    Weblogic is using RSA Crypto-J 3.3.1 The easiest solution is probably to modify
    the signature verification code to use 3.3.1 api-s. The alternative solution would
    require writing your own classloader for the application that would load BSAFE
    classes from your jar.
    Pavel.
    "Gops" <[email protected]> wrote:
    >
    I need to verify the digital signature in the application (Web Tier -
    Servlet)
    and i have got the RSA - BSafe license and tried using the RSA API and
    this works
    fine in the stand alone environment. (weblogic.jar is not part of the
    classpath).
    I have tried the same program in the Weblogic environment the BSAFE
    jar's are
    kept in the classpath prior to weblogic.jar and while starting the server
    i am
    getting the following exception and server continues to start. (Security
    configuration
    doesn't changed)
    =============================================
    <18/02/2004 16:59:46> <Alert> <WebLogicServer> <000297> <Inconsistent
    security
    configuration, java.lang.NoSuchMethodError>
    java.lang.NoSuchMethodError
    at com.rsa.jsafe.JA_AlgID.berDecode(JA_AlgID.java:94)
    at com.rsa.jsafe.JA_AlgID.berDecodeAlgID(JA_AlgID.java:29)
    at com.rsa.certj.cert.X509Certificate.setSignatureAlgorithm(X509Certificate.java:893)
    at com.rsa.certj.cert.X509Certificate.setInnerDER(X509Certificate.java:764)
    at com.rsa.certj.cert.X509Certificate.setCertBER(X509Certificate.java:428)
    at com.rsa.certj.cert.X509Certificate.<init>(X509Certificate.java:328)
    at com.rsa.certj.cert.X509Certificate.<init>(X509Certificate.java:306)
    at utils.ValidateCertChain.convertChain(ValidateCertChain.java:258)
    at utils.ValidateCertChain.validateServerCertChain(ValidateCertChain.java:304)
    at weblogic.security.service.SSLManager.getServerCertificate(SSLManager.java:316)
    at weblogic.t3.srvr.SSLListenThread.<init>(SSLListenThread.java:154)
    at weblogic.t3.srvr.SSLListenThread.<init>(SSLListenThread.java:122)
    at weblogic.t3.srvr.T3Srvr.initializeListenThreads(T3Srvr.java:1548)
    at weblogic.t3.srvr.T3Srvr.resume(T3Srvr.java:891)
    at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:300)
    at weblogic.Server.main(Server.java:32)
    <18/02/2004 16:59:46> <Emergency> <Security> <090034> <Not listening
    for SSL,
    java.io.IOException: Inconsistent security configuration, null.>
    <18/02/2004 16:59:47> <Notice> <WebLogicServer> <000355> <Thread "ListenThread.Default"
    listening on port 7001, ip address 127.0.0.1>
    <18/02/2004 16:59:47> <Notice> <Management> <141030> <Starting discovery
    of Managed
    Server... This feature is on by default, you may turn this off by passing
    -Dweblogic.management.discover=false>
    <18/02/2004 16:59:47> <Notice> <WebLogicServer> <000331> <Started WebLogic
    Admin
    Server "IMTServer" for domain "IMTDomain" running in Development Mode>
    <18/02/2004 16:59:47> <Notice> <WebLogicServer> <000365> <Server state
    changed
    to RUNNING>
    <18/02/2004 16:59:47> <Notice> <WebLogicServer> <000360> <Server started
    in RUNNING
    mode>
    ==========================================
    If the weblogic.jar set first in the classpath and BSAFE jar's kept in
    the last
    the Signature verification fails and iam getting the following exception
    ========================================================
         at com.rsa.jsafe.crypto.ar.f(Unknown Source)
         at com.rsa.jsafe.crypto.c7.a(Unknown Source)
         at com.rsa.jsafe.crypto.b1.a(Unknown Source)
         at com.rsa.jsafe.crypto.av.f(Unknown Source)
         at com.rsa.jsafe.crypto.at.e(Unknown Source)
         at com.rsa.jsafe.provider.JS_Signature.engineVerify(Unknown Source)
         at java.security.Signature$Delegate.engineVerify(Unknown Source)
         at java.security.Signature.verify(Unknown Source)
    ==========================================================
    I believe that there seems to be different versions of BSAFE products.
    Could you
    please suggests that in what way i can overcome this issue. Is it possible
    to
    use the BSAFE jar only for the specific application (web application)
    without
    disturbing weblogic envrionment.
    Reponses are highly appreciated.

  • Exception while using JDIC

    I used jdic-0.9.1 for registering the file type association of the file format that i have created. While executing the code for registering the association it throws the following exception.
    java.lang.UnsatisfiedLinkError: no jdic in java.library.path
         at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1517)
         at java.lang.Runtime.loadLibrary0(Runtime.java:788)
         at java.lang.System.loadLibrary(System.java:834)
         at org.jdesktop.jdic.filetypes.internal.WinRegistryWrapper.<clinit>(Unknown Source)
         at org.jdesktop.jdic.filetypes.internal.WinRegistryUtil.isSubKeyExist(Unknown Source)
         at org.jdesktop.jdic.filetypes.internal.WinRegistryUtil.isWin2kUserDefinedFileExtExist(Unknown Source)
         at org.jdesktop.jdic.filetypes.internal.WinAppAssociationWriter.isAssociationExist(Unknown Source)
         at org.jdesktop.jdic.filetypes.AssociationService.registerUserAssociation(Unknown Source)
         at conversion.RegisterAssociation.main(RegisterAssociation.java:23)
    Exception in thread "main"
    I have given the code here...
    mport org.jdesktop.jdic.filetypes.Association;
    import org.jdesktop.jdic.filetypes.AssociationAlreadyRegisteredException;
    import org.jdesktop.jdic.filetypes.AssociationService;
    import org.jdesktop.jdic.filetypes.RegisterFailedException;
    public class RegisterAssociation {
         * @param args
         public static void main(String[] args) {
              AssociationService associationService = new AssociationService();
              Association icubeAssociation = new Association();
              icubeAssociation.addFileExtension("icube");
              icubeAssociation.addAction(new org.jdesktop.jdic.filetypes.Action(
                        "open", "Path of application goes here"));
              icubeAssociation.setIconFileName("The icon file goes here");
              try {
                   associationService.registerUserAssociation(icubeAssociation);
              } catch (AssociationAlreadyRegisteredException e) {
              } catch (RegisterFailedException e) {
    }

    That is because it can't find the jdic dll file. If
    you're using Netbeans, you can just copy over
    jdic.dll file over to where jdic.jar file is located
    (and you have jdic.jar included in the library in
    your project). If you're not using Netbeans (or other
    IDE), you need to set java.library.path system
    property, but I don't recall the complete steps.. you
    can do a search for 'how to load dll in java'.
    Good luck,
    MaxI am also using NetBeans 5.5 and trying to work with JDIC, to no avail. I continue to get the following exception:
    Exception in thread "main" java.lang.UnsatisfiedLinkError: no jdic in java.library.pathAnd there is no jdic.dll nor jdic.jar that exists, this while doing a CVS checkout per instruction of jdic into its own project "JDIC_WIN32" working alongside my "GUI" project.
    Phil

  • How to handle "The specified resource does not exist" exception while using entity group transactions to purge WADLogs table

    Hi,
    We have a requirement to purge the Azure WADLogs table on a periodic basis. We are achieving this by using Entity group transactions to delete the
    records older than 15 days. The logic is like this.
    bool recordDoesNotExistExceptionOccured = false;
    CloudTable wadLogsTable = tableClient.GetTableReference(WADLogsTableName);
    partitionKey = "0" + DateTime.UtcNow.AddDays(noOfDays).Ticks;
    TableQuery<WadLogsEntity> buildQuery = new TableQuery<WadLogsEntity>().Where(
    TableQuery.GenerateFilterCondition("PartitionKey",
    QueryComparisons.LessThanOrEqual, partitionKey));
    while (!recordDoesNotExistExceptionOccured)
    IEnumerable<WadLogsEntity> result = wadLogsTable.ExecuteQuery(buildQuery).Take(1000);
    //// Batch entity delete.
    if (result != null && result.Count() > 0)
    Dictionary<string, TableBatchOperation> batches = new Dictionary<string, TableBatchOperation>();
    foreach (var entity in result)
    TableOperation tableOperation = TableOperation.Delete(entity);
    if (!batches.ContainsKey(entity.PartitionKey))
    batches.Add(entity.PartitionKey, new TableBatchOperation());
    // A Batch Operation allows a maximum 100 entities in the batch which must share the same PartitionKey.
    if (batches[entity.PartitionKey].Count < 100)
    batches[entity.PartitionKey].Add(tableOperation);
    // Execute batches.
    foreach (var batch in batches.Values)
    try
    await wadLogsTable.ExecuteBatchAsync(batch);
    catch (Exception exception)
    // Log exception here.
    // Set flag.
    if (exception.Message.Contains(ResourceDoesNotExist))
    recordDoesNotExistExceptionOccured = true;
    break;
    else
    break;
    My questions are:
    Is this an efficient way to purge the WADLogs table? If not, what can make this better?
    Is this the correct way to handle the "Specified resource does not exist exception"? If not, how can I make this better?
    Would this logic fail in any particular case?
    How would this approach change if this code is in a worker which has multiple instances deployed?
    I have come up with this code by referencing the solution given
    here by Keith Murray.

    Hi Nikhil,
    Thanks for your posting!
    I tested your and Keith's code on my side, every thing worked fine. And when result is null or "result.count()<0", the While() loop is break. I found you code had some logic to handle the error "ResourceDoesNotExist" .
    It seems that the code worked fine. If you always occurred this error, I suggest you could debug your code and find which line of code throw the exception.   
    >> Is this an efficient way to purge the WADLogs table? If not, what can make this better?
    Base on my experience, we could use code (like the above logic code) and using the third party tool to delete the entities manually. In my opinion, I think the code is every efficient, it could be auto-run and save our workload.
     >>Is this the correct way to handle the "Specified resource does not exist exception"? If not, how can I make this better?
    In you code, you used the "recordDoesNotExistExceptionOccured " as a flag to check whether the entity is null. It is a good choice. I had tried to deleted the log table entities, but I used the flag to check the result number.
    For example, I planed the query result count is 100, if the number is lower than 100, I will set the flag as false, and break the while loop. 
    >>Would this logic fail in any particular case?
    I think it shouldn't fail. But if the result is "0", your while loop will always run. It will never stop. I think you could add "recordDoesNotExistExceptionOccured
    = true;" into your "else" block.
    >>How would this approach change if this code is in a worker which has multiple instances deployed?
    You don't change anything expect the "else" block. It would work fine on the worker role.
    If any question about this issue, please let me know free.
    Regards,
    Will
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

Maybe you are looking for