I have a shopping cart that errors out when try to do a search
select p.products_ship _price, p.products_id, p.products_mode l,
pd.products_nam e, p.products_quan tity, p.products_imag e, p.products_pric e,
p.products_date _added, p.products_last _modified, p.products_date _available,
p.products_stat us, p2c.categories_ id from products p, products_descri ption
pd, products_to_cat egories p2c where p.products_id = pd.products_id and
pd.language_id = '1' and p.products_id = p2c.products_id and
pd.products_nam e like '%3219%' or p.products_mode l like '%3219%' order by
pd.products_nam e
If I remove either
or p.products_mode l like '%3219%'
OR
pd.products_nam e like '%3219%'
The query will run fine 30 Results for Model and 3 products for Name. While
it is running it will load the Temp directory. I moved the DB to one of my
64bit boxes with 8GB Ram and a 200GB drive mysql 4.1.12 Max and it just
runs longer before it throws the error. The Database has 11000 products in
it but we have the same issue with a database with 5K products.
Can this query be the problem. It is from OSC Max
--
Eric Haskins
Lead Software Developer
Merchant 2020
(954) 272-4961 ext. 206
(727) 239-3823 Cell er**@merchant20 20.com 5 9777
>I have a shopping cart that errors out when try to do a search select p.products_ship _price, p.products_id, p.products_mode l, pd.products_na me, p.products_quan tity, p.products_imag e, p.products_pric e, p.products_dat e_added, p.products_last _modified, p.products_date _available, p.products_sta tus, p2c.categories_ id from products p, products_descri ption pd, products_to_cat egories p2c where p.products_id = pd.products_id and pd.language_ id = '1' and p.products_id = p2c.products_id and pd.products_na me like '%3219%' or p.products_mode l like '%3219%' order by pd.products_na me
If I remove either
or p.products_mode l like '%3219%'
OR
pd.products_na me like '%3219%'
The query will run fine 30 Results for Model and 3 products for Name. While it is running it will load the Temp directory. I moved the DB to one of my 64bit boxes with 8GB Ram and a 200GB drive mysql 4.1.12 Max and it just runs longer before it throws the error. The Database has 11000 products in it but we have the same issue with a database with 5K products.
error 28 on my box (FreeBSD) is "no space left on device".
Which partition is running out of disk space?
Gordon L. Burditt
> error 28 on my box (FreeBSD) is "no space left on device". Which partition is running out of disk space?
Gordon L. Burditt
/ partition
Thats why it takes longer for error to develop on the 64 bit box 150Gb
free. The other bo has only 50GB free so it errors out sooner. You can
watch a file in the /tmp directory grow while the search is running
Eric
"Gordon Burditt" <go***********@ burditt.org> wrote in message
news:11******** *****@corp.supe rnews.com... I have a shopping cart that errors out when try to do a search
select p.products_ship _price, p.products_id, p.products_mode l, pd.products_n ame, p.products_quan tity, p.products_imag e, p.products_pric e, p.products_da te_added, p.products_last _modified, p.products_da te_available, p.products_st atus, p2c.categories_ id from products p, products_descri ption pd, products_to_cat egories p2c where p.products_id = pd.products_id and pd.language_i d = '1' and p.products_id = p2c.products_id and pd.products_n ame like '%3219%' or p.products_mode l like '%3219%' order by pd.products_n ame
If I remove either
or p.products_mode l like '%3219%'
OR
pd.products_n ame like '%3219%'
The query will run fine 30 Results for Model and 3 products for Name. While it is running it will load the Temp directory. I moved the DB to one of my 64bit boxes with 8GB Ram and a 200GB drive mysql 4.1.12 Max and it just runs longer before it throws the error. The Database has 11000 products in it but we have the same issue with a database with 5K products.
On 04/08/2005, me wrote: I have a shopping cart that errors out when try to do a search ... and pd.products_nam e like '%3219%' or p.products_mode l like '%3219%' order by pd.products_nam e
Are you sure you don't want
and (pd.products_na me like '%3219%' or p.products_mode l like '%3219%')
here?
--
felix
Felix Geerinckx schrieb: On 04/08/2005, me wrote:
I have a shopping cart that errors out when try to do a search ... and pd.products_nam e like '%3219%' or p.products_mode l like '%3219%' order by pd.products_nam e
Are you sure you don't want
and (pd.products_na me like '%3219%' or p.products_mode l like '%3219%')
here?
-- felix
Hi,
I don't know if I'm right but could it be that you produce a Cartesian
Product with your query?
Maybe it might help to use a real (INNER) JOIN like
SELECT p.products_ship _price, p.products_id, ..., p2c.categories_ id
FROM products p INNER JOIN products_descri ption pd ON p.products_id =
pd.products_id
INNER JOIN products_to_cat egories p2c ON p.products_id =
p2c.products_id
WHERE pd.language_id = '1' AND pd.products_nam e like '%3219%' OR
p.products_mode l like '%3219%'
ORDER BY pd.products_nam e
Please note that I am NOT SURE which conditions are the most important
ones and whether or not you will have to use brackets ("(..)") in order
to group the WHERE... AND.. OR.. parts in order to get the desired
result.
As well I'm NOT SURE if I got all JOINS correct! Please double check
before you use it!
Anyway, I'm pretty sure that you have to use the JOIN keyword in order
to make your query faster.
HTH,
Andy As well I'm NOT SURE if I got all JOINS correct! Please double check before you use it!
Anyway, I'm pretty sure that you have to use the JOIN keyword in order to make your query faster.
HTH,
Andy
Andy Thx a few tweaks and it did the trick!!!!
Eric This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Brian Oster |
last post by:
After applying security patch MS03-031 (Sql server ver 8.00.818) a
query that used to execute in under 2 seconds, now takes over 8
Minutes to complete. Any ideas on what the heck might be going on?
I have tested this extensively and can say for certain that installing
this hot fix is what has caused the performance problem. I just don't
know why or how to fix it.
Brian Oster
|
by: AG |
last post by:
I am able to run a query which runs FAst in QA but slow in the
application.It takes about 16 m in QA but 1000 ms on the
Application.What I wanted to know is why would the query take a long
time in the application when it runs fast on SQL server?
How should we try debugging it?
Ajay
|
by: starman7 |
last post by:
I have a query that seems to kill the db for our website (causes the
'Too many connections' error).
I would like to avoid this! Is there a way to test the query before the
db goes down? I do not have access to a staging environment. I can
access the db via Linux command line, or phpMyAdmin - however I can
only select, update, and delete.
I've heard a user can identify a bad query and kill it, how is this
done? Would my user have...
|
by: Steve |
last post by:
Form FrmRestock's recordsource is QryFrmRestock. The TransactionDate field's
criteria is set ats:
Forms!FrmRestock!LastXDays. LastXDays on the form is a combobox where the
selections are 30, 60 and 90. The default is set at 30.
Question1: When the form opens, there are no records displayed although there
are many records that fit the criteria of 30. If I put a button on the form to
do a requery and press the button, all the records...
|
by: Adam Louis |
last post by:
I would like help resolving this problem. I'm a novice who's been
hired to query a hospital database and extract useful information,
available to me only in a dynamically generated, downloadable .mdb.
The query below query runs correctly and without error, but any
attempt to save it causes Access to crash without a message, leaving
the .ldb file. Opening the DB reveals it saved a blank "query1".
I've upgraded to Jet SP 8, and I'm running...
| |
by: Greg Strong |
last post by:
Hello All,
Is the only solution to an update query which requires the records in a
certain order to dump the records into a temp table in the required
order, then do the update query?
I've tried nesting a select query with the proper sort order inside the
update query, but the update query still appears to complete in the
order of the records in the table. I thought that I'd keep it a simple
question without getting into the detail of...
|
by: mezise |
last post by:
Posted by Pratchaya:
------------------------------------------------------
MySQL Slow Log ERROR
In my.cnf
i add these lines
#######
log-bin
log-slow-queries = /var/log/mysqld-slow.log
|
by: Ty |
last post by:
If anyone replies who saw my other posts, now you know why my posts
look as if I'm using MS Access.
I'm trying to google information about MS Access and why MS Access
causes database locks within DB2. The Developers at my current job
discourage MS Access queries on the DB2 database. Here is what I
found so far:
Microsoft Access, however, is different. Access has its own object
|
by: wsullenger |
last post by:
Doing a manual refresh on a target_type = "user copy". The source is a
view. When APPLY runs it returns
WPLAN: Set is skipped. errcode is 5E1603.
The Physical CD table has rows in it that are waiting to be replicated
(via the view) to the target table.
Help?
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
| |
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |