Problems in fetching date to be set in setWhereClause

Hi,
In my OAF page there is a date combo which is populated by a VO.
By default the date combo shows the date in a format 03-Sep-2011.
So when I set the where clause in my code before doing vo.executeQuery, I set the where clause in as:
vo.setWhereClause("My_DATE =To_Date('"+SelectedDate+"','DD-Mon-YYYY')).
So it works fine.
But if someone goes to the preferences and changes the date format as 03-09-2011 then it sends the same date as DD-MM-YYYY format and my where clause fails.
Is there any solution to it so that whatever date format the user selects in Preference, it shall not affect my above where clause.
Regards
Hawker

Hawker,
As your below statement will always expect the selectedDate value in the DD-Mon-YYYY format, so whenever you will pass something other than this format it will fail.
You need to first connvert the Date into below format then set it to the SelectedDate. This will rectify your issue.
vo.setWhereClause("My_DATE =To_Date('"SelectedDate"','DD-Mon-YYYY')).
{code}
Regards,
Gyan                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

Similar Messages

  • I have Problem in fetching data from CONTROL BLOCK

    Sir,
    I am facing problem in fetching data from control block.
    Asif.

    is your control-block a filter-block for the detail-block?
    Do you want to see only the detail-data of the user-id you have displayed in the master?

  • Swing Applet in JSP: problem with fetching data from database

    i am facing a problem while fetching data from database using Swing Applet plugged in a JSP page.
    // necessary import statements
    public class NewJApplet extends javax.swing.JApplet {
    private JLabel jlblNewTitle;
    private Vector vec;
    public static void main(String[] args) {
    JFrame frame = new JFrame();
    NewJApplet inst = new NewJApplet();
    frame.getContentPane().add(inst);
    ((JComponent)frame.getContentPane()).setPreferredSize(inst.getSize());
    frame.pack();
    frame.setVisible(true);
    public NewJApplet() {
    super();
    initGUI();
    private void initGUI() {
    try {
    this.setSize(542, 701);
    this.getContentPane().setLayout(null);
    jlblTitle = new JLabel();
    this.getContentPane().add(jlblTitle);
    jlblTitle.setText("TITLE");
    jlblTitle.setBounds(197, 16, 117, 30);
    jlblTitle.setFont(new java.awt.Font("Dialog",1,20));
    jlblNewTitle = new JLabel();
    this.getContentPane().add(jlblNewTitle);
    Vector vecTemp = getDBDatum(); // data fetched fm DB r stored here.
    jlblNewTitle.setText(vecTemp.get(1).toString());
    jlblNewTitle.setBounds(350, 16, 117, 30);
    jlblNewTitle.setFont(new java.awt.Font("Dialog",1,20));
    } catch (Exception e) {
    e.printStackTrace();
    }//end of initGUI()
    private Vector getDBDatum() {
    // fetches datum from oracle database and stores it in a vector
    return lvecData;
    }//end of getDBDatum()
    }//end of class
    in index.jsp page i have included the following code for calling this applet:
    <jsp:plugin type="applet" code="NewJApplet.class" codebase="applets"
    width="600" height="300">
    <jsp:fallback>Could not load applet...</jsp:fallback>
    </jsp:plugin>
    if i view it in using AppletViewer it runs perfectly and display the data in JLabel. (ie, both jlblTitle and jlblNewTitle).(ie, DATA FETCHES FROM db AND DISPLAYS PROPERLY)
    BUT IF I CLICK ON INDEX.JSP, ONLY jlblTitle APPEARS. jlblnNewTitle WILL BE BLANK(this label name is supposed to fetch from database)
    EVERY THING IS DISPAYING PROPERLY EXCEPT DATA FROM DATABASE!!!
    i signed the applet as follows :
    grant {
    permission java.security.AllPermission;
    Can any body help me to figure out the problem?

    This is the Swing Applet java code
    import java.awt.Dimension;
    import java.sql.Connection;
    import java.sql.ResultSet;
    import java.sql.SQLException;
    import java.sql.Statement;
    import java.util.Vector;
    import javax.swing.tree.DefaultMutableTreeNode;
    import javax.swing.JScrollPane;
    import javax.swing.JApplet;
    import javax.swing.JButton;
    import javax.swing.JComponent;
    import javax.swing.JFrame;
    import javax.swing.JLabel;
    import javax.swing.JTree;
    import javax.swing.ScrollPaneConstants;
    import javax.swing.SwingConstants;
    public class HaiApplet extends javax.swing.JApplet {
         private JLabel     jlblTitle;
         private JLabel     jlblNewTitle;
         private Vector     vec;
         * main method to display this
         * JApplet inside a new JFrame.
         public static void main(String[] args) {
              JFrame frame = new JFrame();
              NewJApplet inst = new NewJApplet();
              frame.getContentPane().add(inst);
              ((JComponent)frame.getContentPane()).setPreferredSize(inst.getSize());
              frame.pack();
              frame.setVisible(true);
         public HaiApplet() {
              super();
              initGUI();
         private void initGUI() {
              try {               
                   this.setSize(542, 701);
                   this.getContentPane().setLayout(null);
                        jlblTitle = new JLabel();
                        this.getContentPane().add(jlblTitle);
                        jlblTitle.setText("OMMS");
                        jlblTitle.setBounds(197, 16, 117, 30);
                        jlblTitle.setFont(new java.awt.Font("Dialog",1,20));
                        jlblTitle.setHorizontalAlignment(SwingConstants.CENTER);
                        jlblTitle.setForeground(new java.awt.Color(0,128,192));
                        jlblNewTitle = new JLabel();
                        this.getContentPane().add(jlblNewTitle);
                        Vector vecTemp = getDBDatum();
                        jlblNewTitle.setText(vecTemp.get(1).toString());
                        jlblNewTitle.setBounds(350, 16, 117, 30);
                        jlblNewTitle.setFont(new java.awt.Font("Dialog",1,20));     
              } catch (Exception e) {
                   e.printStackTrace();
         }//end of initGUI()
         private Vector getDBDatum() {
              Vector lvecData = new Vector(10,5);
              Connection lcon = null;
              Statement lstmt = null;
              ResultSet lrsResults = null;
              String lstrSQL = null;
              String lstrOut = null;
              try {
                   OmmsDBConnect db = new OmmsDBConnect();
                   lcon = db.connectDb();
                   lstmt = lcon.createStatement(lrsResults.TYPE_SCROLL_SENSITIVE, ResultSet.CONCUR_READ_ONLY);
                   lstrSQL = "select DT_ID from P_DATATABLES";
                   lrsResults = lstmt.executeQuery(lstrSQL);        
                   int i = 0;
                   lrsResults.last();
                   int length = lrsResults.getRow();
                   System.out.println(length);
                   lrsResults.beforeFirst();
                   int recCount = 0;
                   while (lrsResults.next()) {
                        recCount++;
                        lvecData.addElement(new String(lrsResults.getString("DT_ID")));
                   //     System.out.println("ID :  " + lrsResults.getString(1));
                        i++;
                   }System.out.println("here 3 out fm while");
              catch(SQLException e) {
                   System.out.print("SQLException: ");
                   System.out.println(e.getMessage());
              catch(Exception ex) {
                   lstrOut = "Exception Occured " + ex.getMessage();
              finally {
                   try {
                        lrsResults.close();
                        lstmt.close();
                        lcon.close();
                        System.out.println("[DONE]");
                   catch(Exception e) {
                        System.out.println(e);
             }//end of finally
              return lvecData;
         }//end of getDBDatum()
    }//end of classOfcourse the above code compiles and runs well. in Applet Viewer
    I plugged the above Swing Applet in a JSP page index.jsp
    <jsp:plugin type="applet" code="NewJApplet.class" codebase="applets"
                   width="600" height="300">
         <jsp:fallback>Could not load applet...</jsp:fallback>
    </jsp:plugin>Every thing is working fine in AppletViewer...But if i view this in any browser, then only the jlblTitle is displaying. jlblNewTitle is not displaying(this label name is actually fetching from thedatabase)
    can any body help me regarding this matter.? Thx in Advance.

  • Facing  problem in fetching data

    hello everyone ,
    can anyone help me out  frm the problem , i need to fetch  data in alv  report (  likp-vbeln  ,lips-vgbel , likp-kunnr , vbpa-lifnr , vbrp-vgbel,vbuk-fkstk,vbrk-kunrg, vbrk-fkart and lfa1-name1 )  using  input parameter lips-vbeln or likp-vbeln .every time  i stuck in  select querries  for  fetching fieds  of   vbpa vbrk  vbrp vbuk and lfa1 .
    i am new to this forum excuse for  any mistake  regarding the rules and restriction .
    ranjan

    Moderator message - Welcome to SCN.
    Please read Please read "The Forum Rules of Engagement" before posting!  HOT NEWS!! and How to post code in SCN, and some things NOT to do... and [Asking Good Questions in the Forums to get Good Answers|/people/rob.burbank/blog/2010/05/12/asking-good-questions-in-the-forums-to-get-good-answers] before posting again.
    Thread locked.
    Rob

  • Problem in fetching data for Tcode QA03

    Hi,
    I am working on a report in which i have to pick up the dates for a material i.e. when it is MIGO is done and when it is moved to unrestricted stock.
    Till now i am fetching up the data from MSEG nad MKPF where i am getting the data w.r.t. movement types(101,321).
    Now the problem is ,i had checked that when i execute Tcode QA03 there is a option of checking the log of it where i found that is shows the value that the purticular value has been moved to unretricted stcok..
    The problem is it is storing the value in table RSTXT and field name TXLINE. How can i pick up the value for it and moreover it doesnot have the movt.type mentioned in it? Should i pick the value from MSEG n MKPF or make my logic through QALS and
    RSTXT.
    Please provide me some information about it...

    Hi Firends,
    I had developed a code for it now,but the problem is i am facing right now is when try to have difference between dates and time of both mvt.types 101 and 321,there comes a problem that it is not able to calculate the diiference as the data of both present in the seperate lines of the itab. Is there anyway that it can be  calculated.
    Here is the link to the code which i had created, please tell me  where i can rectify the error  :-
    I am really facing the problem in it.. plzz check the code whether it is corect or not?
    http://docs.google.com/View?id=dngp529_4grr2ctf6
    Edited by: nav009 on Nov 6, 2009 9:43 AM

  • Problem in fetching data from 0025IT

    Hello...
    Here we are working on One Page Profile and when i had made enteries in dev server  for employee first aparaisal in infotype 25 , it has shown one record correctly.But in the table HRP1001 , it created two records with same  dates and ratings but created two different object ids for the same record. It is showing same two record in the smartform also.
    Please advice me how to solve this problem...
    Thanks and Regards
    Shivangi...

    Hello Experts ,
    I have the problem regarding Infotype25 . I am working on one page profile , for that i have maintain new entry for an employee in infotype 25.In PA30 ,the record is maintained correctly but in the table HRP1001 it has shown two duplicate records with different object ids.Please help me how can i get the single record in that table .
    Thanks and Regards,
    Shivangi

  • Problem in Fetching data using RFC FM from NON SAP system

    Hi All,
    Need help from experts on data transfer using RFC from a non SAP system/database. I have creasted the destination in sm59.
    I have created a function module too which has an import parameter as a query and export parameter as an internal table.
    No when i test run this function module it returns some entries. But when I call this FM in a program it throws a dump 'rfc_external_abort' .  Here is what the call to FM looks like in my program. Please guide me on this.
    Thanks in advance,
    Saket.
    DATA : lv_query TYPE string,
           it_gddbdata TYPE ZC9_TAB_SOLMAN_XI_RFC.
    lv_query = 'SELECT *  FROM GDDB.VW_GDDB_PERSONS WHERE LASTNAME = ''''A'''''.
    CALL FUNCTION 'Z_C9_SOLMAN_XI_GDDBCON'
    DESTINATION  'D39'
      EXPORTING
        in_sql_query       = lv_query
    IMPORTING
       ET_GDDB_DATA       = it_gddbdata

    Hi,
    your question..
    DATA : lv_query TYPE string,
    it_gddbdata TYPE ZC9_TAB_SOLMAN_XI_RFC.
    lv_query = 'SELECT * FROM GDDB.VW_GDDB_PERSONS WHERE LASTNAME = ''''A'''''.
    CALL FUNCTION 'Z_C9_SOLMAN_XI_GDDBCON'
    DESTINATION 'D39'
    EXPORTING
    in_sql_query = lv_query
    IMPORTING
    ET_GDDB_DATA = it_gddbdata
    you are telling that you are fetching the data  from non sap system  using RFC function module.. how it is possible..you canot fetch the data from non SAP system using RFC FM alone.. you have to use the concept BAPI.. it will work..
    I hope this will help  you..
    Regards,
    Kiran

  • Problem in fetching data by using loop.

    Hello Friends,
    i have to create one report based upon item wise.
    Based upon item wise i have displayed Total stock qty and
    then item wise GRPO details with Qty data.
    I have created Stored procedure for this.
    Now i have kept one column RestQty which is basically used to
    display rest quantity based upon the data of Total Stock Qty and GRPO quantity.
    To Implement this logic i have used loop condition but its not returning correct
    qty on Rest Qty column.
    Rest Qty should work like this:-
    Item aaaaa
    If Total Quantity = 28
    GRPO Quantity = 40(First GRPO Qty),
              7(second last GRPO Qty), &
              3 (Last GRPO Quantity)
    Now Total quantity always first check with Last GRPo Qty,
    it means 28 > 3 then 3 comes to Rest Qty col.
    then Total quantity check with second Last GRPo Qty,
    it means 28 > 7 + 3(Last GRPo Qty) then 7 comes to Rest qty col.
    then Total quantity first check with first GRPo Qty,
    it means 28 > 40(first grpo qty) + 7 + 3, its not satisfied,
    hence it should display 28 - (7+3) = 18 in rest qty col.
    if we sum Rest qty column for Item aaaa then it should equal to Total Qty for particular item.
    so its should work for Item aaaa, based upon this other items should work like this.
    so i only need to correct the data of Rest Qty col, other are ok.
    Please help me to correct this query.
    Regards,

    SELECT OITM.ItemCode,OITM.ItemName,sum(OITW.onhand) as onhand,abc.basenum as GRPONo, abc.docdate as GRPODate,
    (select top 1 docrate from opdn where docentry = abc.baseentry and docnum = abc.basenum) as GRPORate,
    (select  sum(quantity) from pdn1 where docentry = abc.baseentry and abc.itemcode = itemcode) As GRPOQty,null,
    (select top 1 price from pdn1 where docentry = abc.baseentry and abc.itemcode = itemcode) As GRPOUnitPrice,
    (select distinct top 1 opch.docnum from opch inner join pch1 on opch.docentry = pch1.docentry
    where pch1.baseentry = abc.baseentry) as APInvNo,
    (select distinct top 1 opch.docdate from opch inner join pch1 on opch.docentry = pch1.docentry
    where pch1.baseentry = abc.baseentry) as APInvDt,
    (select distinct top 1 opch.u_dodamt from opch inner join pch1 on opch.docentry = pch1.docentry
    where pch1.baseentry = abc.baseentry) as APInvDocRate
    FROM OITW
    INNER JOIN OITM ON OITW.ItemCode = OITM.ItemCode
    INNER JOIN OITB ON OITM.ItmsGrpCod = OITB.ItmsGrpCod
    left join sri1 as abc on OITW.ItemCode = abc.ItemCode
    WHERE(OITW.OnHand <> 0 Or oitw.iscommited <> 0 Or oitw.onorder <> 0 Or oitw.minstock <> 0)
    AND (OITW.ItemCode IN (SELECT pdn1.ItemCode FROM Opdn
    inner join pdn1 on opdn.docentry = pdn1.docentry
    where opdn.series = 314 or opdn.series = 94 or opdn.series = 663))and (abc.Direction = 0)
    AND (abc.LineNum =(SELECT MAX(LineNum) AS Expr1 FROM  SRI1
    WHERE (ItemCode = abc.ItemCode) AND (SysSerial = abc.SysSerial))) AND basetype = 20
    and abc.docdate >= (@FromDate) and abc.docdate <= (@ToDate)
    group by OITM.ItemCode,OITM.ItemName, oitm.suppcatnum,
    abc.basenum, abc.sysserial, abc.baseentry, abc.basenum, abc.docdate,
    oitm.ItmsGrpcod, oitb.ItmsGrpNam, abc.baseentry, abc.SysSerial, abc.ItemCode,oitw.itemcode
    order by OITM.ItemName,abc.basenum

  • Problem in fetching data

    hi
    I M FACING STRANGE PROBLEM.
    WHEN I GIVE SIMPLE "SELECT * FROM TABLE@DBLINK" COMMAND IT GIVES NOT ERROR. ALSO ON THE MOTHER SCHEMA IT RUNS FINE. BUT WHEN I USE THIS COMMAND OVER OTHER DATABASE WITH DBLINK LIKE I MENTIONED HERE BELOW, A VERY STRANGE ERROR COMES.
    PLEASE HELP IF SOME ONE HAS GAUGHT THROUG THIS ...?
    COMMAND IS:-
    SQLWKS> SELECT DISTINCT P.SALES_CONTRACT_NUM, P.SCHEDULE_NUM
    2> FROM PROCESSING_SCHEDULE@MARK P
    3> ORDER BY 1
    4>
    SALES_CONTRACT_NUM SCHEDULE_N
    ORA-01114: IO error writing block to file 1027 (block # 9609)
    ORA-27069: skgfdisp: attempt to do I/O beyond the range of the file
    OSD-04026: Invalid parameter passed.
    O/S-Error: (OS 9609) DNS zone already exists.
    ORA-01114: IO error writing block to file 1027 (block # 9609)
    ORA-27069: skgfdisp: attempt to do I/O beyond the range of the file
    OSD-04026: Invalid parameter passed.
    O/S-Error: (OS 9609) DNS zone already exists.
    ORA-02063: preceding 8 lines from MARK

    FURTHOR MORE TO MY EARLIER QUERY, I FOUND THAT, ERROR COMES WHEN I USE DISTINCT KEYWORD, OTHER WISE IT EXECUTES WELL.
    IS THERE SOME BUG WITH DISTINCT KEYWORK
    ???

  • Problem to fetch data via fetchCalendarEventsByRange

    I have a repeatable ERROR on this program. Could you help?
    Error: CAPI_STAT_LIBRARY_INTERNAL_FUNCTION
    import oracle.calendar.sdk.*;
    public class grahamtest {
         public static void main(String[] args) {
              new grahamtest();
         private     Session mySession = null;
         private Handle agendas[] = {
              new Handle()
         public grahamtest() {
              initCalendar();
              connectToCalendar("[email protected]","******");
              setCalendarUser("[email protected]");
              fetchCalendarEventsByRange("20050627T000000Z", "20050924T235959Z");
              disconnectFromCalendar();
         private void initCalendar() {
              try     {
                   Api.init("d:/calendar_sdk/capi/demo/java/calendar.ini", "d:/calendar_sdk/capi/demo/java/calendar.log");
              catch(Api.StatusException e) {
                   System.out.println("init returned status'" + e.getMessage() + "'");
                   System.exit(-1);
         private void connectToCalendar(String cal_user, String cal_password) {
              try     {
                   mySession = new Session();
                   mySession.connect(Api.CAPI_FLAG_NONE,     "collabsuite-cal.us.oracle.com");
                   mySession.authenticate(Api.CAPI_FLAG_NONE, cal_user, cal_password);
              catch(Api.StatusException e) {
                   System.out.println("session/connect/authenticate returned status'" + e.getMessage() + "'");
                   System.exit(-1);
         private void setCalendarUser(String user) {
              try     {
                   System.out.println("user: " + user);
                   agendas[0] = mySession.getHandle(Api.CAPI_FLAG_NONE, user);
              catch(Api.StatusException e) {
                   System.out.println("getHandle returned status'" + e.getMessage() + "'");
                   System.exit(-1);
         private String fetchCalendarEventsByRange(String startDate, String endDate) {
              String properties[] = {"SUMMARY","DTSTART","DTEND"};
              RequestResult results = new RequestResult();
              String iCalendar = new String();
              try     {
                   iCalendar = mySession.fetchEventsByRange(Api.CSDK_FLAG_STREAM_NOT_MIME,
                        agendas, // search agenda of current user
                        startDate,
                        endDate,
                        properties, // request specific properties
                        results);
                   System.out.println(iCalendar);
                   return iCalendar;
              catch(Api.StatusException e) {
                   System.out.println("fetchEventsByRange returned status'" + e.getMessage() + "'");
                   System.out.println("fetchEventsByRange returned status'" + e + "'");
    //          System.exit(-1);
              return null;
         private void disconnectFromCalendar() {
              // disconnect:
              try {
                   mySession.deauthenticate(Api.CAPI_FLAG_NONE);
                   mySession.disconnect(Api.CAPI_FLAG_NONE);
              catch(Api.StatusException e) {
                   System.out.println("deauthenticate/disconnect returned status'" + e.getMessage() + "'");
                   System.exit(-1);

    Operating System: Windows 2000 Version 5.00.2195 Service Pack 4
    SDK Version: 9.0.4
    Server Version: ? (see our own Oracle Calendar Server)
    Does the error occur every time you run the test ? YES !!!
    Log file:
    DATE = Mon Jul 11 15:48:53.466 2005
    PID = 740; TID = 2608
    LOG TYPE -> ACTIVITY
    Connecting to host "collabsuite-cal.us.oracle.com"
    DATE = Mon Jul 11 15:48:58.984 2005
    PID = 740; TID = 2608
    LOG TYPE -> ACTIVITY
    Logging in as user "[email protected]"
    DATE = Mon Jul 11 15:49:09.519 2005
    PID = 740; TID = 2608
    ERROR CODE -> 0x19310
    Mapped ERRCODE 0x00019310 to CAPIStatus '128 5 1 4 0' (CAPI_STAT_LIBRARY_INTERNAL_FUNCTION)

  • Problem fetching data from multiple tables

    Hi,
    I am facing a problem in fetching data from 3 different tables. i am able to get the data from 2 tables but when i try accessing data from other table, i am getting redundant data. please help, my query is as under.
    select a.*,b.*, c.BidAmount from carregister a , watchlist b, Bidmaster c where a.CarID= b.CarID and b.UserID = 23 and c.BidAmount=(select max(BidAmount) from BidMaster where carid=a.carid group by c.BidAmount);
    Regards,
    Ujjwal B Soni
    <Software Developer>
    Baroda Gujarat India

    Hi,
    I got the solution. The solved query is as under :
    select a.*,b.*,(select max(BidAmount) from BidMaster where carid=b.carid) as MAX_AMT from carregister a , watchlist b where a.CarID= b.CarID and b.UserID=23;
    Thank you all for replying me.
    Warm Regards,
    Ujjwal B Soni
    <Software Developer>
    <Baroda Gujarat India>

  • Can anyone pls. help me : facing problem while fetching the data from BAPI

    Hi all,
        we have installed xMII in a new server. In this new server I am trying to fetch data from a BAPI & write it into a file thru a transaction, but i cant see the data in the tracer, & neither is the file created. But with the same configuration & connection am able to get the data in the old server. Can anyone pls. tell me wat could be the problem?? or is there anything else that we might have forgotten while installing xMII in the new server.
    ur help would be greatly appreciated.
    Thanks,
    Sushma.

    Hi Ravi,
           no am not able to see the table structure also. This is what it is showing in the tracer :
       [INFO ]: Execution Started At: 17:24:17
    [DEBUG]: 00000.03100 Begin Transaction 'TMP99A51958-5BAE-CDE0-0DB5-A3A8C72BC297'
    [DEBUG]: 00000.03100 Begin Sequence Sequence : ()
    [DEBUG]: 00000.03100 Begin Action SAPJCOInterface_0 : (SAP JCO Interface)
    [DEBUG]: 00006.43700 Connection Took 6406 mS
    [DEBUG]: 00009.82800 Function Creation Took 3391 mS
    [DEBUG]: 00010.25000 Execution Took 422 mS
    [DEBUG]: 00010.25000 End Action SAPJCOInterface_0 : (SAP JCO Interface)
    [DEBUG]: 00010.25000 Begin Sequence Sequence_0 : ()
    [DEBUG]: 00010.25000 Begin Action Repeater_0 : (Repeater)
    [DEBUG]: 00010.26600 End Action Repeater_0 : (Repeater)
    [DEBUG]: 00010.26600 End Sequence Sequence_0 : ()
    [DEBUG]: 00010.26600 End Sequence Sequence : ()
    [DEBUG]: 00010.26600 End Transaction 'TMP99A51958-5BAE-CDE0-0DB5-A3A8C72BC297'
    [INFO ]: Execution Completed At: 17:24:28 Elapsed Time was 10235 mS
    I doubt the repeater is not working, becoz i checked the JCO connection & thats fine..
    Thanks,
    Sushma.

  • Dynamic Calc processor cannot lock more than [100] ESM blocks during the calculation, please increase CalcLockBlock setting and then retry(a small data cache setting could also cause this problem, please check the data cache size setting).

    Hi,
    Our Environment is Essbase 11.1.2.2 and working on Essbase EAS and Shared Services components.One of our user tried to run the Cal Script of one Application and faced this error.
    Dynamic Calc processor cannot lock more than [100] ESM blocks during the calculation, please increase CalcLockBlock setting and then retry(a small data cache setting could also cause this problem, please check the data cache size setting).
    I have done some Google and found that we need to add something in Essbase.cfg file like below.
    1012704 Dynamic Calc processor cannot lock more than number ESM blocks during the calculation, please increase CalcLockBlock setting and then retry (a small data cache setting could also cause this problem, please check the data cache size setting).
    Possible Problems
    Analytic Services could not lock enough blocks to perform the calculation.
    Possible Solutions
    Increase the number of blocks that Analytic Services can allocate for a calculation:
    Set the maximum number of blocks that Analytic Services can allocate to at least 500. 
    If you do not have an $ARBORPATH/bin/essbase.cfg file on the server computer, create one using a text editor.
    In the essbase.cfg file on the server computer, set CALCLOCKBLOCKHIGH to 500.
    Stop and restart Analytic Server.
    Add the SET LOCKBLOCK HIGH command to the beginning of the calculation script.
    Set the data cache large enough to hold all the blocks specified in the CALCLOCKBLOCKHIGH setting. 
    Determine the block size.
    Set the data catche size.
    Actually in our Server Config file(essbase.cfg) we dont have below data  added.
    CalcLockBlockHigh 2000
    CalcLockBlockDefault 200
    CalcLockBlocklow 50
    So my doubt is if we edit the Essbase.cfg file and add the above settings and restart the services will it work?  and if so why should we change the Server config file if the problem is with one application Cal Script. Please guide me how to proceed.
    Regards,
    Naveen

    Your calculation needs to hold more blocks in memory than your current set up allows.
    From the docs (quoting so I don't have to write it, not to be a smarta***:
    CALCLOCKBLOCK specifies the number of blocks that can be fixed at each level of the SET LOCKBLOCK HIGH | DEFAULT | LOW calculation script command.
    When a block is calculated, Essbase fixes (gets addressability to) the block along with the blocks containing its children. Essbase calculates the block and then releases it along with the blocks containing its children. By default, Essbase allows up to 100 blocks to be fixed concurrently when calculating a block. This is sufficient for most database calculations. However, you may want to set a number higher than 100 if you are consolidating very large numbers of children in a formula calculation. This ensures that Essbase can fix all the required blocks when calculating a data block and that performance will not be impaired.
    Example
    If the essbase.cfg file contains the following settings:
    CALCLOCKBLOCKHIGH 500  CALCLOCKBLOCKDEFAULT 200  CALCLOCKBLOCKLOW 50 
    then you can use the following SET LOCKBLOCK setting commands in a calculation script:
    SET LOCKBLOCK HIGH; 
    means that Essbase can fix up to 500 data blocks when calculating one block.
    Support doc is saying to change your config file so those settings can be made available for any calc script to use.
    On a side note, if this was working previously and now isn't then it is worth investigating if this is simply due to standard growth or a recent change that has made an unexpected significant impact.

  • Result Set fetching data not sequentially?

    The result set I am using to fetch data from a table in MS-Access following the query "select * from fun",is fetching the recors but not sequentially from data base? How do I fix that?
    Thanx in adv
    Amit

    If you want your data in a particular order then you must include an ORDER BY clause in your SQL. Otherwise the database may return the data in any order it finds convenient.

  • Problem with a data set: DIAdem crashes

    Hi,
    I've got a problem with a data set. When I want to zoom in DIAdem-View, DIAdem crashes with the following message (translated from German ;-):
    error type: FLOAT INEXACT RESULT or FLOAT INVALID OPERATION or FLOAT STACK CHECK
    error address: 00016CB8
    module name: gfsview.DLL
    I've got some similar data set not showing such problems. Further on I scanned the data a bit, but in the 59000 points I didn't see anything special. I did try to delete "NOVALUE"s as well, but after that there still exist "NOVALUE"s.
    Does anyone have an idea what to look for?
    Thanks,
    Carsten

    Carsten,
    Could you please upload you Citadel database to the following FTP site:
    ftp.ni.com/incoming
    If you want to compress (ZIP) and/or put a password on the data, that's fine. Please send me a private email at [email protected] (with the file name and password if you put one on the file) once you have uploaded the file and I will check it out.
    Otmar
    Otmar D. Foehner
    Business Development Manager
    DIAdem and Test Data Management
    National Instruments
    Austin, TX - USA
    "For an optimist the glass is half full, for a pessimist it's half empty, and for an engineer is twice bigger than necessary."

Maybe you are looking for

  • Problem in getting opening balance for multiple GL Account

    Hi, I am working on a  Trail Balance Report in which i am trying to fetch the data for the opening balance for multiple GL Accounts but it is not coming accurate.. Here is the link to the code which i am using currently right now:- http://docs.google

  • Scanning/printing into/from native OS9 apps running in classic

    I am sure some of what I am about to ask is/has been covered in the numerous threads under this section, but I have a time crunch on and need help (the Mac is my wife's, but I get to do the tech support since I work in IT [management now, not hands o

  • Items published with approvals

    Items published with approval does not show when the page is in edit mode. Is this a bug or is it not meant to show. It should be shown and marked with "waiting for approval" or something.

  • Effect disappears when convert to CMYK

    I have a logo that was sent to me RGB, when I convert the document space the effect (reflection) disappears, I'm not very familiar with the effect that the person created, (mask with gradient). Here's a couple of screen shots, any advice would be app

  • I want to block internet sites like youtube and Internet downloads of movies to my users

    Hello I want to block internet sites like youtube and Internet downloads of movies to my users. Please tell me how can I create this kind of filter for my blackberry users. Thank you. Pavlos.