Problem index

Hi
I have a question about index.I want to simulate order by(concept for sql base database) in berkeley db.for examle i want to simulate table like this:
table std_info:
fields:
name,famili,address,std_id,...
and I want to simulate quer like this:
select name from std_info where famili='famili1' order by address
I know how can I define index.
can you give me an example that can be simulate this situations?
thanks alot
regards
saeed

Hi Saeed,
I want to simulate (like statement in sql)
for example I want to simulate query like this:
select * from std_info where address like (%City%);
I know that I must use flag set_range .
but in this situation City is not located in first
part of index so how can I use set_range?If you keep the address as a single field you will need to create a secondary database as an index on address. With a cursor you'll have to iterate and search sequentially each key of this secondary for the pattern %City%. This is somehow similar to the process that hapens in a relational database when you do a SELECT with a WHERE clause containing a LIKE condition (a pattern matching). If the city name is found at a fix location within the address part of the data for every record, than you could construct your secondary only on the city, but this is very unlikely, since the format of an address varies a lot.
A more simpler and elegant approach is to split the address in comprising pieces: street, city, state, zipcode (note that this address format is specific for US, but you can easily adapt to the format that you want).
Thus, the structure that corresponds to the records in "std_info" will look like this:
typedef struct student {
    int std_id;                               /* Student ID */
    char name[MAXFIELD];             /* Student name (first name) */
    char family[MAXFIELD];           /* Student family name (last name) */
     /* Student address, splitted (specific for US addresses */
     char street[MAXFIELD];
     char city[MAXFIELD];
     char state[3];
     char zipcode[6];
} STUDENT;Than, you'll have to create the secondary key generator for the secondary index on city:
/* Secondary key creator for the secondary index on city */
int get_city(DB sdbpCity, const DBT pkey, const DBT pdata, DBT skey)
     char *p = NULL;
     /* point on "std_id" */
     p = (char*) pdata->data;     
     /* move the pointer on "name" */
     p+= sizeof(int);               
     /* move the pointer on "family" */
     p+= (u_int32_t) strlen(p) + 1;
     /* move the pointer on "street" */
     p+= (u_int32_t) strlen(p) + 1;
     /* move the pointer on "city" */
     p+= (u_int32_t) strlen(p) + 1;
     memset(skey, 0, sizeof(DBT));
     skey->data = (void*) p;
     skey->size = (u_int32_t) strlen(p) + 1;
     return(0);
}associate it with the primary db before loading the data, and the querying function may be something similar to this one:
/* Simulate Query 2 */
int query2(DB dbp, DB sdbpCity, const char *searchCity)
     DBC *crs;
     DBT key, data;
     int ret;
     char *p;
     if((ret = sdbpCity->cursor(sdbpCity, NULL, &crs, 0)) != 0){
          sdbpCity->err(sdbpCity, ret, "DB->cursor on secondary failed.");
        return (ret);
     memset(&key, 0, sizeof(DBT));
     memset(&data, 0, sizeof(DBT));
     key.data = (void*) searchCity;
     key.size = (u_int32_t) strlen(searchCity) + 1;
     /* get the first ordered record in the secondary */
     ret = crs->c_get(crs, &key, &data, DB_SET);
     /* retrieve the next ordered records testing for the family name */
     while((ret != DB_NOTFOUND)){
               p = (char*) data.data;
               printf("\nStudent id: %d", (int) *p);
               p += sizeof(int);
               printf("\nName: %s", p);
               p += (u_int32_t) strlen(p) + 1;
               printf("\nFamily: %s", p);
               p += (u_int32_t) strlen(p) + 1;
               printf("\nAddress: %s\n", p); p += (u_int32_t) strlen(p) + 1;
               printf("         %s, ", p); p += (u_int32_t) strlen(p) + 1;
               printf("%s\n", p); p += (u_int32_t) strlen(p) + 1;
               printf("           %s\n\n", p);     
               ret = crs->c_get(crs, &key, &data, DB_NEXT_DUP);
     if(crs != NULL)
          crs->c_close(crs);
     return(0);
}With regard to the suggestions in my previous update here are the according modifications for the secondary composite key creator and the querying function:
/* Secondary key creator for the secondary index on family+address */
int get_family_address(DB sdbp, const DBT pkey, const DBT pdata, DBT skey)
     char p, pFamily, pStreet, pCity, pState, pZipcode;
     u_int32_t dim;
     char *tempbuf;
     p = pFamily = pStreet = pCity = pState = pZipcode = NULL;
     /* point on "std_id" */
     p = (char*) pdata->data;     
     /* move the pointer on "name" */
     p+= sizeof(int);               
     /* move the pointer on "family", retain the address in <pFamily> */
     pFamily = p+= (u_int32_t) strlen(p) + 1;
     /* move the pointer on "street", retain the address in <pStreet> */
     pStreet = p+= (u_int32_t) strlen(p) + 1;
     /* move the pointer on "city", retain the address in <pCity> */
     pCity = p+= (u_int32_t) strlen(p) + 1;
     /* move the pointer on "state", retain the address in <pState> */
     pState = p+= (u_int32_t) strlen(p) + 1;
     /* move the pointer on "Zipcode", retain the address in <pZipcode> */
     pZipcode = p+= (u_int32_t) strlen(p) + 1;
     /* determine the size of the buffer that will store the composite key
      * and allocate space for this buffer */
     dim = (u_int32_t) strlen(pFamily) + strlen(pStreet) +
          strlen(pCity) + strlen(pState) + strlen(pZipcode) + 1;
     tempbuf = (char*) malloc(dim);
     /* set the DB_DBT_APPMALLOC flag in the secondary key DBT */
     memset(skey, 0, sizeof(DBT));
     skey->flags = DB_DBT_APPMALLOC;
     strcpy(tempbuf, pFamily); strcat(tempbuf, pStreet); strcat(tempbuf, pCity);
     strcat(tempbuf, pState); strcat(tempbuf, pZipcode);
    skey->data = (void*) tempbuf;
    skey->size = dim;
    return (0);
/* Simulate Query 1 */
int query1(DB dbp, DB sdbp, const char *searchFamily)
     DBC *crs;
     DBT key, data;
     int ret, walk = 1;
     size_t searchSize;
     char *p;
     searchSize = strlen(searchFamily);
     if((ret = sdbp->cursor(sdbp, NULL, &crs, 0)) != 0){
          sdbp->err(sdbp, ret, "DB->cursor on secondary failed.");
        return (ret);
     memset(&key, 0, sizeof(DBT));
     memset(&data, 0, sizeof(DBT));
     key.data = (void*) searchFamily;
     key.size = (u_int32_t) strlen(searchFamily) + 1;
     /* get the first ordered record in the secondary */
     ret = crs->c_get(crs, &key, &data, DB_SET_RANGE);
     /* retrieve the next ordered records testing for the family name */
     while((ret != DB_NOTFOUND) && walk){
          if(strncmp((const char*)key.data, searchFamily, searchSize))
               walk = 0;
          else {
               p = (char*) data.data;
               printf("\nStudent id: %d", (int) *p);
               p += sizeof(int);
               printf("\nName: %s", p);
               p += (u_int32_t) strlen(p) + 1;
               printf("\nFamily: %s", p);
               p += (u_int32_t) strlen(p) + 1;
               printf("\nAddress: %s\n", p); p += (u_int32_t) strlen(p) + 1;
               printf("         %s, ", p); p += (u_int32_t) strlen(p) + 1;
               printf("%s\n", p); p += (u_int32_t) strlen(p) + 1;
               printf("           %s\n\n", p);     
          ret = crs->c_get(crs, &key, &data, DB_NEXT);
     if(crs != NULL)
          crs->c_close(crs);
     return(0);
}Also, you could set a comparison function on the primary db for sorting correctly the integer keys, and you could set this function as a duplicate comparison function for the records in the secondary databases, using the "DB->set_bt_compare" and, respectively, the "DB->set_dup_compare" methods:
/* Btree comparison function for primary db keys
* also used when sorting duplicates in secondary dbs */
int comp_fcn(DB dbp, const DBT dbt1, const DBT *dbt2)
     int ai, bi;
     memcpy(&ai, dbt1->data, sizeof(int));
     memcpy(&bi, dbt2->data, sizeof(int));
     return (ai - bi);
}Regards,
Andrei

Similar Messages

  • Problems indexing 30M documents

    Platform: Sun 4800, 12 CPU, Solaris 9, 48 Gb RAM
    Oracle Version: 10.1.04
    Database Character Set: UTF-8
    SGA MAX SIZE: 24 Gb
    hi,
    Our database contains a mix of image files and plain text documents in 30 different languages (approximately 30 million rows). When we try to index the documents (using IGNORE in the format column to skip the rows containing images), the indexing either bombs out or hangs indefinitely.
    When I first started working on the problem, there were rows in the ctx_user_index_errors table which didn't really give any good indication of what the problem was. I created a new table containing just these rows and was able to index them with no problems using the same set of preferences and the same indexing script. At that time, they were using just the BASIC_LEXER.
    We created a MULTI_LEXER preference and added sub-lexers when lexers existed for the specified language, using the BASIC_LEXER as the default. When we tried to create the index using a parallel setting of 6, the indexing failed after 2 hours, and we got the following error codes: ORA-29855, ORA-20000, DRG-50853, DRG-50857, ORA-01002, and ORA-06512. We then tried to create the index without parallel slaves, and it failed after 3 hours with an end of file on communication channel error.
    Thinking perhaps that it was the MULTI_LEXER that was causing the problem (because the data is converted to UTF-8 by an external program, and the character set and language ID is not always 100% accurate), we tried to create the index using just the BASIC_LEXER (knowing that we wouldn't get good query results on our CJK data). We set the parallel slaves to 6, and it ran for more than 24 hours, with each slave indexing about 4 million documents (according to the logs) before just hanging. The index state in ctx_user_indexes is POPULATE, and in user_indexes is INPROGRESS. There were three sessions active, 2 locked, and 1 blocking. When we were finally able to ctl-C out of the create index command, SQL*Plus core dumped. It takes hours to drop the index as well.
    We're at a loss to figure out what to try next. This database has been offline for about a week now, and this is becoming critical. In my experience, once the index gets hung in POPULATE, there's no way to get it out other than dropping and recreating the index. I know that Text should be able to handle this volume of data, and the machine is certainly capable of handling the load. It could be that the MULTI_LEXER is choking on improperly identified languages, or that there are errors in the UTF-8 conversion, but it also has problems when we use BASIC_LEXER. It could be a problem indexing in parallel, but it also dies when we don't use parallel. We did get errors early on that the parallel query server died unexpectedly, but we increased the PARALLEL_EXECUTION_MESSAGE_SIZE to 65536, and that stopped the parallel errors (and got us to the point of failure quicker).
    Any help you can provide would be greatly appreciated.
    thanks,
    Tarisa.

    I'm working with the OP on this. Here is the table definition and
    the index creation with all the multi_lexer prefs. The table
    is hash partitioned, and we know the index cannot be
    local because of this, so it is a global domain index.
    Perhaps of interest, we have changed PARALLEL_EXECUTION_MESSAGE_SIZE
    from the default up to 32K. This made a huge difference in indexing speed, but
    so far has just helped us get to the point of failure faster.
    CREATE TABLE m (
    DOC_ID NUMBER,
    CID NUMBER,
    DATA CLOB,
    TYPE_ID NUMBER(10),
    FMT VARCHAR2(10),
    ISO_LANG CHAR(3)
    LOB (data) store as meta_lob_segment
    ( ENABLE STORAGE IN ROW
    PCTVERSION 0
    NOCACHE
    NOLOGGING
    STORAGE (INITIAL 32K NEXT 32K)
    CHUNK 16K )
    PARTITION BY HASH ( doc_id )
    PARTITIONS 6
    STORE IN (ts1, ts2, ts3, ts4, ts5, ts6),
    pctfree 20
    initrans 12
    maxtrans 255
    tablespace ts
    ALTER TABLE m
    ADD (CONSTRAINT pk_m_c PRIMARY KEY (doc_id, cid)
    USING index
    pctfree 20
    initrans 12
    maxtrans 255
    tablespace ts
    nologging )
    BEGIN
    ctx_ddl.create_preference('english_lexer', 'basic_lexer');
    ctx_ddl.set_attribute('english_lexer','index_themes','false');
    ctx_ddl.set_attribute('english_lexer','index_text','true');
    ctx_ddl.create_preference('japanese_lexer','japanese_lexer');
    ctx_ddl.create_preference('chinese_lexer','chinese_lexer');
    ctx_ddl.create_preference('korean_lexer','korean_morph_lexer');
    ctx_ddl.create_preference('german_lexer','basic_lexer');
    ctx_ddl.set_attribute('german_lexer','index_themes','false');
    ctx_ddl.set_attribute('german_lexer','index_text','true');
    ctx_ddl.set_attribute('german_lexer','composite','german');
    ctx_ddl.set_attribute('german_lexer','mixed_case','yes');
    ctx_ddl.set_attribute('german_lexer','alternate_spelling','german');
    ctx_ddl.create_preference('french_lexer','basic_lexer');
    ctx_ddl.set_attribute('french_lexer','index_text','true');
    ctx_ddl.set_attribute('french_lexer','index_themes','false');
    ctx_ddl.set_attribute('french_lexer','base_letter','yes');
    ctx_ddl.create_preference('spanish_lexer','basic_lexer');
    ctx_ddl.set_attribute('spanish_lexer','index_text','true');
    ctx_ddl.set_attribute('spanish_lexer','index_themes','false');
    ctx_ddl.set_attribute('spanish_lexer','base_letter','yes');
    ctx_ddl.create_preferences('global_lexer','multi_lexer');
    ctx_ddl.add_sub_lexer('global_lexer','default','english_lexer');
    ctx_ddl.add_sub_lexer('global_lexer','english','english_lexer','eng');
    ctx_ddl.add_sub_lexer('global_lexer','gernan','german_lexer','ger');
    ctx_ddl.add_sub_lexer('global_lexer','french','french_lexer','fra');
    ctx_ddl.add_sub_lexer('global_lexer','spanish','spanish_lexer','spa');
    ctx_ddl.add_sub_lexer('global_lexer','japanese','japanese_lexer','jpn');
    ctx_ddl.add_sub_lexer('global_lexer','korean','korean_lexer','kor');
    ctx_ddl.add_sub_lexer('global_lexer','simplified chinese','chinese_lexer','zho');
    ctx_ddl.add_sub_lexer('global_lexer','traditional chinese','chinese_lexer');
    END;
    BEGIN
    ctx_output.start_log('m_ctx_data.log');
    END;
    CREATE INDEX m_ctx_data ON m (data)
    INDEXTYPE IS ctxsys.context
    PARAMETERS ('memory 1G
    lexer global_lexer
    format column fmt
    language column iso_lang
    sync (every "sysdate+1")' )
    PARALLEL 6
    BEGIN
    ctx_output.end_log();
    END;
    /

  • Problem indexing with TREX

    Hi guys,
      We have some problems with our TREX system. This´s our environment:
      - SAP Netweaver 7 - SP17 (SUN Solaris)
      - SAP TREX 7 (Windows 2003 server)
      - IIS 6 with SSO to File Server (SSO22Kerbmap configured)
      The problem is that When indexing process is started, we detected that a lot of documents had preprocessing errors. We have in TREX log the following info for each file error:
    2009-06-14 17:46:01.589 e          preprocessor     Preprocessor.cpp(00897) :         HTTPHEAD failed for URL http://naspro01.xxxxxx.es:50000/irj/go/km/docs/departamentos/gc-idp/laboratorio/fichas%20de%20seguridad%20reactivos%20lab/merck_es_fichas%20de%20seguridad%20reactivos/1090/109033.pdf with Httpstatus 401
    2009-06-14 17:46:01.589 e          preprocessor     Preprocessor.cpp(03553) :         HANDLE: DISPATCH - Processing Document with key '/Departamentos/GC-IDP/Laboratorio/FICHAS DE SEGURIDAD REACTIVOS LAB/Merck_es_Fichas de Seguridad Reactivos/1090/109033.pdf' failed, returning PREPROCESSOR_ACTIVITY_ERROR (Code 6401)
    More information:
    - index_service user have super administrator rol in our system.
    - We have some errors in windows log about sso22kerbmap library. The text is 'Application failure: w3wp.exe, version:6.0.3790.3959, module: SSO22KerbMap.dll,version 1.1.0.8 ...'
    Can somebody help us to solve this problem?
    Best regards.

    Hi Julio,
    did you check the following SAP Note ?
    SAP Note 735639 - SSO22KerbMap: Known issues
    Did you also create an Active Directory User for the user index_service ?
    This is described on page 7 in my white paper "[Integration of Windows File Servers into the SAP KM platform using SSO and the WebDAV repository manager|http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/e1f93f5c-0301-0010-5c83-9681791f78ec]".
    Best regards,
    André

  • Performance Problems - Index and Statistics

    Dear Gurus,
    I am having problems lossing indexes and statistics on cubes ,it seems my indexes are too old which in fact are not too old just created a month back and we check indexes daily and it returns us RED on the manage TAB.
    please help

    Dear Mr Syed ,
    Solution steps I mentioned in my previous reply itself explains so called RE-ORG of tables;however to clarify more on that issue.
    Occasionally,ORACLE <b>Cost-Based Optimizer</b> may calculate the estimated costs for a Full Table Scan lower than those for an Index Scan, although the actual runtime of an access via an index would be considerably lower than the runtime of the Full Table Scan,Some Imperative points to be considered in order to perk up the performance and improve on quandary areas such as extensive running times for Change runs & Aggregate activate & fill ups.
    Performance problems based on a wrong optimizer decision would show that there is something serious missing at Database level and we need to RE_ORG  the degenerated indexes in order to perk up the overall performance and avoid daily manual (RSRV+RSNAORA)activities on almost similar indexes.
    For <b>Re-organizing</b> degenerated indexes 3 options are available-
    <b>1) DROP INDEX ..., and CREATE INDEX …</b>
    <b>2)ALTER INDEX <index name> REBUILD (ONLINE PARALLEL x NOLOGGING)</b>
    <b>3) ALTER INDEX <index name> COALESCE [as of Oracle 8i (8.1) only]</b>
    Each option has its Pros & Cons ,option <b>2</b> seems to be having lot of advantages to
    <b>Advantages- option 2</b>
    1)Fast storage in a different table space possible
    2)Creates a new index tree
    3)Gives the option to change storage parameters without deleting the index
    4)As of Oracle 8i (8.1), you can avoid a lock on the table by specifying the ONLINE option. In this case, Oracle waits until the resource has been released, and then starts the rebuild. The "resource busy" error no longer occurs.
    I would still leave the Database tech team be the best to judge and take a call on these.
    These modus operandi could be institutionalized  for all fretful cubes & its indexes as well.
    However,I leave the thoughts with you.
    Hope it Helps
    Chetan
    @CP..

  • Repartitioning Problem - Indexes Rebuild

    Hi, I decided a QA Repartitioning Test prior to any Production activities and I am ending up with an index problem on my InfoCube.  The Repartitioning Monitor Shows everything Green as a final result.  Deeper in the logs there is a yellow warning that all of the indexes could not be rebuilt.  Message RSDU_REPART450.
    So I have tried everything to rebuild the indexes on the infocube, but now the index status always shows up as red.  I am now trying a compression and then I'll try to rebuild the indexes again.  After the compression the E Fact Table is populated, but the F Fact Table still has records!  SAP_INFOCUBE_DESIGNS showst that both the F and E Tables have 2+ million records!  The compression Logs say everything went fine and I verified the performance tab shows all requests as compressed!  What Gives...
    /BIC/EZ_P_C003      rows:  2,812,700    ratio:         50  %
    /BIC/FZ_P_C003      rows:  2,856,833    ratio:         50  %
    Any ideas or advice what I should do next?

    Found Note 1283322 - Repartitioning corrupts the indexes
    Note sure if this fixes it.  The Note is only valid for SPS 16 and above and we are only at SPS 15.
    If you read the note it says that your InfoCube Indexes get corrupt if your infocube name is more than 7 characters.  Who tested that functionality??? 
    Thanks,

  • Oracle XE 10.2.0.1.0  - Problem indexing PDF

    I am using Oracle XE 10.2.0.1.0 with Czech national settings set.
    I need to make PDF with czech national characters working. Indexing TXT, HTML and DOC2003 documents with the same content works fine.
    Below is my configuration.
    h1. National Language Support
    NLS_CALENDAR GREGORIAN
    NLS_CHARACTERSET AL32UTF8
    NLS_COMP BINARY
    NLS_CURRENCY Kč
    NLS_DATE_FORMAT DD.MM.RR
    NLS_DATE_LANGUAGE CZECH
    NLS_DUAL_CURRENCY Kč
    NLS_ISO_CURRENCY CZECH REPUBLIC
    NLS_LANGUAGE CZECH
    NLS_LENGTH_SEMANTICS BYTE
    NLS_NCHAR_CHARACTERSET AL16UTF16
    NLS_NCHAR_CONV_EXCP FALSE
    NLS_NUMERIC_CHARACTERS ,.
    NLS_SORT CZECH
    NLS_TERRITORY CZECH REPUBLIC
    NLS_TIME_FORMAT HH24:MI:SSXFF
    NLS_TIMESTAMP_FORMAT DD.MM.RR HH24:MI:SSXFF
    NLS_TIMESTAMP_TZ_FORMAT DD.MM.RR HH24:MI:SSXFF TZR
    NLS_TIME_TZ_FORMAT HH24:MI:SSXFF TZR
    h1. Datastore
    PDF url: http://www.mpsv.cz/files/clanky/6981/tiskove_avizo_CJ.pdf
    I renamed the pdf to SummitKZamestnanosti_PDF-40.
    CREATE TABLE file_datastore
    id NUMBER PRIMARY KEY,
    fmt varchar2(10),
    docs VARCHAR2(2000)
    -- INSERT data INTO File Datastore TABLE
    INSERT INTO file_datastore VALUES
    (111560,'binary','C:\Docs\SummitKZamestnanosti_PDF-40'
    -- Configure DATASTORE
    EXEC ctx_ddl.drop_preference('NO_PATH');
    EXEC ctx_ddl.create_preference('NO_PATH','FILE_DATASTORE');
    -- Configure LEXER
    EXEC ctx_ddl.drop_preference('LEXER');
    EXEC ctx_ddl.create_preference('LEXER','BASIC_LEXER');
    -- CREATE CONTEXT INDEX
    DROP INDEX idx_file_datastore_text FORCE;
    CREATE INDEX idx_file_datastore_text ON file_datastore
    ( docs )
    indextype IS ctxsys.context parameters
    ( 'format column fmt Datastore NO_PATH filter ctxsys.AUTO_FILTER lexer LEXER' );
    -- QUERIES that should work.
    -- SELECT id, docs, score(1) FROM file_datastore WHERE contains ( docs,'Bližší',1 ) > 0;
    SELECT id, docs, score(1) FROM file_datastore WHERE contains ( docs,'dopadů ',1 ) > 0;
    -- SELECT id, docs, score(1) FROM file_datastore WHERE contains ( docs,'sociálních',1 ) > 0;
    SELECT id, docs, score(1) FROM file_datastore WHERE contains ( docs,'Španělsko',1 ) > 0;
    -- SELECT id, docs, score(1) FROM file_datastore WHERE contains ( docs,'Švédska',1 ) > 0;
    SELECT id, docs, score(1) FROM file_datastore WHERE contains ( docs,'Summit',1 ) > 0;
    h1. My Output
    ID DOCS
    0 rows selected
    ID DOCS
    0 rows selected
    ID DOCS
    111560 C:\Docs\SummitKZamestnanosti_PDF-40
    1 rows selected
    Regards

    I have used the 100% same configuration as above, but now for the Oracle Database 11g R1 11.1.0.7.0 – Production instead of Oracle 10g XE.
    The result is that AUTO_FILTER for Oracle 11g is able to parse Czech language characters from the sample PDF file without any problems.
    The problem with Oracle Text 10g R2 may be I guess:
    1. In embedded fonts as mentioned in the Link: [documentation | http://download-west.oracle.com/docs/cd/B12037_01/text.101/b10730/afilsupt.htm] (I tried to embbed all fonts and the whole character set, but it did not helped)
    2. in the character encoding of the text within the PDF documents.
    I would like to add that also other third party PDF2Text converters have similar issues with the Czech characters in the PDF documents – after text extraction Czech national characters were displayed incorrectly.
    If you have any other remarks, ideas or conclusions please reply :-)

  • Looping Problem-Index

    Dear all,
    I am unable to get the index read correctly for my IT_DISPLAY table.There are 2 values in plaf table and multible in display table.
    how to get the correct index value for my display table?since currently it is on plaf table.due to this index problem,my values get moved incoreectly
    code is as follows
    SORT IT_AFPO BY PLNUM.
    SORT IT_PLAF BY PLNUM.
    LOOP AT IT_AFPO INTO WA_AFPO.
    LOOP AT IT_PLAF INTO WA_PLAF.
      W_INDEX = SY-TABIX.
    IF WA_PLAF-PLNUM = WA_AFPO-PLNUM.
       MOVE:WA_PLAF-GSMNG TO WA_DISPLAY-GAMNG.
       MODIFY IT_DISPLAY INDEX W_INDEX FROM WA_DISPLAY TRANSPORTING GAMNG.
      ENDIF.
      CLEAR:WA_PLAF,WA_DISPLAY.
    ENDLOOP.
    CLEAR:WA_AFPO.
    ENDLOOP.

    Hai Rahul try like this..
    SORT IT_AFPO BY PLNUM.
    SORT IT_PLAF BY PLNUM.
    LOOP AT IT_AFPO INTO WA_AFPO.
    read table IT_PLAF INTO WA_PLAF with key PLNUM = WA_AFPO-PLNUM binary search.
    if sy-subrc eq 0.
    W_INDEX = SY-TABIX.
    MOVE:WA_PLAF-GSMNG TO WA_DISPLAY-GAMNG.
    MODIFY IT_DISPLAY INDEX W_INDEX FROM WA_DISPLAY TRANSPORTING GAMNG.
    endif.
    ENDIF.
    CLEAR:WA_PLAF,WA_DISPLAY.
    CLEAR:WA_AFPO.
    ENDLOOP.
    if you have to do a loop in a loop
    SORT IT_AFPO BY PLNUM.
    SORT IT_PLAF BY PLNUM.
    LOOP AT IT_AFPO INTO WA_AFPO.
    LOOP AT IT_PLAF INTO WA_PLAF where PLNUM = WA_AFPO-PLNUM .
    W_INDEX = SY-TABIX.
    MOVE:WA_PLAF-GSMNG TO WA_DISPLAY-GAMNG.
    MODIFY IT_DISPLAY INDEX W_INDEX FROM WA_DISPLAY TRANSPORTING GAMNG.
    CLEAR:WA_PLAF,WA_DISPLAY.
    ENDLOOP.
    CLEAR:WA_AFPO.
    ENDLOOP.

  • MS docs having problems indexing

    Hi there,
    I try to check out a MS Office file and this is what I get:
    Account: prj/PRJ000001
    Checked Out By:     
    Status: GenWWW
    Formats: application/vnd.ms-excel
    Now it doesn't index, i try reindexing nothing... i search for GenWWW and some people blamed IBR but i disabled it and nothing. Someone else talked about partitions and no, that's no my case. I'm puzzle about this one, pfd, txt, files work correctly.
    As a result I can't see the "Web Location" link either, nor can't find the file on search (well this is implied by the this-does-not-index). Any ideas?

    OK we seem to have 1 refinery server, but all it says is:
    Type Time Description [ Details ]
    Info 2009/58/16 11:58 PM Agent is initialized.
    Info 2009/58/16 11:58 PM Agent queue is being monitored.
    (yes I don't know what is going on with the date)
    I just noticed we don't have the IBR provider setup to it >_<, it must have been removed somehow, I'm going to add it and see what happens.
    Thanks for your help I really appreciate it
    EDITED: I added the IBR provider and it worked, i'll mark you both helpful for pointing me in the right direction, thank you.
    Edited by: malky on Jun 23, 2009 2:25 PM

  • Problems indexing .cfm page

    I have a page at www.salleboise.com/contact.cfm that I am
    trying to index on
    a internal search program. The program won't read that
    particular file, but
    will index other .cfm files just fine. I don't see anything
    that would
    prevent the file from being read, but what I'm being told by
    the support for
    the search software is that this particular page is only
    responding to IE
    requests, not generic requests.
    What can I change? All the other page have the following
    <!DOCTYPE HTML
    PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    http://www.w3.org/TR/html4/loose.dtd">
    before the page starts, just like
    the contact.cfm page....
    What can I do?????

    I use a program called Zoom to create a internal search of my
    site.
    Zoom has its own index tool, and will index most of my .cfm
    pages, but won't
    do the one in question because (based on what their support
    says) it only
    reponds to IE or FF browser, not a generic GET command.
    Hopefully that makes more sense??
    "dempster" <[email protected]> wrote in
    message
    news:f7mf34$30m$[email protected]..
    > Do you mean that the search program won't crawl the
    page? It could be that
    > the
    > link is created by a JavaScript program which would work
    within a browser
    > but
    > not by the crawler. Could you provide more details?
    >

  • Error while creating an Index in SP14..Please help..  :(

    Hello All,
    Im working on SP14.
    Got an error as below while creating an Index:
    " <b>Index could not be created; creating index failed: general configuration error (Errorcode 2030)"</b>
    Whats wrong..?
    Please help.
    Awaiting Reply.
    Thanks and Warm Regards,
    Ritu R Hunjan

    Hi Ritu & Subrato,
    I'm affraid Errorcode 2030 is related to TREX user administrative rights in the OS.
    Please take a look at this thread and the suggestions give there to fix your problem:
    Index creation failure and other problems
    Hope this helps,
    Robert

  • INDEX GETTING UNUSABLE

    Hello everybody,
    I'm using Oracle 9i and I'm getting below error when I execute a anonymous block which runs through the cursor and updates the table.
    ORA-01502: index 'ASAP.PK_STATUS_NO' or partition of such index is in unusable state
    select query on the same table is executing fine but seems that update is getting troubled. And the status number column is declared to be primary key
    Can anyone tell me what and where the problem might be ???
    regards,
    Rossy

    From Oracle Metalink Note: 336195.1
    Solution
    There can be multiple causes of for the ORA-1502 ... all are expected behaviour and the index needs to be recreated in to resolve the error
    Causes
    1) The table was loaded using a direct load method (import ... sqlloader ... insert with the APPEND hint ... a direct write from a C program)
    2) An ALTER INDEX ... REBUILD failed and left the index in an unusable state
    3) The problem index was a global index on a partitioned table and an EXCHANGE PARTITION was done
    4) The table was moved to a different location using ALTER TABLE ... MOVE
    5) Per the Application developers guide:
    If alter table command is used to change the underlying data of a column from LONG to CLOB or LONG RAW to BLOB. All indexes must be rebuilt
    Regards, Gerwin
    Edited by: Gerwin Hendriksen on May 29, 2009 11:45 AM

  • Google index external HTML data sets?

    I know one of the workarounds to have Google properly index
    dynamic content is to use HTML data sets, but I'm unclear about one
    thing. Does this only work if you have the HTML data set table on
    the same page you use it with, or does it also work with external
    HTML data sets?
    For instance, will Google have a problem indexing if I use a
    external HTML data set like:
    <script type="text/javascript">
    <!--
    var educationLinks = new
    Spry.Data.HTMLDataSet("links/educationLinks.htm",
    "educationLinks");
    //-->
    </script>
    <div spry:region="educationLinks" id="linksContainer"
    class="SpryHiddenRegion">
    <ul spry:repeatchildren="educationLinks"
    class="unorderedLinkList">
    <li><a href="{url}"
    target="_blank">{name}</a> - {description}</li>
    </ul>
    <!-- end #linksContainer -->
    </div>

    I'm doing the same exact thing using external HTML data sets
    instead of XML. It is true that spiders will not index the external
    page based on the Spry data you noted. My solution will be to
    create a sitemap.xml page and submit it to the search engines. That
    sitemap.xml file will contain all the pages in your site and the
    spiders will use it as a central point to crawl all of those pages
    specified within. So, I will just include my externally referenced
    files in the sitemap.xml file.
    Checkout
    http://www.sitemap.org for more
    information on that.

  • File datastore problem

    Hi all,
    I have a problem indexing files residing on a different server from the one where oracle system resides. I can however load the files into BLOB field using SQLLDR and later index them using CTXSYS.CONTEXT type.
    The problem is when using file_datastore to index the files remotely rather than copying them to the database
    As shown below:
    exec ctx_ddl.create_preference('My_user_datastore', 'FILE_DATASTORE');
    exec ctx_ddl.create_preference('My_index_storage', 'BASIC_STORAGE');
    exec ctx_ddl.set_attribute('My_index_storage', 'I_TABLE_CLAUSE','tablespace indx storage (initial 1m)');
    exec ctx_ddl.set_attribute('My_index_storage', 'K_TABLE_CLAUSE','tablespace indx storage (initial 1m)');
    exec ctx_ddl.set_attribute('My_index_storage', 'R_TABLE_CLAUSE','tablespace indx storage (initial 1m)');
    exec ctx_ddl.set_attribute('My_index_storage', 'N_TABLE_CLAUSE','tablespace indx storage (initial 1m)');
    exec ctx_ddl.set_attribute('My_index_storage', 'I_INDEX_CLAUSE','tablespace indx storage (initial 1m)');
    Then create the index as:
    CREATE INDEX FILES_INDX
    ON FILES_TABLE(FILE_PATH)
    INDEXTYPE IS CTXSYS.CONTEXT
    parameters ('datastore My_user_datastore storage My_index_storage memory 1m');
    This creates a ghost index.
    Can anybody help?
    Thanks in advance
    Regards
    Nehro

    If you use Windows platform it's possible
    because Oracle does not support BFILE work with UNC paths.
    You can use USER_DATASTORE and read files through HTTP protocol or using Java procedure for loading files from
    remote host.
    If you want I can send you my Java stored procedure for
    work with files.

  • Problem Programing

    Microsoft Windows XP [Version 5.1.2600]
    (C) Copyright 1985-2001 Microsoft Corp.
    C:\Documents and Settings\Kenneth Rinderhagen>cd C:\
    C:\>java HelloWorldApp
    Exception in thread "main" java.lang.NoClassDefFoundError: HelloWorldApp
    Caused by: java.lang.ClassNotFoundException: HelloWorldApp
    at java.net.URLClassLoader$1.run(Unknown Source)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at java.lang.ClassLoader.loadClassInternal(Unknown Source)
    C:\>

    {color:0000ff}http://java.sun.com/docs/books/tutorial/getStarted/problems/index.html{color}

  • Can the contents of a Spry Widget (accordion panel, etc.) be indexed by search engines?

    I have an equipment list that I want to include on a webpage. It's so long in straight HTML, even with  CSS turning things into columns that it seems to be a good candidate for a Spry Panel. But I need to be sure that it will be indexed, because people who are looking for a machine shop often look for a specific piece of equipment and the contents need to be searchable. (Otherwise, I'd just create a PDF from the original InDesign doc and put it out there that way.
    Thanks.

    Hi and welcome -
    I have a number of sites with accordion type scripts and find Google has no problem indexing hidden content and returning results ranked by it.

