HP3000-L Archives

November 2000, Week 3

HP3000-L@RAVEN.UTC.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Tony Summers <[log in to unmask]>
Reply To:
Tony Summers <[log in to unmask]>
Date:
Tue, 21 Nov 2000 16:36:52 +0000
Content-Type:
text/plain
Parts/Attachments:
text/plain (50 lines)
Hello all. and many thanks in advance.

I'm experimenting with B-trees in Image and have managed to rebuild an 
Manual Master dataset with a b-tree index and can demonstrate using a 
Cobol program that my DBFIND and DBGET calls are using the b-tree to 
return records from the dataset in primary key order. 

However, I cannot get the structured arguement parameter to work - the DBFIND 
call always returns the CHAIN-COUNT equal to the number of records in the 
dataset rather than the number of records that should qualify. 

I.e. the superset chain is always the number of records on the dataset. 

Is there a known problem with DBFIND/structured parameters ? 

Or can someone spot an error in the following fragments ...


 1   B-TREE.
 3    FILLER                   PIC XX VALUE "[]".
 3    FILLER                  PIC S9(4) COMP SYNC VALUE 0.
 3    FILLER                  PIC S9(4) COMP SYNC VALUE 6.
 3    FILLER                   PIC S9(4) COMP SYNC VALUE 6.
 3    FILLER                   PIC X(12)
                    VALUE "CA000 DA000 ".  << client key is 6 bytes of format AAnnn + space >> 

     MOVE 4  TO DB-MODE
     MOVE "CLIENT;" TO LIST
     MOVE "CLIENTFILE;" TO CLIENTMASTER
     CALL "DBFIND" USING DBNAME
                         CLIENTMASTER
                         DB-MODE
                         STATUS1
                         LIST
                         b-tree

       IF CONDITION NOT = 0 THEN
          PERFORM MD9999-GET-ERROR-AND-EXPLAIN
       END-IF
       DISPLAY " CHAIN COUNT " CHAIN-COUNT

     MOVE 5 TO DB-MODE
     MOVE "CLIENT,CLIENTNAME1,CLIENTNAME2;" TO LIST
     MOVE "CLIENT;" TO LIST

     PERFORM WITH TEST AFTER UNTIL DONE
         CALL "DBGET" USING DBNAME, CLIENTMASTER, DB-MODE,
                            STATUS1, LIST, CLIENTMASTER-BUFFER,
                            NOT-USED-PARM-32

ATOM RSS1 RSS2