Extract date from string in T-SQL

Hi,
I am having one field(AT_TEXT) in my database that has below kind of values. I want to extract date from this string but the issue is all rows has different format.
1)One Month Lttr sent on 3/12/2009 due to
2)One Month Letter sent on 1/15/2009 due to
3)One Month letter sent on7/15/2011.The amount due             - This has no space between on and 7 and . after yr
4)One Month letter sent on 7/16/12 due to        - This has 12 instead of 2012(2 positions after 2nd slash/)
Can anyone please help me to write query to extract date from this string?
Vicky

Hi Jingyang
Li,
I checked your query and it looks good but I have one issue. So when we reverse it, it looks like below and it is talking that $57.80 as a 1st numeric value and try to convert it into date and giving me error.
I realize from your query that you are trying to reverse the value and then try to find out 1st Numeric value from that string, but my whole string has another numeric value at the end, like 
"One Month Letter on 1/15/2009 due to non-pmt of prems-amt to avoid DE is $57.80"
So when we reverse it, it looks like below and it is taking that $57.80 as a 1st numeric value and try to convert it into date and giving me error.         
"08.75$ si ED diova ot eud tma - smerp fo tmp-non ot eud 9002/51/1 no retteL htnoM enO"
Also sometimes I have $ amount at the end and sometimes I don't have any $ amount at the end, like below,
"One Month letter sent on 10/15/2012 due to non-payment of premiums. The amount due to avoid dise"
Can you please modify your query which takes only date part not the $ amount and give me?
Thank you so much for your help 
Vicky

