Query on column with comma separated values

I have a proposed table with unnormalized data like the following:
ID COLA COLB REFLIST
21 xxx  zzz  24,25,78,412
22 xxx  xxx  21
24 yyy  xxx  912,22
25 zzz  fff  433,555,22
.. ...  ...  ...There are 200 million rows. There is maximum of about 10 IDs in the REFLIST, though typically two or three. How could I efficiently query this data on the REFLIST column? e.g. something like:
SELECT id FROM mytable WHERE :myval in reflistLogically there is a many to many relationship between rows in this table. The REFLIST column contains pointers to ID values elsewhere in the table. The data could be normalized so that the relationship keys are in a separate table (in fact this is the current solution that we want to change).
ID  REF
21  24
21  25
21  78
21  412
22  21
24  912
... ...The comma separated list seems instinctively like a bad idea, however there are various reasons for proposing it. The main reason is because the source for this data has it structured like the REFLIST example. It is an OLTP-like system rather than a data warehouse. The source code (and edit performance) would benefit greatly from not having to maintain the relationship table as the data changes.
Going back to querying the REFLIST column, the problem seems to be building an approriate index for the data. The ideas proposed so far are:
<li>Make a materialized view that presents the relationships as normalized (e.g. as in the example with ID, REF columns above), then index the plain column - the various methods of writing the view SQL have been widely posted.
<li>Use a Oracle Text Index (not something I have ever had call to use before).
Any other ideas? Its Oracle 10.2, though 11g could be possible.
Thanks
Jim

Something like this ?
This is test demo on my 11.2.0.1 Windows XP
SQL> create table test (id number,reflist varchar2(30));
Table created.
SQL> insert into test values (21,'24,25,78,412');
1 row created.
SQL> insert into test values (22,'21');
1 row created.
SQL> insert into test values (24,'912,22');
1 row created.
SQL> insert into test values (25,'433,555,22');
1 row created.
SQL> select * from test
  2  where
  3  ',' || reflist || ',' like '%,22,%';
        ID REFLIST
        24 912,22
        25 433,555,22
SQL>Source:http://stackoverflow.com/questions/7212282/is-it-possible-to-query-a-comma-separated-column-for-a-specific-value
Regards
Girish Sharma
Edited by: Girish Sharma on Jul 12, 2012 2:31 PM

