[Search for users]
[Overall Top Noters]
[List of all Conferences]
[Download this site]
Title: | *OLD* ALL-IN-1 (tm) Support Conference |
Notice: | Closed - See Note 4331.l to move to IOSG::ALL-IN-1 |
Moderator: | IOSG::PYE |
|
Created: | Thu Jan 30 1992 |
Last Modified: | Tue Jan 23 1996 |
Last Successful Update: | Fri Jun 06 1997 |
Number of topics: | 4343 |
Total number of notes: | 18308 |
2391.0. "FOR FIRST/Alternate key Search" by AIMTEC::BUTLER_T () Wed Mar 10 1993 18:41
Hello:
I am working a problem of "alternate key doing sequential search."
ALL help, comments, appreciated.
Below is the entry form named data, trace, and script. The only thing
I have been able to determine, working with the customer, is that
if I have him specify a dsr with a kor, he gets nothing back! I had
him enter the form with a primary key and the field had a value.
The alternate key/field in question is TDATE.
Does usinf FOR FIRST imply a sequential search on an alternate key?
Thanks,
Tim
Thank you for your help so far with this problem. I am sending the following
files:
CRSE - This is the entry form
CRSE.FDL - The FDL for the database
CRS_PRINT_MENU_WEEK.SCP - Script with the for loop
A1TRACE.LOG - The trace file you requested
CRS.DAT - 5 lines from the database
Thanks for your help.
Kevin Hoot
CRSE*****************************
! FMS Form Description Application Aid
NAMED_DATA INDEX=1 NAME='.TYPE'
DATA='ENTRY/MODE=UPDATE/KEY=BUILDING,NUMBER,START/POST=''IFEXIT\' ;
NAMED_DATA INDEX=2 NAME='.TYPE'
DATA='GET $MEET_KEY=ROOM START''' ;
NAMED_DATA INDEX=3 NAME='.FILE'
DATA='SITE_ALLIN1_FILES:CRS.DAT,SITE_ALLIN1_FILES:CRS.FDL' ;
NAMED_DATA INDEX=4 NAME='BUILDING'
DATA='/RECOG=CRSRM.BUILDING;' ;
NAMED_DATA INDEX=5 NAME='BUILDING'
DATA=' CLOSE_PRIOR\' ;
NAMED_DATA INDEX=6 NAME='BUILDING'
DATA=' GET BUILDING=OA$SEL_KEY:1\' ;
NAMED_DATA INDEX=7 NAME='BUILDING'
DATA=' GET NUMBER=OA$SEL_KEY:4:1\' ;
NAMED_DATA INDEX=8 NAME='BUILDING'
DATA=' OA$FLD_NEXT' ;
NAMED_DATA INDEX=9 NAME='BUILDING'
DATA='/SHOW=.BUILDING " " .NUMBER " " .NAME' ;
NAMED_DATA INDEX=10 NAME='NUMBER'
DATA='/RECOG=CRSRM WITH .BUILDING = BUILDING AND .NUMBER = NUMBER;' ;
NAMED_DATA INDEX=11 NAME='NUMBER'
DATA=' CLOSE_PRIOR\' ;
NAMED_DATA INDEX=12 NAME='NUMBER'
DATA=' GET NUMBER = OA$SEL_KEY:4:1\' ;
NAMED_DATA INDEX=13 NAME='NUMBER'
DATA=' GET BUILDING = OA$SEL_KEY:1\' ;
NAMED_DATA INDEX=14 NAME='NUMBER'
DATA=' OA$FLD_NEXT' ;
NAMED_DATA INDEX=15 NAME='NUMBER'
DATA='/RSE' ;
NAMED_DATA INDEX=16 NAME='NUMBER'
DATA='/SHOW=.BUILDING " " .NUMBER " " .NAME' ;
NAMED_DATA INDEX=17 NAME='SCHEDULER'
DATA='/PRE=''GET SCHEDULER=OA$USER\OA$FLD_NEXT''' ;
END_OF_FORM NAME='CRSE' ;
CRSE.FDL ***************************
TITLE "MEET_ROOM"
IDENT " 7-MAR-1993 16:01:08 VAX-11 FDL Editor"
SYSTEM
SOURCE "VAX/VMS"
FILE
ORGANIZATION indexed
RECORD
CARRIAGE_CONTROL carriage_return
FORMAT fixed
SIZE 244
AREA 0
ALLOCATION 8589
BEST_TRY_CONTIGUOUS yes
BUCKET_SIZE 6
EXTENSION 2148
AREA 1
ALLOCATION 138
BEST_TRY_CONTIGUOUS yes
BUCKET_SIZE 6
EXTENSION 36
AREA 2
ALLOCATION 2535
BEST_TRY_CONTIGUOUS yes
BUCKET_SIZE 9
EXTENSION 645
KEY 0
CHANGES no
DATA_AREA 0
DATA_FILL 100
DATA_KEY_COMPRESSION yes
DATA_RECORD_COMPRESSION yes
DUPLICATES no
INDEX_AREA 1
INDEX_COMPRESSION yes
INDEX_FILL 100
NAME "MEET_ROOM"
PROLOG 3
SEG0_LENGTH 21
SEG0_POSITION 0
TYPE string
KEY 1
CHANGES no
DATA_AREA 2
DATA_FILL 100
DATA_KEY_COMPRESSION yes
DUPLICATES yes
INDEX_AREA 2
INDEX_COMPRESSION yes
INDEX_FILL 100
NAME "BUILDING"
SEG0_LENGTH 1
SEG0_POSITION 0
TYPE string
KEY 2
CHANGES no
DATA_AREA 2
DATA_FILL 100
DATA_KEY_COMPRESSION yes
DUPLICATES yes
INDEX_AREA 2
INDEX_COMPRESSION yes
INDEX_FILL 100
LEVEL1_INDEX_AREA 2
NAME "NUMBER"
SEG0_LENGTH 4
SEG0_POSITION 1
TYPE string
KEY 3
CHANGES no
DATA_AREA 2
DATA_FILL 100
DATA_KEY_COMPRESSION yes
DUPLICATES yes
INDEX_AREA 2
INDEX_COMPRESSION yes
INDEX_FILL 100
LEVEL1_INDEX_AREA 2
NAME "START"
SEG0_LENGTH 16
SEG0_POSITION 5
TYPE string
KEY 4
CHANGES no
DATA_AREA 2
DATA_FILL 100
DATA_KEY_COMPRESSION yes
DUPLICATES yes
INDEX_AREA 2
INDEX_COMPRESSION yes
INDEX_FILL 100
LEVEL1_INDEX_AREA 2
NAME "TDATE"
SEG0_LENGTH 11
SEG0_POSITION 218
TYPE string
A1TRACE.LOG**************************8
![IO] Getting next record from TXT$TXL_DO, Text starts "FOR FIRST CRSE "
![SCRIPT] SITE_ALLIN1_SCRIPTS:CRS_PRINT_MENU_WEEK.SCP Line 23: FOR FIRST CRSE WI
! TH .TDATE EQS #TEMP_1_DATE DO GET #TEMP_ROOM=.%KEY:5
![FUNC] Function: FOR, Cmd line: FIRST CRSE WITH .TDATE EQS #TEMP_1_DATE DO GE
! T #TEMP_ROOM=.%KEY:5
![A1LOG] Entry: %OA-I-LOGFUN, Function: FOR FIRST CRSE WITH .TDATE
! EQS #TEMP_1_DATE DO GET #TEMP_ROOM=.%KEY:5
![SYMBOL] Symbol: #TEMP_1_DATE, Value: 04-Mar-1993
![IO] Rewinding CRSE, Key-of-ref: MEET_ROOM/0
![IO] Getting record from CRSE by RSE
![IO] Getting next record from CRSE
![IO] Getting field TDATE from CRSE, Value: 28-Feb-1993
![SYMBOL] Symbol: .TDATE, Value: 28-Feb-1993
![IO] Getting next record from CRSE
![IO] Getting field TDATE from CRSE, Value: 28-Feb-1993
![SYMBOL] Symbol: .TDATE, Value: 28-Feb-1993
![IO] Getting next record from CRSE
![IO] Getting field TDATE from CRSE, Value: 28-Feb-1993
![SYMBOL] Symbol: .TDATE, Value: 28-Feb-1993
![IO] Getting next record from CRSE
![IO] Getting field TDATE from CRSE, Value: 01-Mar-1993
![SYMBOL] Symbol: .TDATE, Value: 01-Mar-1993
![IO] Getting next record from CRSE
![IO] Getting field TDATE from CRSE, Value: 02-Mar-1993
![SYMBOL] Symbol: .TDATE, Value: 02-Mar-1993
![IO] Getting next record from CRSE
![IO] Getting field TDATE from CRSE, Value: 03-Mar-1993
![SYMBOL] Symbol: .TDATE, Value: 03-Mar-1993
![IO] Getting next record from CRSE
![IO] Getting field TDATE from CRSE, Value: 04-Mar-1993
![SYMBOL] Symbol: .TDATE, Value: 04-Mar-1993
![FUNC] Function: GET, Cmd line: #TEMP_ROOM=.%KEY:5
![A1LOG] Entry: %OA-I-LOGFUN, Function: GET #TEMP_ROOM=.%KEY:5
![SYMBOL] Symbol: #TEMP_ROOM=.%KEY:5, Value: R340
CRS_PRINT_MENU_WEEK.SCP*********************************
FOR FIRST CRSE WITH .TDATE EQS #TEMP_1_DATE DO GET #TEMP_ROOM=.%KEY:5
FOR CRSE WITH .TDATE EQS #TEMP_1_DATE DO -
CRS.DAT*******************8
R340 19930228090000001993022810000000L L L L L 04 0 HOOTKB 28-Feb-199309:00am 10:00am
R340 19930228100000001993022811000000l l l l l 04 0 HOOTKB 28-Feb-199310:00am 11:00am
R340 19930228110000001993022812000000L L L L L 04 0 HOOTKB 28-Feb-199311:00am 12:00pm
R340 19930228120000001993022813000000l l l l l 04 0 HOOTKB 28-Feb-199312:00pm 01:00pm
T.R | Title | User | Personal Name | Date | Lines |
---|
2391.1 | CRS on ALL-IN-1 v3.0??? | AIMTEC::WICKS_A | I dreamt I found a working printer! | Wed Mar 10 1993 18:47 | 12 |
| Tim,
Two important missing bits of information in your base note
1) version of ALL-IN-1 - presumably v3.0?
2) whether this bit of named data comes from the unsupported and not
upgraded to version 3.0 yet COnference Room Scheduler ASSET?
Regards,
Andrew.D.Wicks
|
2391.2 | Lets not throw the product out with the asset | AIMTEC::BUTLER_T | | Thu Mar 11 1993 12:51 | 10 |
| Andrew,
It is v3.0 and crs.
I am more concerned with the alternate key, sequential search part
of this.
Thanks,
Tim
|
2391.3 | | AIMTEC::ZANIEWSKI_D | Why would CSC specialists need training? | Thu Mar 11 1993 13:00 | 7 |
| Hi Tim,
Why don't you try this with a supported dataset? AIE (action item
entry form) or CALACCENT (calendar access management entry form)
are two, and see if the results are the same.
Dave Zaniewski
|
2391.4 | still looking | AIMTEC::BUTLER_T | | Thu Mar 11 1993 16:01 | 28 |
|
OA$MINOR_FLAME_ON
I am not talking about supported or unsupported data sets. I am
talking about a plain entry form with an fdl and the for function
with the first parameter.
I can change the name on the plain vanilla entry form and the fdl
and get the same thing. Because I changed the name makes it supported?
OA$MINOR_FLAME_OFF
Re .1 & .2
I know you are not telling me that because Digital created the dataset
makes a difference. I have looked at the fdl and it looks fine.
Now I feel better, I am still trying to determine if the for first
is supposed to do a keyed lookup and in this case if the field has
a value in the data set, mapped by the entry form, why when I
interactively use a dsr format with a key-of-reference I get no
value returned.
Any help is still appreciated,
Tim
|
2391.5 | | IOSG::MAURICE | Because of the architect the building fell down | Thu Mar 11 1993 16:58 | 11 |
| Hi,
Do you really mean alternate key, or do you really mean segmented key?
In the FOR FIRST example what is in the value of the symbols. Perhaps
it's a case of using .%key as in
for first xxxx with .%key = #xxxx do get #y = .%key
HTH
Stuart
|
2391.6 | works for me | AIMTEC::ZANIEWSKI_D | Why would CSC specialists need training? | Thu Mar 11 1993 17:49 | 10 |
| If you mean alternate key then the syntax for your FOR is
incorrect.
FOR FIRST CALACCENT:ACCUSER WITH .ACCUSER = "ZANIEWSKI_D" ...
This does an indexed search on my system. I won't take offense
Tim. I was just trying to point you where I knew there were
working examples.
Dave Zaniewski
|
2391.7 | Mixed case in field | AIMTEC::BUTLER_T | | Thu Mar 11 1993 18:17 | 9 |
| re .5
Thanks Stuart. I am waiting to try this on the customers system.
The only other thing we have found to date was that the field
contained MIXED case. Uppercasing appears to do the trick.
Tim
|
2391.8 | crs write mixed case | AIMTEC::BUTLER_T | | Thu Mar 11 1993 19:20 | 8 |
| re .6 .7
It turns out that the CRS writes mixed case to other files in
ALL-IN-1! That is what I think Andrew and Dave were getting too.
Thanks,
Tim
|