[Date Prev][Date Next][Thread Prev][Thread Next][Minivend by date
][Minivend by thread
]
Re: SQL interface - am I doing this right?
****** message to minivend-users from Dan Busarow <dan@dpcsys.com> ******
On Mon, 21 Dec 1998, Chris Powell wrote:
> I've just transitioned from the ASCII products database to an SQL
> products db using Solid. While tricky, I have managed to meet success.
> (One caveat is that [item-field ...] things need to be in caps, e.g.
> [item-field CATEGORY].
If the column names are upper case in the DB, yes.
> I noticed a big performance hit by taking the SQL route, however --
> things take seconds to return when they used to be pretty snappy. I'm
> presuming this is due to the overhead of the DBI/DBD interface, but I
> want to make sure it's not me...
Are you talking about a text search (wildcard LIKE) or a match?
SQL is pretty poor at text searches and you can use a mix of gdbm
and SQL for these. It's in the docs but basically you want to
periodically create a new products.asc from the database. MV will
see the new products.asc and rebuild the gdbm for you.
If you are seeing these poor results on regular matches (select *
from products where code = 'xyz') then you need to look at your DB.
Make code (and any other fields you search on) an index. Multi-
second searches are not normal, especially on such a small table.
> (BTW, the Solid db is only 400 records long, and the machine is a PPro
> 200 with lots of RAM and very little else going on... so it's not the
> machine, IMHO.)
Even without indexes this should return the results too quick to
measure. What's Solid's performance like just running straight
perl, DBI::DBD code?
Dan
--
Dan Busarow 949 443 4172
Dana Point Communications, Inc. dan@dpcsys.com
Dana Point, California 83 09 EF 59 E0 11 89 B4 8D 09 DB FD E1 DD 0C 82
-
To unsubscribe from the list, DO NOT REPLY to this message. Instead, send
email with 'UNSUBSCRIBE minivend-users' in the body to Majordomo@minivend.com.
Archive of past messages: http://www.minivend.com/minivend/minivend-list