Maybe you are looking for

  • How to install Oracle Database 10.2.0.3

    Hi, I need to install Database 10.2.0.3 in a Windows Server 2003 R2, but I don`t kown what is the best opcion: a) Install directy Database 10.2.0.3 that I have downloaded from Oracle web http://www.oracle.com/technology/software/products/database/ind

  • How to edit text of UI elements in sap standard ABAP webdynpro component

    Hi All, I have a requirement wherein I want to change the standard text of mainly LABEL UI in travel and expenses ABAP webdynpro components. As per my knowledge we canu2019t change UI text directly by changing it in layout in enhancement. We have to

  • SwingWoker

    Hi All I am facing a flickering problem in applet when using SwingWorker class from sun i want to do some background processing in event thread SwingUtilities.invokeLater did help me but not that much GUI used to get freeze to prevent that i have use

  • Video with aim user

    I'm trying to video conference with an aim user, however, the video feed from my aim buddy is full of pixels. I mean, it's so bad I can barely see make out my buddy. I know my buddy has a good web cam, so it's not that. Is there any setting that need

  • Drill down problem in a row structure

    Hi Experts, Could you throw some light on the following issue. I have a P&L report with one KF and one Char structure in the query. my char structure is as follows A - Selection B - Selection C - Formula (A+B) D - Selection E - Selection F - Selectio