[comp.sys.amiga.multimedia] AmigaVision Problems...Help I'm Stuck!

sl3b4@cc.usu.edu (03/28/91)

Hi all.  I am putting together an AmigaVision project for my workplace. 
Hopefully if all goes well, they will be impressed and buy some Amigas. ;-)
But...I have came across two problems, I hope someone out there can lend me
hand in figuring them out!

1.  I want to search a database "Key".  It is a string that is 30 chars.  The
    problem I have is that when using the "Select Record" icon, it will only
    match those records where the search string matches the first part of the
    "key".  What I want it to do is to select all of the records that contain 
    the search string anywhere in that "key". Example:  Search string is
    "BALL". The record with "BALL BEARINGS" would be selected but not, "RUBBER
    MOUSE BALLS".  Can I do this?  If so how?

2.  This database is a Logo database for a large business forms producer.  The
    logos are referenced by a number.  That number also designates an IFF brush
    with an image of the logo so that you can search the database and find the
    logo you need.  BUT...how can I get the brush on the screen?  There is no
    way that I can see that I can pass a variable with the path/filename of the
    brush to be displayed to any of the AV type icons.  All of these icons
    require a set path/filename.  Help...This is VERY important to the success 
    of my getting them to get an Amiga.  They already have a pc with a similar 
    database (ugly and not user friendly), and I was thinking this would be a
    snap to do with AmigaVision.  So far, but this one got me.  HELP!

Any help would be appreciated, thoughts, ideas, etc.  Thanks alot in advance!

John Z.
SL3B4@cc.usu.edu

cathy@cbmvax.commodore.com (Catherine Godfrey - CATS) (04/02/91)

In article <1991Mar28.011658.47180@cc.usu.edu> sl3b4@cc.usu.edu writes:

>    "key".  What I want it to do is to select all of the records that contain 
>    the search string anywhere in that "key". Example:  Search string is
>    "BALL". The record with "BALL BEARINGS" would be selected but not, "RUBBER
>    MOUSE BALLS".  Can I do this?  If so how?

AmigaVision will only try to match the beginning of a key with your variable.  
You might want to consider the following options:

1) Add duplicate records...each with a different key field.  For instance, 
you could have a "Rubber Mouse Balls" record and then add two similar records, 
"Mouse Rubber Balls" and "Balls Rubber Mouse".  This way you could match this 
record if you were searching for "Ball", "Mouse" or "Rubber".  The obvious 
problem with this work-around is that it could make your database HUGE!

2) Create three (or four) new fields in your database and make them all key 
fields.  Each field would have a single key word.  
(The "Ball Bearings" record would contain:  Key Field 1 = Ball,  
                                            Key Field 2 = Bearings, and
                                            Key Field 3 = "".
The "Rubber Mouse Balls" record :           Key Field 1 = Rubber,
                                            Key Field 2 = Mouse, and 
                                            Key Field 3 = Balls.)
Whenever you do a search, actually do three searches.  Set up three SELECT
Icons with the first one trying to match your variable to Key Field 1, the
second trying to match the variable with Key Field 2 and so on.  Of course,
you want a simple check to make sure the previous SEARCH Icon didn't find
a match before you continue with the search.
   
Keep in mind, the problem with this work-around is that it could slow your 
search time.

>    logo you need.  BUT...how can I get the brush on the screen?  There is no
>    way that I can see that I can pass a variable with the path/filename of the
>    brush to be displayed to any of the AV type icons.  All of these icons

You can place a variable in the Filename field of a BRUSH Icon.  Just make sure
the variable is within square brackets, [].  

For example, your picture is in "Work:Apps/ILBM1/dog.pic" and
             your variable PICTURE = "ILBM1/dog", then 
             the Filename field would contain "Work:Apps/[PICTURE].pic".

In AmigaVision 1.53G you can use variables as filenames in Brush objects of 
the Object Editor, too.

>John Z.
>SL3B4@cc.usu.edu

Cathy

-- 
              ============================================
              Cathy Godfrey   {rutgers,uunet}!cbmvax!cathy
              Authoring System Support Specialist        
              Commodore Applications and Technical Support 
              ============================================

manes@vger.nsu.edu ((Mark D. Manes), Norfolk State University) (04/03/91)

In article <1991Mar28.011658.47180@cc.usu.edu>, sl3b4@cc.usu.edu writes:
> Hi all.  I am putting together an AmigaVision project for my workplace. 
> Hopefully if all goes well, they will be impressed and buy some Amigas. ;-)
> But...I have came across two problems, I hope someone out there can lend me
> hand in figuring them out!
> 
> 1.  I want to search a database "Key".  It is a string that is 30 chars.  The
>     problem I have is that when using the "Select Record" icon, it will only
>     match those records where the search string matches the first part of the
>     "key".  What I want it to do is to select all of the records that contain 
>     the search string anywhere in that "key". Example:  Search string is
>     "BALL". The record with "BALL BEARINGS" would be selected but not, "RUBBER
>     MOUSE BALLS".  Can I do this?  If so how?

This may not be the 'fastest' solution, but it will work.

- Use the select database icon, and allow it to select all of the records.
- Then use the read data icon and bring in your key variable into a variable
  that you will examine
- Use the findstr() function to locate your sub-string.

> 
> 2.  This database is a Logo database for a large business forms producer.  The
>     logos are referenced by a number.  That number also designates an IFF brush
>     with an image of the logo so that you can search the database and find the
>     logo you need.  BUT...how can I get the brush on the screen?  There is no
>     way that I can see that I can pass a variable with the path/filename of the
>     brush to be displayed to any of the AV type icons.  All of these icons
>     require a set path/filename.  Help...This is VERY important to the success 
>     of my getting them to get an Amiga.  They already have a pc with a similar 
>     database (ugly and not user friendly), and I was thinking this would be a
>     snap to do with AmigaVision.  So far, but this one got me.  HELP!

You can use a variable in any of the display or audio icons by place the
variable name inside of brackets.   The only problem is that if the file
is not found, you will not be able to trap the error nicely.  AmigaVision
will simply put up its "I give up" requestor.

> 
> Any help would be appreciated, thoughts, ideas, etc.  Thanks alot in advance!
> 
> John Z.
> SL3B4@cc.usu.edu

 -mark=
     
 +--------+   ==================================================          
 | \/     |   Mark D. Manes   "Mr. AmigaVision,  The 32 bit guy"
 | /\  \/ |   manes@vger.nsu.edu                                        
 |     /  |   (804) 683-2532    "Make up your own mind! - AMIGA"
 +--------+   ==================================================