Quick and Omnidex on entry.
georgia miller
georgia_miller@gfps.k12.mt.us
11 Mar 1999 10:45:38 -0700
Paul, I didn't do the code for what you are doing exactly the first time. Sorry, I didn't see the rest of the email. I changed the code to your specific files and put it in the Entry Procedure. I have never used this Omindex lookup code outside of the Find Procedure, so I'm not sure if it will work or not. You can try the following code.
____________________________________________________________________
>To: Paul Kemner; PowerHouse Listserv (new)
>From: georgia miller on Thu, Mar 11, 1999 9:59 AM
>Subject: RE: Quick and Omnidex on entry.
>Paul,
>Here is how to get Omnidex to work with Quick. This is on an HP3000 with
>MPEix PH 7.29.C3.
>
>First you need these Temporaries:
>;Omnidex Search Tempoaries
> TEMP SEARCH-KEY CHAR*80
> TEMP CRITERIA CHAR*80
> TEMP QUALIFY-COUNT INT SIZE 4
> TEMP MESSAGE CHAR*80
> TEMP CONTROL-CMD CHAR*80
> TEMP BUFFER CHAR*80
> TEMP BASE-ID CHAR*5 RESET AT STARTUP
> TEMP BASE-IDL CHAR*5 RESET AT STARTUP
>
> The file must be accessed sequential - doesn't need to be a designer file:
> FILE CUSTOMERS REFERENCE
> ACCESS SEQUENTIAL
>
>Add this to the Entry Procedure
>
>Procedure Entry
> Begin
> Accept ord-key of orders
> Accept t-cust-no of orders
> LET SEARCH-KEY = &
> "databasename/database_read_password.CUSTOMERS.CUST-NO(SORTED, BASE"+
> BASE-ID+");"
> LET CRITERIA = TRUNC(T-CUST-NO) + ";"
> DO EXTERNAL OMNIFIND(SEARCH-KEY,CRITERIA,QUALIFY-COUNT,MESSAGE)
> IF MESSAGE <> ""
> THEN ERROR = MESSAGE
;I'm not sure you need this get, but I think you'll need it in the Entry Procedure
GET CUSTOMERS SEQUENTIAL
> Display cust-name of customers
> END
>
> PROCEDURE INITIAL
> BEGIN
> GET CUSTOMERS SEQUENTIAL
> LET CONTROL-CMD = "BASEID($LASTGET);"
> DO EXTERNAL OMNIFINDCONTROL(CONTROL-CMD,BUFFER,MESSAGE)
> IF MESSAGE <> ""
> THEN ERROR = MESSAGE
> ELSE LET BASE-ID = LJ(TRUNC(BUFFER))
> END
>
>Hope this helps!
>
>Georgia Miller, Systems Analyst
>Great Falls Public Schools
>Email: georgia_miller@gfps.k12.mt.us
>____________________________________________________________________
>
>>To: powerh-l@lists.swau.edu
>>From: Paul Kemner on Tue, Mar 9, 1999 9:29 AM
>>Subject: Quick and Omnidex on entry.
>
>>
>>I'm having a problem with an Omnidex retrieval in Quick. We don't have a
>>set of manuals since Omnidex was purchased with a 3rd party package.
>>
>>In the demo files, all the examples use a POSTPATH procedure, with code
>>similar to this:
>>
>>REQUEST CUSTOMER-NAME
>>LET CRITERIA=TRUNC(CUSTOMER-NAME)+":"
>>LET SEARCH-KEY = "CUSSTOMERS.CUSTOMER-NAME;"
>>DO EXTERNAL OMNIFIND(SEARCH-KEY,CRITERIA,QUALIFY-COUNT,MESSAGE)
>>Etc etc.
>>The omnifind procedure doesn't return a value as such, and I assume that
>>the info gets put on a stack somewhere.
>>
>>I need to do the retrieval in an ENTRY procedure, and get a key value
>>returned. Any ideas / sections of code that do this in Quick?
>>
>>Here are the records: ****************************************
>>
>>Record ORDERS (image master)
>>Item ord-key (the image key)
>>Item cust-id
>>Etc.
>>
>>Record CUSTOMERS (image master)
>>Item cust-id (the image key)
>>Item cust-no (an OMNIDEX repeating key)
>>Item cust-name
>>Etc.
>>
>>And this is the screen: ******************************************
>>
>>Screen Test
>>
>>File ORDERS
>>File CUSTOMERS designer
>>
>>Temp t-cust-no
>>
>>Field ord-key of ORDERS
>>Field t-cust-no
>>Field cust-name of customers display
>>
>>Procedure Entry
>> Begin
>> Accept ord-key
>> Accept t-cust-no
>>; If cust-no was a regular image key, I could do the following, but
>>;as things are I get "No key/index is defined which matches these items"
>>from QDESIGN.
>> Get CUSTOMERS via cust-no using t-cust-no
>> Let cust-id of ORDERS = cust-id of CUSTOMERS
>> Display cust-name of customers
>> Etc. etc.
>> End
>>
>>It is my guess that I need to call some external procedure that would do
>>the "Get CUSTOMERS" task.
>>Do you have any code example for this?
>>
>>= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
>>Subscribe: "subscribe powerh-l" in message body to majordomo@lists.swau.edu
>>Unsubscribe: "unsubscribe powerh-l" in message to majordomo@lists.swau.edu
>>powerh-l@lists.swau.edu is gatewayed one-way to bit.listserv.powerh-l
>>This list is closed, thus to post to the list, you must be a subscriber.
>
>= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
>Subscribe: "subscribe powerh-l" in message body to majordomo@lists.swau.edu
>Unsubscribe: "unsubscribe powerh-l" in message to majordomo@lists.swau.edu
>powerh-l@lists.swau.edu is gatewayed one-way to bit.listserv.powerh-l
>This list is closed, thus to post to the list, you must be a subscriber.
= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
Subscribe: "subscribe powerh-l" in message body to majordomo@lists.swau.edu
Unsubscribe: "unsubscribe powerh-l" in message to majordomo@lists.swau.edu
powerh-l@lists.swau.edu is gatewayed one-way to bit.listserv.powerh-l
This list is closed, thus to post to the list, you must be a subscriber.