Similar Messages

  • Extracting data from string

    Can anyone point me in the right direction as to how URL's
    can be extracted from a string?
    Or at least find the start and end positions...
    EG:
    I want to get the URL's from the "a href"'s...
    String- "The quick brown fox jumps over the lazy dog, <a
    href="
    http://www.example1.com">click
    here</a>. The quick brown fox jumps over the lazy dog, <a
    href="
    http://www.example2.com">click
    here</a>.".

    Hi,
    You can do this by using the "anchors" object in
    "Javascript".. Below is the Sample Code..
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0
    Transitional//EN" "
    http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="
    http://www.w3.org/1999/xhtml">
    <head>
    <script language="javascript">
    function fnCheckAnchors()
    for (var i=0;i<document.anchors.length;i++)
    alert(document.anchors.item(i));
    </script>
    <meta http-equiv="Content-Type" content="text/html;
    charset=utf-8" />
    <title>Untitled Document</title>
    </head>
    <body>
    <form name="form" action="" method="post"
    onsubmit="fnCheckAnchors();">
    <a name="1" href="
    http://www.yahoo.com">Yahoo</a><br
    />
    <a name="2" href="
    http://www.google.com">Google</a><br
    />
    <a name="3" href="
    http://www.altavista.com">Altavista</a><br
    />
    <input type="submit" name="submit" value="Submit" />
    </form>
    </body>
    </html>

  • Extracting data from a SQL Server to BW

    Hi Experts,
        Can somebody let me know how to extract data from a NON SAP
        SQL Server I mean
        1. Creating a Source System
        2. Connecting to the SQL server
        3. Creating datasources and extraction
        Kindly help me its urgent
        thank you
        arshad.

    Hi Ingo,
    What I suggest is instead of extracting it to a file, can you use the function module which replicates this data to the mobile clients and use this function module to call the select statement. If a mobile client is able to access this info, then it must be doing a RFC call to some system whose logical system would have been in SAP as well. This is an assumption.
    May be if you could call the same function to derive the required data instead of extracting it to a file and then uploading it.
    Regards,
    Srikanth

  • Extracting data from Oracle GL and importing to FDM using ERPI adapter

    Hi,
    I am also trying to use ERPI adapter to directly extract data from Oracle GL. I am not finding sufficient information on this. It would be great if anyone can help me in this.
    I have one more doubt: Can we call the stored procedures in the FDM custom scripts, If so can I get the syntax of the script...I really don't have idea on this FDM part. I was working till now with the Flatfile input, But my client wants to make this change in the existing system. Accessing/Extracting data from Oracle GL. Experts who knows it can pls guide me.
    I am using FDM 11.1.2 and ERPI associated with 11.1.2.
    Thanks in Advance.
    [email protected]

    Hi,
    Is it possible to execute the stored procedures in FDM. Currently we are extracting data from oracle GL using SQl procedures (constaller tool is user to create the inteface) and storing the required data in the intermediate table in oracle GL, From which we are extracting data into a flat file and then loading it to FDM.
    So my question: is it possible to invoke the stored procedure from FDM scripts, If so can you pls let me know how to do that...
    Thanks In Advance,
    [email protected]

  • Is it possible to save / extract data from a MS SQL database 2008 using lookout 6.2?

    Is it possible to save / extract data from a MS SQL database 2008 using lookout 6.2?
      Now a days we are saving / extracting data in a excel spreadsheet, but we would like to do that using a database because it is better.

    You can use ODBC connection to work with SQL Server database.
    Use SQLExec object to execute the SQL statement. Here is a KB about the SQL statement.
    http://digital.ni.com/public.nsf/allkb/4ADEEA04CD24AE0B862565E20002A16F?OpenDocument
    To write data to spreadsheet is more straightforward because Lookout has built-in spreadsheet object. But you need to write SQL statement by yourself to interact with other database.
    To read the data back is the same way. Just use "select" SQL statement to query. You can use Datatable object to query.
    The "Data Source" can be "DSN = data source name;". The data source name is configured in Control Panel->Administrative Tools->Data Sources(ODBC).
    Ryan Shi
    National Instruments

  • Extract data from Flat file CSV to SQL Server 2008 using SSIS 2008 (Data gets corrupted when extraction)

    Hi,
    I am trying to extract data from multiple CSV files to SQL into a single table. The data type of all the columns in SQL table is nvarchar(MAX).  I am able to extract the data from the flat files but some of the data(on extraction) is
    corrupt including question marks(?) and other invalid special characters. Also I tried selecting the UTF-8, 65001(Unicode) format but the problem still persists. Also I tried using data converter but no use.
    I checked with the data in the flat file but there is no data with question mark(?) or any other special characters.
    The separator in the flat file is Comma(,)
    Please help.
    Thanks in advace.

    The source system and application determines the code page and encoding. Is it Windows, Unix, Mainframe or some other type? 
    Unicode files sometimes begin with a byte order mark (2 bytes) to indicate little or big endian.  If you open the file in notepad and then select save as, the encoding in the dialog will show the encoding notepad detected based on the BOM.  If
    that is ANSI instead of Unicode or UTF-8, you will need to know the code page the source system used when the file was created.
    Dan Guzman, SQL Server MVP, http://www.dbdelta.com

  • Extract data from a BW 7.0 cube to a SQL DB using Data Services XI

    Hi Gurus,
    We are trying to extract data from a BW 7.0 cube to a SQL DB using Data Services XI, the issue is that we can not read text without making "joins" between SID in the fact table and the master data tables. Do you know if it is posible to read text in a natural way?
    Best Regards

    Thanks Wondewossen,
    As you know, the DataStores (Data Services) provide access to:
    1.-Tables
    2.-Functions
    3.-IDOCs
    4.-Open Hub Tables
    We are trying to extract data using the first one (Tables), not using Open Hub.
    Best Regardas

  • Using SQL Server 2012 SSIS to Extract Data From SAP

    Hi
    What is the current best practice for using SQL Server 2012 SSIS to extract data from SAP R3? Please note we are looking for a solution that does not use SAP BW or SAP OHS.
    Ideally we would like to build our ETL SSIS process to make a .NET call to an SAP RFC procedure and avoid using web services.
    With SS2012 can we use any of these without using SAP BW:
    - SAP .NET Connector
    - MS ADO .NET
    - BizTalk .NET 3.0 Adapter
    Thanks and take care,
    Shayne

    Hi Shayne,
    You can use the .NET Framework Data Provider for mySAP Business Suite along with SQL Server Integration Service (SSIS) to import data from an SAP system into SQL Server database tables, flat files, or other compatible destination types. You can create an SSIS
    package that can be executed to import data from an SAP system.
    You must use the SQL Server Import and Export wizard to import data into the SQL Server database. You must provide a select query to specify data to be imported. The query must confirm to the semantics supported by the Data Provider for SAP. You can start the
    SQL Server Import Export Wizard either from the SQL Server Management Studio or from an Integration Service project in Visual Studio. Detail steps please see:
    Importing SAP Data Using SQL Server Management Studio:
    http://msdn.microsoft.com/en-us/library/cc185161(v=bts.10).aspx
    Importing SAP Data Using Visual Studio:
    http://msdn.microsoft.com/en-us/library/cc185254(v=bts.10).aspx
    Please feel free to ask if you have any question.
    Thanks,
    Eileen
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. This can be beneficial to other community members reading the thread.

  • Extracting data from Express to SQL Server

    is there a way to extract data from a Personal Express (v5)
    database into MS SQL Server (2000) using a DTS package ? I
    haven't found any references to an Express ODBC driver so I
    doubt it's possible and I may have to use SNAPI from VB.
    thanks.

    erics44 wrote:
    Hi
    i am looking after a set of schemas and reports. One report is based on data in an sql server that is periodically extracted from oracle.
    How might this be done? I am struggling finding the object that does thisThere could be any number of ways. It could be SQL Server connecting to the oracle database and querying the data directly. It could be a script on the SQL Server server that connects to Oracle and extracts the data. It could be a script on the Oracle server that extracts the data and then pushes it across to the SQL Server server. It could be a completely different script sitting on an unrelated server connecting to both databases. It could be a scheduled job running on the Oracle database that extracts the data and moves it across..... and so the list goes on.
    It's unlikely we'll be able to tell you anything as you are the one with access to your servers.

  • Extracting data from ms sql data base

    Hi Experts,
    we have a requirement of extracting data from MS SQL data base,could any one pls help me with the approach to extract data
    from ms sql data base(actually we have to extract the data from PRIMAVERA i.e the back end data base is MS SQL data base and the application is built on java)so we have got two options one is using ud connect and the other one is using PI(XI).i came to know the two approach have based on differenct methods,pull and push mechanism.and also for PI,it can be extracted using
    real time data acquisition property in dtp and for db connect it don't support real time data acqusition.
    so pls guide me,which mechanism would be feasible to extract the data from PRIMAVERA to SAP BI.and can you suggest with methods is more efficient.
    Thanks in advance.

    Hi thanks for the reply,
    initially we tried with db connect,but our Bi system(oracle) is mount on unix OS and the Primavera(MS Sql DB)is on windows OS.so we could not found the data base shared library  once if the DB client is installed on the application server.so we are working around with the other possibilities,so can you suggest me which could be favarable in our case.
    Thank You.

  • Could not extract data from MS-SQL to BW( IBM DM400)

    Hello,
      I have creat one DB connect to extract data from MS-SQL to BW system(DB: IBM DB400).
      I can show the data using display table contents in RSA1-- > source system -- > select database table.
      But I can not extract data using infopackage after I  had generated DataSource.
      The table/fields name have be made of upper case ,number and "_".
      could you help me ?
    the best regards,
    che xiaopeng
    03/22/2005

    Hi Xiaopeng,
    Have you checked for any related OSS Notes on that topic? In times of trouble, OSS does help a lot.
    There might be some fix or patch on that issue...
    Its pretty weird that you can see the data under BW from MSSQL and you cannot extract it. I think the problem lies on one of these things:
    1.) Posting of request log in BW.
    2.) Configuration of the MSSQL Data Source in BW.
    3.) SAP Drivers (DBConnect) for MSSQL improperly installed.
    4.) Authorization issues of the RFC user on BW side.
    Hope I have helped and if i did, please grant points...
    --Jkyle

  • How extract data from bw cube to MS SQL server.

    Hi all,
           This is Sateesh.In my requirement, i need to extract date from  BW Cube and to be moved to MS SQL server.can any one give  the slution .Pls give me the process how to move from bw to sql server.

    HI Kumar,
                       Try with Open Hub.........
    Check these.....
    http://help.sap.com/saphelp_nw04/helpdata/en/66/76473c3502e640e10000000a114084/frameset.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/c5/03853c01c89d7ce10000000a11405a/frameset.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/59/90070982d5524b931ae16d613ac04a/frameset.htm
    http://help.sap.com/saphelp_nw2004s/helpdata/en/ce/c2463c6796e61ce10000000a114084/frameset.htm
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/43f92595-0501-0010-5eb5-bb772d41ffa4
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/e830a690-0201-0010-ac86-9689620a8bc9
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/5f12a03d-0401-0010-d9a7-a55552cbe9da
    http://help.sap.com/saphelp_nw04/helpdata/en/66/76473c3502e640e10000000a114084/frameset.htm
    /people/happy.tony/blog/2006/09/18/hyperion-essbase-data-extraction-transformation-and-loading
    /people/marc.bernard/blog/2005/07/11/reorganization-of-sap-business-intelligence-forums
    Using OpenHub Unix to export to SQL Server
    Infospoke
    HOW TO RETRACT DATA FROM BPS 7.1 TO SRM 5.0
    Regards,
    Vijay.

  • Generate Insert Statement Script to Extract Data from Table in Oracle 7i

    Hi all, I have an old Oracle legacy system that is running for over 15 years.Every now and then we need to extract data from this table@ ORacle 7i to be imported back to Oracle 10G.
    My thoughts are to create a script of Insert statements in oracle 7 and that to be deployed back to Oracle 10G.
    I found this scripts in Google and not sure how exactly this works.Any explanation on thsi scripts , would be greatly appreciated.I find this scripst may help to generate a set of insert statements from that table to the latest table at 10G.
    <pre>
    -- Step 1: Create this procedure:
    create or replace Function ExtractData(v_table_name varchar2) return varchar2 As
    b_found boolean:=false;
    v_tempa varchar2(8000);
    v_tempb varchar2(8000);
    v_tempc varchar2(255);
    begin
    for tab_rec in (select table_name from user_tables where table_name=upper(v_table_name))
    loop
    b_found:=true;
    v_tempa:='select ''insert into '||tab_rec.table_name||' (';
    for col_rec in (select * from user_tab_columns
    where
    table_name=tab_rec.table_name
    order by
    column_id)
    loop
    if col_rec.column_id=1 then
    v_tempa:=v_tempa||'''||chr(10)||''';
    else
    v_tempa:=v_tempa||',''||chr(10)||''';
    v_tempb:=v_tempb||',''||chr(10)||''';
    end if;
    v_tempa:=v_tempa||col_rec.column_name;
    if instr(col_rec.data_type,'CHAR') > 0 then
    v_tempc:='''''''''||'||col_rec.column_name||'||''''''''';
    elsif instr(col_rec.data_type,'DATE') > 0 then
    v_tempc:='''to_date(''''''||to_char('||col_rec.column_name||',''mm/dd/yyyy hh24:mi'')||'''''',''''mm/dd/yyyy hh24:mi'''')''';
    else
    v_tempc:=col_rec.column_name;
    end if;
    v_tempb:=v_tempb||'''||decode('||col_rec.column_name||',Null,''Null'','||v_tempc||')||''';
    end loop;
    v_tempa:=v_tempa||') values ('||v_tempb||');'' from '||tab_rec.table_name||';';
    end loop;
    if Not b_found then
    v_tempa:='-- Table '||v_table_name||' not found';
    else
    v_tempa:=v_tempa||chr(10)||'select ''-- commit;'' from dual;';
    end if;
    return v_tempa;
    end;
    show errors
    -- STEP 2: Run the following code to extract the data.
    set head off
    set pages 0
    set trims on
    set lines 2000
    set feed off
    set echo off
    var retline varchar2(4000)
    spool c:\t1.sql
    select 'set echo off' from dual;
    select 'spool c:\recreatedata.sql' from dual;
    select 'select ''-- This data was extracted on ''||to_char(sysdate,''mm/dd/yyyy hh24:mi'') from dual;' from dual;
    -- Repeat the following two lines as many times as tables you want to extract
    exec :retline:=ExtractData('dept');
    print :retline;
    exec :retline:=ExtractData('emp');
    print :retline;
    select 'spool off' from dual;
    spool off
    @c:\t1
    -- STEP3: Run the spooled output c:\recreatedata.sql to recreate data.
    Source:http://www.idevelopment.info/data/Oracle/DBA_tips/PL_SQL/PLSQL_5.shtml
    </pre>

    Thanks Justin.
    I get what you are saying,i really wanted to see the output of the codes, because the furtherst i could get from that code is
    SELECT EXTRACTDATA('MYTABLE') FROM MYTABLE;
    and it generated this:
    "select 'insert into MYTABLE ('||chr(10)||'DATE1,'||chr(10)||'TIME1,'||chr(10)||'COUNTS) values ('||decode(DATE1,Null,'Null','to_date('''||to_char(DATE1,'mm/dd/yyyy hh24:mi')||''',''mm/dd/yyyy hh24:mi'')')||','||chr(10)||''||decode(TIME1,Null,'Null',TIME1)||','||chr(10)||''||decode(COUNTS,Null,'Null',COUNTS)||');' from MYTABLE;
    select '-- commit;' from dual;"
    "select 'insert into MYTABLE ('||chr(10)||'DATE1,'||chr(10)||'TIME1,'||chr(10)||'COUNTS) values ('||decode(DATE1,Null,'Null','to_date('''||to_char(DATE1,'mm/dd/yyyy hh24:mi')||''',''mm/dd/yyyy hh24:mi'')')||','||chr(10)||''||decode(TIME1,Null,'Null',TIME1)||','||chr(10)||''||decode(COUNTS,Null,'Null',COUNTS)||');' from MYTABLE;
    select '-- commit;' from dual;"
    "select 'insert into MYTABLE ('||chr(10)||'DATE1,'||chr(10)||'TIME1,'||chr(10)||'COUNTS) values ('||decode(DATE1,Null,'Null','to_date('''||to_char(DATE1,'mm/dd/yyyy hh24:mi')||''',''mm/dd/yyyy hh24:mi'')')||','||chr(10)||''||decode(TIME1,Null,'Null',TIME1)||','||chr(10)||''||decode(COUNTS,Null,'Null',COUNTS)||');' from MYTABLE;
    select '-- commit;' from dual;"
    "select 'insert into MYTABLE ('||chr(10)||'DATE1,'||chr(10)||'TIME1,'||chr(10)||'COUNTS) values ('||decode(DATE1,Null,'Null','to_date('''||to_char(DATE1,'mm/dd/yyyy hh24:mi')||''',''mm/dd/yyyy hh24:mi'')')||','||chr(10)||''||decode(TIME1,Null,'Null',TIME1)||','||chr(10)||''||decode(COUNTS,Null,'Null',COUNTS)||');' from MYTABLE;
    select '-- commit;' from dual;"
    "select 'insert into MYTABLE ('||chr(10)||'DATE1,'||chr(10)||'TIME1,'||chr(10)||'COUNTS) values ('||decode(DATE1,Null,'Null','to_date('''||to_char(DATE1,'mm/dd/yyyy hh24:mi')||''',''mm/dd/yyyy hh24:mi'')')||','||chr(10)||''||decode(TIME1,Null,'Null',TIME1)||','||chr(10)||''||decode(COUNTS,Null,'Null',COUNTS)||');' from MYTABLE;
    select '-- commit;' from dual;"
    "select 'insert into MYTABLE ('||chr(10)||'DATE1,'||chr(10)||'TIME1,'||chr(10)||'COUNTS) values ('||decode(DATE1,Null,'Null','to_date('''||to_char(DATE1,'mm/dd/yyyy hh24:mi')||''',''mm/dd/yyyy hh24:mi'')')||','||chr(10)||''||decode(TIME1,Null,'Null',TIME1)||','||chr(10)||''||decode(COUNTS,Null,'Null',COUNTS)||');' from MYTABLE;
    select '-- commit;' from dual;"
    I was expecting a string of
    insert into mytable values (19/1/2009,1,1);
    insert into mytable values (19/10/2008,5,10);
    Thanks for the explanation .

  • How to extract data from database to XSLT?

    I want to generate a report by XSLT, but the data is extracted from the database. I will use Access/SQL server for my database. Can i write SQL in XSLT to extract data from database? Have any sample code or reference website to show how it work?
    THX

    for example: "SELECT code, name FROM TABLE FOR XML RAW"
    String xml = null;
    if(rs.next()){
      xml = rs.getString(1);
    }You will get xml string something like this:
    <row empID="1234"/><row empID="1235"/>
    You can construct a DOM using this xml data and operate on it.
    However you may explore more on resulting xml format.
    A different SQL Query (rather than using XML RAW) may give output in a more desired format.

  • Extracting Data from Essbase using ODI fails with: Cannot calculate file.

    I'm try to Extract Data from Essbase using ODI KM (LKM Hyperion Essbase DATA to SQL). I'm using
    CalcScript for EXRACTION_QUERY_TYPE. CalcScript in my case resides on Essbase App directory, so I
    just specify the name (i.e. FULLEXP) for EXTRACTION_QUERY_FILE. Before creating ODI interface
    I ran CalcScript successfully from EAS. Also, ODI and Essbase are on different servers. ODI Agent
    is not running on Essbase Server, but ODI Agent has access to file generated by CalcScript.
    EPM Fusion Version 11.1.2.2. Essbase running in LINUX and ODI 11g running on Windows Server.
    Created the ODI interface where source is my Planning Cube and target is a relational table using SYNOPSIS
    MEMORY Engine for staging area. I make it thru the following ODI interface steps OK:
    1 - Loading - SrcSet0 - Drop work table
    2 - Loading - SrcSet0 - Create work table
    3 - Loading - SrcSet0 - Begin Essbase Data Extract.
    I then fail at:
    4 - Loading - SrcSet0 - Extract Data
    I get the following Message in ODI Operators console.
    org.apache.bsf.BSFException: exception from Jython:
    Traceback (most recent call last):
    File "<string>", line 1, in <module>
         at com.hyperion.odi.essbase.ODIEssbaseDataReader.getAppData(Unknown Source)
         at com.hyperion.odi.essbase.AbstractEssbaseReader.extract(Unknown Source)
         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:597)
    com.hyperion.odi.essbase.ODIEssbaseException: com.hyperion.odi.essbase.ODIEssbaseException: Cannot calculate file. Essbase Error(1013131): Failed to start Asynchronous thread
         at org.apache.bsf.engines.jython.JythonEngine.exec(JythonEngine.java:146)
         at com.sunopsis.dwg.codeinterpretor.SnpScriptingInterpretor.execInBSFEngine(SnpScriptingInterpretor.java:346)
         at com.sunopsis.dwg.codeinterpretor.SnpScriptingInterpretor.exec(SnpScriptingInterpretor.java:170)
         at com.sunopsis.dwg.dbobj.SnpSessTaskSql.scripting(SnpSessTaskSql.java:2458)
         at oracle.odi.runtime.agent.execution.cmd.ScriptingExecutor.execute(ScriptingExecutor.java:48)
         at oracle.odi.runtime.agent.execution.cmd.ScriptingExecutor.execute(ScriptingExecutor.java:1)
         at oracle.odi.runtime.agent.execution.TaskExecutionHandler.handleTask(TaskExecutionHandler.java:50)
         at com.sunopsis.dwg.dbobj.SnpSessTaskSql.processTask(SnpSessTaskSql.java:2906)
         at com.sunopsis.dwg.dbobj.SnpSessTaskSql.treatTask(SnpSessTaskSql.java:2609)
         at com.sunopsis.dwg.dbobj.SnpSessStep.treatAttachedTasks(SnpSessStep.java:540)
         at com.sunopsis.dwg.dbobj.SnpSessStep.treatSessStep(SnpSessStep.java:453)
         at com.sunopsis.dwg.dbobj.SnpSession.treatSession(SnpSession.java:1740)
         at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor$2.doAction(StartSessRequestProcessor.java:338)
         at oracle.odi.core.persistence.dwgobject.DwgObjectTemplate.execute(DwgObjectTemplate.java:214)
         at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor.doProcessStartSessTask(StartSessRequestProcessor.java:272)
         at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor.access$0(StartSessRequestProcessor.java:263)
         at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor$StartSessTask.doExecute(StartSessRequestProcessor.java:822)
         at oracle.odi.runtime.agent.processor.task.AgentTask.execute(AgentTask.java:123)
         at oracle.odi.runtime.agent.support.DefaultAgentTaskExecutor$2.run(DefaultAgentTaskExecutor.java:83)
         at java.lang.Thread.run(Thread.java:662)

    I'm try to Extract Data from Essbase using ODI KM (LKM Hyperion Essbase DATA to SQL). I'm using
    CalcScript for EXRACTION_QUERY_TYPE. CalcScript in my case resides on Essbase App directory, so I
    just specify the name (i.e. FULLEXP) for EXTRACTION_QUERY_FILE. Before creating ODI interface
    I ran CalcScript successfully from EAS. Also, ODI and Essbase are on different servers. ODI Agent
    is not running on Essbase Server, but ODI Agent has access to file generated by CalcScript.
    EPM Fusion Version 11.1.2.2. Essbase running in LINUX and ODI 11g running on Windows Server.
    Created the ODI interface where source is my Planning Cube and target is a relational table using SYNOPSIS
    MEMORY Engine for staging area. I make it thru the following ODI interface steps OK:
    1 - Loading - SrcSet0 - Drop work table
    2 - Loading - SrcSet0 - Create work table
    3 - Loading - SrcSet0 - Begin Essbase Data Extract.
    I then fail at:
    4 - Loading - SrcSet0 - Extract Data
    I get the following Message in ODI Operators console.
    org.apache.bsf.BSFException: exception from Jython:
    Traceback (most recent call last):
    File "<string>", line 1, in <module>
         at com.hyperion.odi.essbase.ODIEssbaseDataReader.getAppData(Unknown Source)
         at com.hyperion.odi.essbase.AbstractEssbaseReader.extract(Unknown Source)
         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:597)
    com.hyperion.odi.essbase.ODIEssbaseException: com.hyperion.odi.essbase.ODIEssbaseException: Cannot calculate file. Essbase Error(1013131): Failed to start Asynchronous thread
         at org.apache.bsf.engines.jython.JythonEngine.exec(JythonEngine.java:146)
         at com.sunopsis.dwg.codeinterpretor.SnpScriptingInterpretor.execInBSFEngine(SnpScriptingInterpretor.java:346)
         at com.sunopsis.dwg.codeinterpretor.SnpScriptingInterpretor.exec(SnpScriptingInterpretor.java:170)
         at com.sunopsis.dwg.dbobj.SnpSessTaskSql.scripting(SnpSessTaskSql.java:2458)
         at oracle.odi.runtime.agent.execution.cmd.ScriptingExecutor.execute(ScriptingExecutor.java:48)
         at oracle.odi.runtime.agent.execution.cmd.ScriptingExecutor.execute(ScriptingExecutor.java:1)
         at oracle.odi.runtime.agent.execution.TaskExecutionHandler.handleTask(TaskExecutionHandler.java:50)
         at com.sunopsis.dwg.dbobj.SnpSessTaskSql.processTask(SnpSessTaskSql.java:2906)
         at com.sunopsis.dwg.dbobj.SnpSessTaskSql.treatTask(SnpSessTaskSql.java:2609)
         at com.sunopsis.dwg.dbobj.SnpSessStep.treatAttachedTasks(SnpSessStep.java:540)
         at com.sunopsis.dwg.dbobj.SnpSessStep.treatSessStep(SnpSessStep.java:453)
         at com.sunopsis.dwg.dbobj.SnpSession.treatSession(SnpSession.java:1740)
         at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor$2.doAction(StartSessRequestProcessor.java:338)
         at oracle.odi.core.persistence.dwgobject.DwgObjectTemplate.execute(DwgObjectTemplate.java:214)
         at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor.doProcessStartSessTask(StartSessRequestProcessor.java:272)
         at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor.access$0(StartSessRequestProcessor.java:263)
         at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor$StartSessTask.doExecute(StartSessRequestProcessor.java:822)
         at oracle.odi.runtime.agent.processor.task.AgentTask.execute(AgentTask.java:123)
         at oracle.odi.runtime.agent.support.DefaultAgentTaskExecutor$2.run(DefaultAgentTaskExecutor.java:83)
         at java.lang.Thread.run(Thread.java:662)

Maybe you are looking for