Action command S (select) on dates/numbers
Boyle, Joe
Joe.Boyle@cognos.com
Wed, 16 May 2001 07:41:46 -0400
an afterthought, you may have tried the 'entering %@6@ ' approach and found
that it failed.
The problem could be that you are entering the pattern too early.
Select processing first prompts for request responses in the path procedure
and then places you back in the action field. Once back in the action field
you should see a message like "Enter ID-numbers for select values or press
NEXT DATA to start data retrieval.", it is at this point that you can enter
the id of a field in which to enter a pattern.
MODE:S ACTION:S
01 Employee No
02 Last Name
Using the example above where both fields are index segments on separate
indexes, the dialogue would go as below where Q is the quick prompt and R is
your response,
Q1. action field
R1. S
path procedure
Q2. ID 1
R2. return
Q3. ID 2
R3. return
Q4. action field
R4. 1
Q5. ID 1
R5. %@6@
Q6. action field
R6. return
MODE:S ACTION:
01 Employee No 2,560
02 Last Name ???jo4
03 Employee No 655,360
04 Last Name ??jo3
The full data set is below,
MODE:F ACTION:
01 Employee No 0
02 Last Name ?????jo6
03 Employee No 1
04 Last Name jo
05 Employee No 10
06 Last Name ????jo5
07 Employee No 2,560
08 Last Name ???jo4
09 Employee No 655,360
10 Last Name ??jo3
11 Employee No ########
12 Last Name ?jo2
Alas, for some strange reason the message 'This entry must be numeric.'
appears at the bottom of the screen.
regards,
Joe Boyle.
-----Original Message-----
From: Boyle, Joe [mailto:Joe.Boyle@cognos.com]
Sent: 16 May 2001 11:56
To: 'Markus Grossrieder'; Powerhouse List (E-mail)
Subject: RE: Action command S (select) on dates/numbers
Hi Markus,
I am assuming that by your comment 'S action for dates (or numbers)' you are
referring to select processing. I've found that select patterns do work e.g.
entering %@6@ will find all numeric values containing the digit 6.
The field structure as seen from Quick is EMPLOYEE_NO OF EMPLOYEES NUMERIC
-9(6), this is a c-isam file on Unix.
For a list of other patterns which may work, look in the 'Pattern Matching
in Powerhouse' section of your Qdesign statement manual.
I have also found that syntax like that below will achieve the equivalent of
the '@@' function when used with indexes containing numeric segments, but
only with btree type file systems such as RMS, Xbase etc... I seem to recall
that Oracle and SQL did'nt like this.
proc input TEST1_DATO
begin
; this input procedure is required only if you have to rework a date format
entered by the user. Not required if ; not a date
;
if 5 lt size(truncate(fieldtext))
then begin
if 7 gt size(truncate(fieldtext))
then begin
if 20 gt nconvert ( fieldtext[5:2] )
then let t1 = nconvert ( &
( "20" + fieldtext[5:2] &
+ fieldtext [3:2] + fieldtext [1:2] ))
else let t1 = nconvert ( &
( "19" + fieldtext[5:2] &
+ fieldtext [3:2] + fieldtext [1:2] ))
end
else let t1 = nconvert ( &
( fieldtext[5:4] &
+ fieldtext [3:2] + fieldtext [1:2] ))
end
END
PROCEDURE PATH
BEGIN
let t-flag = "P"
REQUEST TEST1_DATO OF TEST1
IF PROMPTOK
THEN LET PATH = 1
IF PATH = 0
THEN BEGIN
LET PATH = 2
END
END
PROCEDURE FIND
BEGIN
for display test1
begin
IF PATH = 1
THEN begin
if t-flag = "P"
then begin
let t-flag = "F"
; next, set the pointer in the file
GET TEST1 unique &
VIA TEST1_DATO using T1 optional
end
else GET TEST1 SEQUENTIAL
end
IF PATH = 2
THEN GET TEST1 SEQUENTIAL
end
END
regards,
Joe Boyle.
-----Original Message-----
From: Markus Grossrieder [mailto:markus.grossrieder@alba-systems.com]
Sent: 16 May 2001 10:25
To: Powerhouse List (E-mail)
Subject: Action command S (select) on dates/numbers
Hi all,
I just wonder if it is possible to use the S action for dates (or numbers)
in
combination with wildcards, i.e.
- all invoices with '1999' in the date
- all clients with '000' in the clients ID number
- etc.
I never find out if it's possible and
(if yes) how to do it, or
(if not) why not (Conrad, Bob) ?
TIA, Markus
ps: PH 8.13d (HP Unix), 7.10g (VMS)
= = = = = = = = = = = = = = = = = = = = = = = = = = = =
Mailing list: powerh-l@lists.swau.edu
Subscribe: "subscribe" in message body to powerh-l-request@lists.swau.edu
Unsubscribe: "unsubscribe" in message body to
powerh-l-request@lists.swau.edu
http://lists.swau.edu/mailman/listinfo/powerh-l
This list is closed, thus to post to the list you must be a subscriber.
= = = = = = = = = = = = = = = = = = = = = = = = = = = =
Mailing list: powerh-l@lists.swau.edu
Subscribe: "subscribe" in message body to powerh-l-request@lists.swau.edu
Unsubscribe: "unsubscribe" in message body to
powerh-l-request@lists.swau.edu
http://lists.swau.edu/mailman/listinfo/powerh-l
This list is closed, thus to post to the list you must be a subscriber.