Similar Messages

  • SQL - Multiple Fetch into Single Column with Comma Separator

    Hello Experts,
    Good Day to all...
    I need your help on following scenarios. The below query returns set of titleID strings. Instead of printing them one below the other as query output, I want the output to be in batch of 25 values.i.e each row should have 25 values separated by comma. i.e If there are 100 titles satisfying the output, then there should be only four rows with and each row having 25 titles in comma separated manner.
    SELECT DISTINCT title_id
               FROM pack_relation
              WHERE package_id IN (      SELECT DISTINCT fa.package_id
                                                    FROM annotation fa
                                                GROUP BY fa.package_id
                                                  HAVING COUNT
                                                            (fa.package_id) <100);I tried with the PL/SQL block; whereas it is printing all the values continously :(
    I need to stop with 25 values and display.
    If its possible with SQL block alone; then it would be of great help
    DECLARE
       v_str   VARCHAR2 (32767)  := NULL;
       CURSOR c1
       IS
         SELECT DISTINCT title_id
               FROM pack_relation
              WHERE package_id IN (      SELECT DISTINCT fa.package_id
                                                    FROM annotation fa
                                                GROUP BY fa.package_id
                                                  HAVING COUNT
                                                            (fa.package_id) <100);
    BEGIN
       FOR i IN c1
       LOOP
          v_str := v_str || ',' || i.title_id;
       END LOOP;
       v_str := SUBSTR (v_str, 2);
       DBMS_OUTPUT.put_line (v_str);
    EXCEPTION
       WHEN OTHERS
       THEN
          DBMS_OUTPUT.put_line ('Error-->' || SQLERRM);
    END;Thanks...

    You can use CEIL
    Sample code
    SELECT
        nt,
        LTRIM(MAX(SYS_CONNECT_BY_PATH(val,',')) KEEP (DENSE_RANK LAST ORDER BY curr),',') AS concat_val
    FROM
            SELECT
                val,
                nt,
                ROW_NUMBER() OVER (PARTITION BY nt ORDER BY val)    AS curr,
                ROW_NUMBER() OVER (PARTITION BY nt ORDER BY val) -1 AS prev
            FROM
                    SELECT
                        level                          AS val,
                        ceil(rownum/3)  as nt /* Grouped in batches of 3 */
                    FROM
                        dual
                        CONNECT BY level <= 10
    GROUP BY
        nt
        CONNECT BY prev = PRIOR curr
    AND nt              = PRIOR nt
        START WITH curr = 1;
            NT CONCAT_VAL
             1 1,2,3
             2 4,5,6
             3 7,8,9
             4 10Your code
    SELECT
        nt,
        LTRIM(MAX(SYS_CONNECT_BY_PATH(title_id,',')) KEEP (DENSE_RANK LAST ORDER BY curr),',') AS concat_val
    FROM
            SELECT
                title_id,
                nt,
                ROW_NUMBER () OVER (PARTITion BY nt ORDER BY title_id)   AS curr,
                ROW_NUMBER() OVER (PARTITION BY nt ORDER BY title_id) -1 AS prev
            FROM
                    SELECT
                        title_id,
                        ceil(rownum/25) AS nt /* Grouped in batches of 25 */
                    FROM
                        pack_relation tdpr
                    JOIN annotation fa
                    ON
                        tdpr.package_id = fa.package_id
                    GROUP BY
                        title_id,
                        fa.package_id
                    HAVING
                        COUNT (fa.package_id) < 500
    GROUP BY
        nt
        CONNECT BY prev = PRIOR curr
    AND nt              = PRIOR nt
        START WITH curr = 1;

  • Field with comma separated values to be split into Rows using a Query

    Thanks for the Reply.. I also have to Decode each of the spilt values with some text..
    replace(disc_topics,',',chr(10)) A from XYZ
    Disc_topics values are '01,02,03,04,05'
    this has to be done in SQL
    01 Test1
    02 Test2
    03 Test3
    04 Test4

    select replace( replace( replace( replace( '#' || '01,02,03,04,05,10,11', ',', ',#'), '#0','#'),'#','Test'),',',chr(10)) A from XYZ

  • Displaying data from a list into a single field with comma separated values

    Hi,
    I have a requirement to change a report with an XML structure (simplified version) as below
    <Protocol>
    <ProtocolNumber>100</ProtocolNumber>
    <SiteName>Baxter Building</SiteName>
    <ListOfActivity>
    <Activity>
    <Description>Communication Memo Description.</Description>
    <Name>James</Name>
    </Activity>
    <Activity>
    <Description>Visit 4</Description>
    <Name>James</Name>
    </Activity>
    <ListOfActivity/>
    </Protocol>
    On the report I need to display all the 'Names' for each of the Child (Activities) in a single field at the Parent (Protocol) level, with each Name separated by a comma.
    How do I go about getting this to work?
    Thanks

    Take a look at this: http://blogs.oracle.com/xmlpublisher/entry/inline_grouping
    You could do this (ofcourse, you will need to add extra logic to ensure that there is no comma added after the last name..)
    <?for-each@inlines:Name?><?.?><?', '?><?end for-each?>
    Thanks,
    Bipuser

  • Invalid number error - with comma separated values

    FUNCTION fn_check_value(
    p_ids_in IN VARCHAR2
    RETURN NUMBER
    IS
    v_nCheckValue NUMBER;
    CURSOR vCur
    IS
    SELECT COUNT(*)
    FROM t1
    WHERE col_id IN (p_ids_in); -- col_id is number field
    BEGIN
    OPEN vCur;
    FETCH vCur INTO v_nCheckValue;
    CLOSE vCur;
    Return v_nCheckValue;
    END fn_check_value;
    I get following error when the input is 3,4. Works fine with single value
    Execution failed: ORA-01722: invalid number

    If you have more than one number in the list being passed in through p_ids_in then you could try the following
    CURSOR vCur
    IS
    SELECT COUNT(*)
    FROM t1
    where
    INSTR(chr(44) || p_ids_in || chr(44), chr(44) || col_id || chr(44) ) > 0;
    This will do pattern matching and will return a true if the pattern matches.
    For example, if p_ids_in = '3,4'
    then INSTR (',3,4' , ',3,') > 0 will return a true.
    This approach is useful if you have more than one value inside a string.
    Shakti
    (http://www.impact-sol.com)
    (Developers of Guggi Oracle - Tool for DBAs and Developers)

  • Mapping a column with comma seperated values

    Hi,
    I have two tables
    1. Tasks (task_id, task_description)
    2. Task_assignment (username, task_assignment_value)
    the task_assignment_value has a comma seperated list of task_ids.
    What is the best ways to map the tables ?
    Thanks in advance.
    Moinuddin Mohammed

    I have a couple of attributes where I do this. From TopLink's perspective, I just map it as a String. Then, in my accessors for the attribute, I transform the primitive between the String and an Array or however the rest of the app wants to see the attribute.
    Here's an example that's actually more complicated than absolutely necessary. The mapped attributed is indicatorValueListString. It is lazily converted to an Array of Enums when it is first accessed. And it is converted back to a String in the preWriteEventCallback that is mapped in the TopLink descriptor.
    This implementation attempts to minimize the number of times the String<->Array conversion takes place, but if that's not a concern, it could be made much more simple. Also, at my company we privately manage collections with the Collection classes for dynamic allocation, but publicly exchange Arrays for type-safety. This could also be factored out. ValuedEnumUtils basically manages asking the enum for its delimiter and performing the actual conversion between a String and an Array or back.
    private String indicatorValueListString;
    private List indicatorValueSelections;
    private List indicatorValueSelections() {
            if (indicatorValueSelections == null) {
                    indicatorValueSelections = new ArrayList();
                    if (indicatorValueListString != null) {
                            indicatorValueSelections =
                                    java.util.Arrays.asList(ValuedEnumUtils.decodeEnumString(
                                         IndicatorValueEnum.class,indicatorValueListString));
            return indicatorValueSelections;
    private void indicatorValueSelections(List newIndicatorValueSelections) {
            indicatorValueSelections = newIndicatorValueSelections;
    public IndicatorValueEnum[] getIndicatorValueSelections() {
            return (IndicatorValueEnum[])indicatorValueSelections().toArray(new IndicatorValueEnum[0]);
    public void setIndicatorValueSelections(IndicatorValueEnum[] newIvSelections) {
            indicatorValueSelections(java.util.Arrays.asList(newIvSelections));
    public boolean addIndicatorValueSelection(IndicatorValueEnum anIvEnum) {
            return indicatorValueSelections().add(anIvEnum);
    public boolean removeIndicatorValueSelection(IndicatorValueEnum anIvEnum) {
            return indicatorValueSelections().remove(anIvEnum);
    public void preWriteEventCallback(DescriptorEvent aDescriptorEvent) {
            // Note: Not using accessor to avoid lazy initialization if no changes
            // are necessary.
            if (indicatorValueSelections != null) {
                    indicatorValueListString =
                            ValuedEnumUtils.encodeEnumString((ValuedEnum[])indicatorValueSelections.toArray());
    }

  • One column having multiple values with comma separator.

    Hey Guys,
    In my db, one culmn having multiple values with comma separator. like column_name = 'value1,value2,value3'. Now I want to compare this column to another column and fetch in Cursor.
    and each value having corresponding email_id, By fetching cursor, I need to populate email_ids.
    Thanks in advance!!
    -Lakshman

    Please compare and fetch cursor and populate result with out extract data into temp table. Give me the query!You have not provided DDL for table so I don't know table or column name to write any SQL.
    You have not provided DML for test data to run SQL against.

  • How can i get all these values in single row with comma separated?

    I have a table "abxx" with column "absg" Number(3)
    which is having following rows
    absg
    1
    3
    56
    232
    43
    436
    23
    677
    545
    367
    xxxxxx No of rows
    How can i get all these values in single row with comma separated?
    Like
    output_absg
    1,3,56,232,43,436,23,677,545,367,..,..,...............
    Can you send the query Plz!

    These all will do the same
    create or replace type string_agg_type as object
    2 (
    3 total varchar2(4000),
    4
    5 static function
    6 ODCIAggregateInitialize(sctx IN OUT string_agg_type )
    7 return number,
    8
    9 member function
    10 ODCIAggregateIterate(self IN OUT string_agg_type ,
    11 value IN varchar2 )
    12 return number,
    13
    14 member function
    15 ODCIAggregateTerminate(self IN string_agg_type,
    16 returnValue OUT varchar2,
    17 flags IN number)
    18 return number,
    19
    20 member function
    21 ODCIAggregateMerge(self IN OUT string_agg_type,
    22 ctx2 IN string_agg_type)
    23 return number
    24 );
    25 /
    create or replace type body string_agg_type
    2 is
    3
    4 static function ODCIAggregateInitialize(sctx IN OUT string_agg_type)
    5 return number
    6 is
    7 begin
    8 sctx := string_agg_type( null );
    9 return ODCIConst.Success;
    10 end;
    11
    12 member function ODCIAggregateIterate(self IN OUT string_agg_type,
    13 value IN varchar2 )
    14 return number
    15 is
    16 begin
    17 self.total := self.total || ',' || value;
    18 return ODCIConst.Success;
    19 end;
    20
    21 member function ODCIAggregateTerminate(self IN string_agg_type,
    22 returnValue OUT varchar2,
    23 flags IN number)
    24 return number
    25 is
    26 begin
    27 returnValue := ltrim(self.total,',');
    28 return ODCIConst.Success;
    29 end;
    30
    31 member function ODCIAggregateMerge(self IN OUT string_agg_type,
    32 ctx2 IN string_agg_type)
    33 return number
    34 is
    35 begin
    36 self.total := self.total || ctx2.total;
    37 return ODCIConst.Success;
    38 end;
    39
    40
    41 end;
    42 /
    Type body created.
    [email protected]>
    [email protected]> CREATE or replace
    2 FUNCTION stragg(input varchar2 )
    3 RETURN varchar2
    4 PARALLEL_ENABLE AGGREGATE USING string_agg_type;
    5 /
    CREATE OR REPLACE FUNCTION get_employees (p_deptno in emp.deptno%TYPE)
    RETURN VARCHAR2
    IS
    l_text VARCHAR2(32767) := NULL;
    BEGIN
    FOR cur_rec IN (SELECT ename FROM emp WHERE deptno = p_deptno) LOOP
    l_text := l_text || ',' || cur_rec.ename;
    END LOOP;
    RETURN LTRIM(l_text, ',');
    END;
    SHOW ERRORS
    The function can then be incorporated into a query as follows.
    COLUMN employees FORMAT A50
    SELECT deptno,
    get_employees(deptno) AS employees
    FROM emp
    GROUP by deptno;
    ###########################################3
    SELECT SUBSTR(STR,2) FROM
    (SELECT SYS_CONNECT_BY_PATH(n,',')
    STR ,LENGTH(SYS_CONNECT_BY_PATH(n,',')) LN
    FROM
    SELECT N,rownum rn from t )
    CONNECT BY rn = PRIOR RN+1
    ORDER BY LN desc )
    WHERE ROWNUM=1
    declare
    str varchar2(32767);
    begin
    for i in (select sal from emp) loop
    str:= str || i.sal ||',' ;
    end loop;
    dbms_output.put_line(str);
    end;
    COLUMN employees FORMAT A50
    SELECT e.deptno,
    get_employees(e.deptno) AS employees
    FROM (SELECT DISTINCT deptno
    FROM emp) e;
    DEPTNO EMPLOYEES
    10 CLARK,KING,MILLER
    20 SMITH,JONES,SCOTT,ADAMS,FORD
    30 ALLEN,WARD,MARTIN,BLAKE,TURNER,JAMES
    CREATE OR REPLACE FUNCTION concatenate_list (p_cursor IN SYS_REFCURSOR)
    RETURN VARCHAR2
    IS
    l_return VARCHAR2(32767);
    l_temp VARCHAR2(32767);
    BEGIN
    LOOP
    FETCH p_cursor
    INTO l_temp;
    EXIT WHEN p_cursor%NOTFOUND;
    l_return := l_return || ',' || l_temp;
    END LOOP;
    RETURN LTRIM(l_return, ',');
    END;
    COLUMN employees FORMAT A50
    SELECT e1.deptno,
    concatenate_list(CURSOR(SELECT e2.ename FROM emp e2 WHERE e2.deptno = e1.deptno)) employees
    FROM emp e1
    GROUP BY e1.deptno;
    DEPTNO EMPLOYEES
    10 CLARK,KING,MILLER
    20 SMITH,JONES,SCOTT,ADAMS,FORD
    30 ALLEN,WARD,MARTIN,BLAKE,TURNER,JAMES
    CREATE OR REPLACE TYPE t_string_agg AS OBJECT
    g_string VARCHAR2(32767),
    STATIC FUNCTION ODCIAggregateInitialize(sctx IN OUT t_string_agg)
    RETURN NUMBER,
    MEMBER FUNCTION ODCIAggregateIterate(self IN OUT t_string_agg,
    value IN VARCHAR2 )
    RETURN NUMBER,
    MEMBER FUNCTION ODCIAggregateTerminate(self IN t_string_agg,
    returnValue OUT VARCHAR2,
    flags IN NUMBER)
    RETURN NUMBER,
    MEMBER FUNCTION ODCIAggregateMerge(self IN OUT t_string_agg,
    ctx2 IN t_string_agg)
    RETURN NUMBER
    SHOW ERRORS
    CREATE OR REPLACE TYPE BODY t_string_agg IS
    STATIC FUNCTION ODCIAggregateInitialize(sctx IN OUT t_string_agg)
    RETURN NUMBER IS
    BEGIN
    sctx := t_string_agg(NULL);
    RETURN ODCIConst.Success;
    END;
    MEMBER FUNCTION ODCIAggregateIterate(self IN OUT t_string_agg,
    value IN VARCHAR2 )
    RETURN NUMBER IS
    BEGIN
    SELF.g_string := self.g_string || ',' || value;
    RETURN ODCIConst.Success;
    END;
    MEMBER FUNCTION ODCIAggregateTerminate(self IN t_string_agg,
    returnValue OUT VARCHAR2,
    flags IN NUMBER)
    RETURN NUMBER IS
    BEGIN
    returnValue := RTRIM(LTRIM(SELF.g_string, ','), ',');
    RETURN ODCIConst.Success;
    END;
    MEMBER FUNCTION ODCIAggregateMerge(self IN OUT t_string_agg,
    ctx2 IN t_string_agg)
    RETURN NUMBER IS
    BEGIN
    SELF.g_string := SELF.g_string || ',' || ctx2.g_string;
    RETURN ODCIConst.Success;
    END;
    END;
    SHOW ERRORS
    CREATE OR REPLACE FUNCTION string_agg (p_input VARCHAR2)
    RETURN VARCHAR2
    PARALLEL_ENABLE AGGREGATE USING t_string_agg;
    /

  • Adding a parameter with comma separated having different values

    i want to add a parameter with comma separated having different values of a column. e.g i have column having values from 10000 to 99999. i want to create report for the selected values of 11111,12111,131111 etc. This selection can be one or more values as desired. Second problem is restricting the records as per parameter.

    Reports doesn't allow multi-selection of a parameter in its parameter form. You need to use Oracle*Forms or an HTML Form to front end more advanced parameter form options.
    However, you could have multiple parameters and combine their selections into a single parameter in the after parameter form trigger. This would at least allow you to give the user the option for selecting up to 'n' parameters. The single parameter would have to be of type "character" and you probably want to add appropriate quotes around the values in the after parameter form trigger.
    Second problem is restricting the records as per parameter. Once you've got the comma seperated values into a single parameter (say p_myValues with a default value of '') then you can just use a lexical parameter to restrict the values as in:
    select * from emp
    where to_char(empno) in (&p_myValues)

  • Comma Separated Value Taking too Much Time to Execute

    Hi,
    select ES_DIAGNOSIS_CODE DC from ecg_study WHERE PS_PROTOCOL_ID LIKE 'H6L-MC-LFAN'
    The above query returns comma separated value from the above query.
    I am using the query below to split the comma separated value but the below query is taking lot of time to return the data.
    SELECT
    select DC from (
    with t as ( select ES_DIAGNOSIS_CODE DC from ecg_study WHERE PS_PROTOCOL_ID LIKE 'H6L-MC-LFAN' )
    select REGEXP_SUBSTR (DC, '[^,]+', 1, level) DC from t
    connect by level <= length(regexp_replace(DC,'[^,]*'))+1 )
    Please suggest me is there any alternative way to do this comma separated value.
    Thanks
    Sudhir

    Nikolay Savvinov wrote:
    Hi BluShadow,
    I know that this function is fast with varchar2 strings from several years of using it. With CLOBs one may need something faster, but the OP didn't menion CLOBs.
    Best regards,
    NikolayJust because you perceive it to be fast doesn't mean it's faster than doing it in SQL alone.
    For starters you are context switching from the SQL engine to PL/SQL to call it.
    Then in your code you are doing this...
    select substr(v_str,v_last_break+1, decode(v_nxt_break,0,v_length, v_nxt_break-v_last_break-1)) into v_result from dual;which is context switching back from the PL/SQL engine to the SQL engine for each entry in the string.
    Why people do that I don't know... when PL/SQL alone could do it without a context switch e.g.
    v_result := substr(v_str,v_last_break+1, case when v_nxt_break = 0 then v_length else v_nxt_break-v_last_break-1 end);So, if you still think it's faster than pure SQL (which is what the OP is using), please go ahead and prove it to us.

  • How to seach for a particular text in comma separated values

    Hi,
    I have one table for eg. TB_Fruits.
    In that i have one column FruitsName(Varchar)
    In that column i am storing string in comma separated values.
    Select FruitsName from tb_fruits;
    Result: orange,banana,apple
    Now the issue is suppose if i try to insert any of these fruits name again then it should not allow me to insert.
    Suppose now if i try to insert ('grapes,banana')
    or
    ('apple,grapes')
    the orange,banana,apple can be in any position.
    How to check if any of these names already exist or not in the column fruitsname?
    I cannot use like or INstr function here. because the position is not fixed not even string.
    Appreciate any help.

    After doing search.
    Got to know <= 3 length in word is in stoplist.
    That's why the value ALL it was not searching in index.
    After modifying the index this problem is solved.
    CREATE INDEX
    Fruitsname_idx ON tb_fruits (FruitsName)
    indextype is ctxsys.context
    PARAMETERS('SYNC ( ON COMMIT)
    stoplist ctxsys.empty_stoplist');
    But now the issue is suppose i have value with space..
    i inserted one more row with value 'FRUITS YELLOW'
    So in the index it is storing two rows....one is for FRUITS and second is for YELLOW.
    select * from tb_fruits t where contains(t.FruitsName,'FRUITS')>0
    I will get record..but actually there should be no record.
    And it should allow me to insert. So i can insert the value FRUITS in more row.
    Any help on how to store the value with space in one row in index??

  • Exporting Metadata (caption information) from JPEGS to a comma separated value (CSV) file

    Here is my dilemma. I am an archivist at an arts organization and we are in the process of digitizing many of our materials to post them on the web and make them available to internet users. One of the principle components of our collection is a large trove of photographs. We have been in the process of digitizing these images and embedding metadata (in the Caption/Description, Author/Photographer and Copyright fields) via PhotoShops File Info command.
    Now I am at a crossroads. We need to extract this metadata and transfer it into a comma separated value form, like an Excel spreadsheet or a FileMakerPro database. I have been told that it is not possible to do this through PhotoShop, that I must run a script through Acrobat or Bridge. I have no clue how to do this. I have been directed to a couple of links.
    First I was directed to this (now dead) link: http://www.barredrocksoftware.com/products.html
    The BSExportMetadata script allegedly exports the metadata from files selected in Adobe's Bridge into a comma separated value (CSV) file suitable for import into Excel, Access and most database programs. It installs as a Bridge menu item making it simple to use. The the Export Metadata script provides you with an easy to use wizard allowing you to select associated information about a set of images that you can then export. This script requires Creative Suite 2 (CS2). This script sounds like it does exactly what I want to do, but unfortunately, it no longer exists.
    Then I found this:
    Arnold Dubin, "Script to Export and Import Keywords and Metadata" #13, 8 Aug 2005 7:23 am
    I tried this procedure, but nothing seemed to happen. I also tried to copy the script into the JAVASCRIPT action option in Acrobat, but I received a message that the script had an error. It also seems to me that this script does not set up a dumping point, that is, a file into which this information will be exported to.
    I am a novice, not a code writer or a programmer/developer. I need a step-by-step explanation of how to implement this filtering of information. We have about 2000 jpeg and tiff files, so I would rather not go through each file and copy and paste this information elsewhere. I need to find out how to create a batch process that will do this procedure for me. Can anyone help?

    Hello -
    Is anyone aware of a tool that will do the above that is available for mac? Everything I've found so far seems to be PC only.
    Any help is appreciated, thanks!

  • HT2486 The selected file does not appear to be a valid comma separated values (csv) file or a valid tab delimited file. Choose a different file.

    The selected file does not appear to be a valid comma separated values (csv) file or a valid tab delimited file. Choose a different file.

    I guess your question is, "what's wrong with the file?"
    You're going to have to figure that out yourself, as we cannot see the file.
    Importing into Address book requires either a tab-delimited or a comma-delimited file. You can export out of most spreadsheets into a csv file. However, you need to make sure you clean up the file first.  If you have a field that has commas in the field, they will create new fields at the comma. So, some lines will have more fields than the others, causing issues like the error you saw.

  • Currency with comma separator

    Hi all ,
    I have a currency filed TFULLVACWTG. I am summing all values like this
    TFULLVACWTG = VFWTG001 + VFWTG002 + VFWTG003 + VFWTG004 + VFWTG005 . iam getting output like  this 14092.00 i should get output like this 14,092.00
    I should write output with comma separator .is there any key word or f.m for this one?

    Hi Priya,
    You have two options.
    1) Changes in user master record ie change thousand separator as , and decimal separator as .(dot).
    You can do this with transaction SU3.
    2) If you dont want to change master record then try with this code.
    DATA VC_TFULLVACWTG(18).
    VC_TFULLVACWTG = TFULLVACWTG.
    TRANSLATE VC_TFULLVACWTG USING ',#'.
    TRANSLATE VC_TFULLVACWTG USING '.,'.
    TRANSLATE VC_TFULLVACWTG USING '#.'.
    WRITE VC_TFULLVACWTG.
    Thanks,
    Vinay

  • Comma Separated Values files ?!!

    Is there special classes for dealing with CSV (comma separated values) to use a text file just like a database ??
    thanks in advance

    sorry, it just sounds like a strange thing to do. Normally, you would not use CSV for persistent data storage with a High Level Language. In your design, if you wanted to refer to a particular record, you get into all sorts of problems. You could keep a note of where each record is, like what line number its on, but then you would need some way of modifying this note when you add records. Also, you would have to be sure that no-one is accessing the file outside of the program as then things will not be where the program expects them to be. You could refer to each record using some identifier, but then if you are going to start using all of this, then you may as well go the database route. If you are new to java, it will probably help you learn. I just don't envisage you ever having to use the type of design you are talking of in practice. The closest thing that you ever might use it for is if you had a plain text configuration or parameter file for a program.

Maybe you are looking for

  • Problem with JCheckBox in a JTable

    Hello, I have a JTable with JCheckBox as Editor for boolean values. I added a ListSelectionListener on that JTable. My problem is : when I click on a cell which have a JCheckBoxEditor, there is only one event generated : the one which unselect the ro

  • Serial number does not work

    i purchased CS2 online from amazon ... the serial number did not work... I then went to live chat and they guided me to a new number.. it does not work either...  what can i do?????

  • Safari opens for one second

    then nothing. I am continuing to have other difficulties since installing memory into my computer but after a visit to the Apple store in LA and the genius bar the situation was TEMPORARILY resolved. Even after repairing my disk i.e. starting of the

  • How do you Simulate Overprint in Acrobat Standard?

    I know how to simulate overprint in Professional but is it in Standard? anyone?

  • Acrobat Reader is printing a random black bar on pages

    When printed from Windows, not from the Mac OS. They start out on the left as a bunch of thin lines and as they go to the left they quickly become a thick black line. The PDF's are being created right from Adobe InDesign CS6. The work around that the