UPLOAD TEXT DATA IN ORACLE

My Dear Friends
I have a text file as follows
aaaaa, aaaaaa, aaaaaa
how i can upload same in oracle table
any body can help me
thanks in advance
Rgds
Muhammad Tahir Khan (TeeJay)

You can use SQL*Loader or an external table. I assume that the example that you provided is just a simplified example of one row of comma-delimited data. If you are planning on doing text searches on it, another option would be a file_datastore with a text index. There are examples of all of these in the searchable online documentation.

Similar Messages

  • Upload text file to oracle table with checking and aggregation

    Hi Friends,
    I am new to ODI.  I have encountered a problem which is specific to ODI 11G (11.1.1.6.3) to upload text file to oracle table with checking and aggregation.  Would you please teach me how to implement the following requirement in ODI 11G?
    Input text file a:
    staffCode, staffCat, status, data
    input text file b:
    staffCodeStart, staffCodeEnd, staffCat
    temp output oracle table c:
    staffCat, data
    output oracle table d:
    staffCat, data
    order:
    a.staffCode, a.staffCat, a.status
    filter:
    a.status = ‘active’
    join:
    a left outerjoin b on a.staffCode between b.staffCodeStart and b.staffCodeEnd
    insert temp table c:
    c.staffCat = if b.staffCat is not null then b.staffCat else a.staffCat
    c.data = a.data
    insert table d:
    if c.staffCat between 99 and 1000 then d.staffCat = c.staffCat, d.data = sum(c.data)
    else d.staffCat = c.staffCat, d.data = LAST(c.data)
    Any help on fixing this is highly appreciated. Thanks!!
    Thanks,
    Chris

    Dear Santy,
    Many thanks for your prompt reply.  May I have more information about the LAST or SUM step?
    I was successful to create and run the following interfaces p and q
    1. Drag text file a to a newly created interface panel p
    2. Filter text file a : a.status = ‘active’
    3. Lookup text file a to text file b : a.staffCode between b.staffCodeStart and b.staffCodeEnd
    4. Drag oracle temp table c to interface panel p
    5. Set c.staffCat : CASE WHEN b.staffCat IS NULL THEN a.staffCat ELSE b.staffCat END
    6. Set c.data : a.data
    7. Drag oracle temp table c to a newly created interface panel q
    8. Drag oracle table d to interface panel q
    9. Set UK to d.staffCat
    10. Set Distinct Rows to table d
    11. Set d.staffCat = c.staffCat
    12. Set d.data = SUM(c.data)
    However, the interface q should be more than that:
    If c.staffCat is between 99 and 1000, then d.data = the last record c.data; else d.data = sum(c.data)
    Would you please teach me how to do the LAST or SUM steps?  Moreover, can interface p and interface q be combined to one interface and do not use the temp table c?  Millions thanks!
    Regards,
    Chris

  • How to insert long text data in oracle for LONG column type??

    Anybody who can tell me what is best way to store long text (more than 8k) in Oralce table.
    I am using Long datatype for column but it still doenst let me insert longer strings.
    Also I am using ODP.Net.
    Anybody with a good suggestion???
    Thanks in advance

    Hi,
    Are you getting an error? If so, what?
    This works for me..
    Greg
    create table longtab(col1 varchar2(10), col2 long );
    using System;
    using System.Data;
    using Oracle.DataAccess.Client;
    using Oracle.DataAccess.Types;
    using System.Text;
    public class longwrite
    public static void Main()
    // make a long string
    StringBuilder sb = new StringBuilder();
    for (int i=0;i<55000;i++)
    sb.Append("a");
    sb.Append("Z");
    string indata = sb.ToString();
    Console.WriteLine("string length is {0}",indata .Length);
    // insert into database
    OracleConnection con = new OracleConnection("user id=scott;password=tiger;data source=orcl");
    con.Open();
    OracleCommand cmd = new OracleCommand();
    cmd.CommandText = "insert into longtab values(1,:longparam)";
    cmd.Connection = con;
    OracleParameter longparam = new OracleParameter("longparam",OracleDbType.Long,indata .Length);
    longparam.Direction = ParameterDirection.Input;
    longparam.Value = indata ;
    cmd.Parameters.Add(longparam);
    cmd.ExecuteNonQuery();
    Console.WriteLine("insert complete");
    //now retrieve it
    cmd.CommandText = "select rowid,col2 from longtab where col1 = 1";
    OracleDataReader reader = cmd.ExecuteReader();
    reader.Read();
    string outdata = (string)reader.GetOracleString(1);
    Console.WriteLine("string length is {0}",outdata.Length);
    //Console.WriteLine("string is {0}",outdata);
    reader.Close();     
    con.Close();
    con.Close();
    }

  • Uploading bulk data in oracle spatial

    Hi,
    I need to upload a map data in (input is ESRI File geodatabase) in Oracle Spatial using ArcSDE.
    I have Oracle spatial 10g, ArcGIS desktop 9.3. I am able to connect the oracle spatial data using arcsde and i am able to view those maps in arcmap. Also, i am able to upload small esri shape files in oracle spatial using esri arccatalog through arcsde.
    I would like to know, the steps to be followed to upload a road network for North america (around 15gb) data as SDO. If there is any document available it will be more useful for me.
    Or pls. share your experience in this.
    Thanks,
    Vadivelan. P

    Yikes,
    You won't require 150 gig of undo to load your data with ESRI tools. Noel might need to start a new thread to discuss that issue as his bulk loader may need some tuning. :p
    All ESRI bulk loaders use a rather modest auto-commit. ArcCatalog is 1000 records and sdeimport is 2000 records by default. So after loading that many records the tool does a commit and thus avoids much undo at all. You can easily change this number to tune performance (higher for point data, lower for huge honkin' polygons) in the parameters.
    At this point I would say the heck with all these torpedoes and give your load a try. You stated in the very first thread that you have loaded shapefiles successfully into Oracle Spatial so the assumption is you have your dbtune keywords setup and are all set with the issues of mapping ESRI coordinate systems into Oracle Spatial. So full steam ahead! Another idea would be to load a small subset of the data and make sure its correct to your needs before doing the whole thing. My opinion is I don't think you need to worry about the 15 gig size of the load. Yes it will take some time to do but I would bet whatever problems you run into are the same you would face with a 15 meg load.
    Cheers and good luck,
    Paul

  • Load Huge data into oracle table

    Hi,
    I am using oracle 11g Express Edition, I have a file of .csv forma, Which has a data of size 500MB which needs to be uploaded into oracle table.
    Please suggest which would be the best method to upload the data into table. Data is employee ticket history which is of huge data.
    How to do the mass upload of data into oracle table need experts suggestion on this requirement.
    Thanks
    Sudhir

    Sudhir_Meru wrote:
    Hi,
    I am using oracle 11g Express Edition, I have a file of .csv forma, Which has a data of size 500MB which needs to be uploaded into oracle table.
    Please suggest which would be the best method to upload the data into table. Data is employee ticket history which is of huge data.
    How to do the mass upload of data into oracle table need experts suggestion on this requirement.
    Thanks
    SudhirOne method is to use SQL Loader (sqlldr)
    Another method is to define an external table in Oracle which is allowing you to view your big file as a table in database.
    You may want to have a look at this guide: Choosing the Right Export/Import Utility and this Managing External Tables.
    Regards.
    Al
    Edited by: Alberto Faenza on Nov 6, 2012 10:24 AM

  • ShortDump in Text data

    Hi frds,
    i am uploadin COPA Text (Not Attributes) data to BW, upto PSA there were no problem, when i execute DTP its ended up with shortdump.
    Status 'Processed with Errors'
    Message no. RSBK223
    Shortdump msg..
    Error in the ABAP Application Program
      The current ABAP program "CL_RSDMD_UPDATE_MASTER_DATA===CP" had
       terminated because it has   come across a statement that unfortunately cannot be executed.
    "GETWA_NOT_ASSIGNED" " "
    "CL_RSDMD_UPDATE_MASTER_DATA===CP" or "CL_RSDMD_UPDATE_MASTER_DATA===CM00E"
    "_UPDATE_TEXTS_KERNL_T"
    I have already gone thru the previous threads, but not cleared
    please provide some inputs on this
    Thanks,
    Srini

    Hi Dinesh,
    Thanks for your time
    I hav gone thru the thread , but it doesnt seemed to help to my present situation.
    I am uploading text data to 0g_cwwair ,there are only 3 fileds and only 4 records iam extracting to BW.. its a full update , i am able to see that @ PSA level...
    In SM21 also i dint find more info
    I dont understd where im missing...
    Pls help me
    Thanks,
    Srini

  • Unable to find file error while loading data from text file to Oracle

    Hi,
    I am having a interface where i am loading a data of Text file to Oracle.
    But when i am trying to do this i am getting following error.
    ODI-1227: Task SrcSet0 (Loading) fails on the source FILE connection SAPMM.
    Caused By: java.sql.SQLException: File not found: d:/mdb/#General.get_filename
         at com.sunopsis.jdbc.driver.file.FileResultSet.<init>(FileResultSet.java:160)
         at com.sunopsis.jdbc.driver.file.impl.commands.CommandSelect.execute(CommandSelect.java:57)
         at com.sunopsis.jdbc.driver.file.CommandExecutor.executeCommand(CommandExecutor.java:33)
    SAPMM is connection name.
    I am using get_filename to get the filename and it is fetching correct value as the this variable refreshes in previous step of this interface.
    KM used for loading is File to SQL
    What would be cause of this error?
    Thanks,
    Mahesh

    Hi,
    Did a testing and following are the result
    I have
    A> created package having steps like
    1. Declaration of variable v_filename.
    2. Refreshing variable v_filename.
    3. Execution of Interface which gets the file name from v_filename and load into target table
    Package executes successfully.
    B> created package having steps like
    1. Declaration of variable v_filename.
    2. Refreshing variable v_filename.
    3. Scenario of Interface which gets the file name from v_filename and load into target table
    Package executes with erre as it is not able to find the file
    C> created package having steps like
    1. Declaration of variable v_filename.
    2. Refreshing variable v_filename.
    3. Execution of Interface which gets the file name from v_filename and load into target table
    4. Now create a scenario of the package , use the generated scenario in another package say main_package
    Execution of main_package is successful.
    Thanks,
    Sutirtha

  • How to load date and time from text file to oracle table through sqlloader

    hi friends
    i need you to show me what i miss to load date and time from text file to oracle table through sqlloader
    this is my data in this path (c:\external\my_data.txt)
    7369,SMITH,17-NOV-81,09:14:04,CLERK,20
    7499,ALLEN,01-MAY-81,17:06:08,SALESMAN,30
    7521,WARD,09-JUN-81,17:06:30,SALESMAN,30
    7566,JONES,02-APR-81,09:24:10,MANAGER,20
    7654,MARTIN,28-SEP-81,17:24:10,SALESMAN,30my table in database emp2
    create table emp2 (empno number,
                      ename varchar2(20),
                      hiredate date,
                      etime date,
                      ejob varchar2(20),
                      deptno number);the control file code in this path (c:\external\ctrl.ctl)
    load data
    infile 'C:\external\my_data.txt'
    into table emp2
    fields terminated by ','
    (empno, ename, hiredate, etime, ejob, deptno)this is the error :
    C:\>sqlldr scott/tiger control=C:\external\ctrl.ctl
    SQL*Loader: Release 10.2.0.1.0 - Production on Mon May 31 09:45:10 2010
    Copyright (c) 1982, 2005, Oracle.  All rights reserved.
    Commit point reached - logical record count 5
    C:\>any help i greatly appreciated
    thanks
    Edited by: user10947262 on May 31, 2010 9:47 AM

    load data
    infile 'C:\external\my_data.txt'
    into table emp2
    fields terminated by ','
    (empno, ename, hiredate, etime, ejob, deptno)Try
    load data
    infile 'C:\external\my_data.txt'
    into table emp2
    fields terminated by ','
    (empno, ename, hiredate, etime "to_date(:etime,'hh24:mi:ss')", ejob, deptno)
    this is the error :
    C:\>sqlldr scott/tiger control=C:\external\ctrl.ctl
    SQL*Loader: Release 10.2.0.1.0 - Production on Mon May 31 09:45:10 2010
    Copyright (c) 1982, 2005, Oracle.  All rights reserved.
    Commit point reached - logical record count 5
    C:\>
    That's not an error, you can see errors within log and bad files.

  • Problem in Uploading sales order text data using LSMW

    Hi All,
    I am facing Problem in uploading open sales order data from legacy to SAP using LSMW.
    We are trying to upload sales order data using LSMW Standard Batch/Direct input using program name RVINVB10 and program type D. We are not able to upload item text but have no problem in uploading remaining data.
    the details we are passing to BTEXHKOM structure are......
    BTEXHKOM-OLDNR = IHEADER-OLDORD_NO.
    BTEXHKOM-LAISO = 'EN'.
    BTEXHKOM-TDID = 'Z009'.
    and the for structure BTEXLKOM
    BTEXLKOM-OLDNR = IHEADER-OLDORD_NO.
    BTEXLKOM-TXPARGRAPH = '/'.
    CONCATENATE LITEM-DEPTID LITEM-DEPTNAME
    INTO BTEXLKOM-TXLINE SEPARATED BY ' '.
    we have three input source structures.
    IHEADER Header structure
    LITEM Line item structure ( Material data )
    IPARTN Partners structure
    The structure relationships are
    BTEXHKOM <<< IHEADER.
    BTEXLKOM <<< IHEADER.
    Please let me know if I am doing some thing wrong or some thing else need to be done.
    Thanks,
    Chindam.

    you can pass below values also
    OLDNR         :  order number and item nuber
    TXPARGRAPH  : VBBK
    TXLINE        : your text.....

  • Problems with special characters uploading data into oracle database

    Greetings
    I have a problem uploading data into oracle tables from sybase datasource. The data that I want to upload is in Spanish, for example when I have a varchar field with the data 'Consultoría', in oracle table the data upload with interrogation symbols.
    I have my source and target datastores configured as follows.
    Any suggestion? Thank you for your time

    Chack section 10 Locales and Multi-byte Functionality in the SAP Data Services Reference Guide for an exhaustive description of NLS settings.
    As a summary, following settings are required:
    locales in the datastore definitions match the actual locale used in the associated databases
    the locale of the DS engine allows for source to target translation
    the character set in the target database supports storage of accented characters

  • Upload Basic Data Text for Materials

    Hi,
    I'm trying to upload Basic Data Text for Materials using FM SAVE_TEXT. Everything works fine except long text. It is not accepting more than 132 charactors. What logic should I use so that it will append the remaining text for the same material on the other line?
    Please help !!!
    Thanks.

    If your text is longer than 132 characters, you have to wrap the text into multiple lines (FMs you should be using are FORMAT_TEXTLINES & RKD_WORD_WRAP).
    Search in SDN for details on these FMs.
    BR,
    Suhas
    PS: You can also explore uploading the material long texts using BAPI_MATERIAL_SAVEDATA. Uploading Basic Data Longtext into Material Master

  • Importing an SQL Server TEXT data type field in Oracle - problem with LONG

    Hello,
    I work in Oracle 9i and I created a view on a distant SQL Server database that contains a TEXT data type field. But I have a problem when I select that field in Oracle; I have the following error message: "ORA-00997: forbidden use of LONG data type".
    Could anybody have a solution for me, to solve that problem?
    Thanks a lot!

    It is very difficult to suggest anything without seeing your code.  I don't even know if what you are seeing is the actual value or an error code.  Often, negative numbers are indicative of error codes. 
    For instance -1 could mean that you have an invalid reference or path, etc...
    Can you post your code?

  • Error in uploading TEXT master data

    I got the following error while Creating Infopackage for uploading TEXT Master data:
    Error 8 when compiling the upload program:row 431, message: A newer version of data type
    /BIC/B0000102000 was
    Can anyone let me know how to solve this issue?
    Thanks,
    Soujanya.

    Hi Soujanya,
    Check whether the row 431 is having proper data that i matching in Data type with the IO.
    Also activate the transfer rule/ Transformations if any. Then try loading the data.
    If you are trying to load the Data through the Flat File, close the *.CSV file before actually loading the data & dont open it till it is successfully loaded.
    Hope it helps!
    Regards,
    Pavan

  • MS ACCESS TO ORACLE Error Migrating Text Data

    Hello people:
    ¿How can i migrate spanish characters in Oracle ?
    I'm migrating some data with spanish characters like:
    Á, É, Í, Ó, Ú, á, í, ú, é, ó, ñ , Ñ.
    So the process was correct but when i query data in Oracle y have this:
    Español instead of Español or
    Francés instead of Francés
    My *.dat files get the correct data, but when i migrate this to Oracle i have this erroneous data.
    Im mapping from Text Data Type to Varchar2 with 100 length
    I'll appreciate any help
    Ryan

    Hi Ryan,
    You mention in your posting that when you migrate to Oracle that you have errorneous data. Are the invalid characters saved in the Oracle database or are you just seeing these invalid characters when you query the database?
    Could you please check what your NLS_LANG parameter is set to? You can check the value of NLS_LANG by checking the registry subkey. Also could you check what the NLS_CHARACTERSET is on your Oracle database.
    Regards,
    Hilary

  • How can I upload text master data for attribute-only Charactertic?

    I can't create infosource for attribute-only Charactertic via direct update from Infoobject, because attribute-only Charactertics you can't choose from available infoobject.
    How can I upload text master data for attribute-only Charactertic?
    Thanks!

    Hi roberto,
    I soloved the problem. I can input the attribute-only char directly in the text box instead of choosing from list of infoobjects, but I still can't find the char in infoobject selection dialog even using search.

Maybe you are looking for

  • Thousands of individual .txt files being created while using "next available file name" option in Save to ASCII step

    I'm using Signal Express to record Load vs Displacement data and export it to a format our engineers can work with (in this case ASCII is okay). It would seem that by selecting the Next Available File Name from the drop down arrow it would do just th

  • BAPI used to delete the Purchase Order

    Hi All, I need to create a report by which we need to delete the selected purchase order. Kindly suggest me the BAPI which I should use for the same. Thanks, Sandy.

  • Where is Idvd in Mountain Lion?

    It doesn't seem to exist any more. So what do I use to burn an IMovie movie to a disk? So is there no app on my Macbook Pro Retina with Mountain Lion that I can use to put IMovies on a disk?????? Seems really strange. I've made a movie and now I can'

  • IPod won't restore - problem downloading iPod software

    When the restore window comes up and I select the restore button, an error window pops up that says "there was a problem downloading the iPod software for the iPod "iPod". The requested resource was not found". I've tried several of the tips includin

  • Datasource for material wise production data

    Hi Gurus, I need to extract daily production data from ECC material & plantwise. So which datasource I need to use for it? Its for a steel industry. Of the below ones which datasources can I use? & which DSO & Cube can I consider?\ 2LIS_04_P_COMP 2LI