r that other operations take way too long, or something else?
> Any suggestions on how I can delete those rows without causing a lot
> of downtime?
Do the big operations at a time when your site isn't busy. Like at night.
> sql (stupid filter...)
Yes, but at least they
ase of column names, but not table names. So, you can say:
SELECT name FROM Students;
But not:
SELECT Name FROM students;
If you always use lower case, then you and your co-workers will always know
how to type in names without having to get out a copy of the schema first.
OK, I'l
uggest making your column a varchar(). Then, you
~might~ get the data with a query like this:
SELECT CONCAT(CONCAT(''), link, '') FROM stuff;
---
Rodney Broom
President, R.Broom Consulting
http://www.rbroom.com/
sql
---
e
(col1, col2, col3)
VALUES
(?, ?, ?)
});
$sth->execute(@values);
None of the other silly quoting stuff we're talking about applies to what you are
doing. Just use bind variables and ALL of your problems will go away.
Hollar if you need a hand with this, it can be a bit
on't be defined and you
won't be able to say: $db->errstr(). Instead, your statement could read:
$db = DBI->connect($database,$db_username,$db_password) or
die "Cannot Connect: " . $DBI::errstr;
---
Rodney Broom
President, R.Broom Consulting
http://www.rbroom.com/
mysql site and haven't found something that addresses this.
> Any ideas?
I found this by searching for 'date'. Then, after learing how to use UNIX_TIMESTAMP(),
I searched for 'round' (on a hunch) and found that MySQL has a rounding function that
fixed my number for me
ably get every record in the table. By any chance, is bar.fooID a delimited
list of IDs?
---
Rodney Broom
President, R.Broom Consulting
http://www.rbroom.com/
sql
-
Before posting, please check:
http://www.mysql.co
like
a "real" database. This would mean a little programming, or at least a little
searching on the web. But I'm sure that you could find pre-built, free scripts that
will do most if not all of what you're looking for.
---
Rodn
at CGI languages are available to him?" If none,
and only this built-in search engine, then we need to know these things:
- What format does this search engine accept data in?
- What mechanism(s) are available for importing?
---
Rodney Broom
ogram
- Search engine
Am I any closer?
---
Rodney Broom
President, R.Broom Consulting
http://www.rbroom.com/
sql
-
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/
umber of rows to
return:
mysql> select * from table LIMIT 5; # Retrieve first 5 rows
In other words, LIMIT n is equivalent to LIMIT 0,n.
---
Rodney Broom
President, R.Broom Consulting
http://www.rbroom.com/
sql
-
ocket science. Hollar if you still need
a hand.
---
Rodney Broom
President, R.Broom Consulting
http://www.rbroom.com/
sql
-
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysq
{echo '$query' | $MYSQL $DATABASE > /dev/null});
}
}
# Check end time
# Do some math and make a report.
---
Rodney Broom
President, R.Broom Consulting
http://www.rbroom.com/
sql
-
Before posting, please c
e page at:
http://www.informsarnialambton.org/search.htm
---
Rodney Broom
President, R.Broom Consulting
http://www.rbroom.com/
sql
-
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http
nialambton.org/listing/36.HTM
> I would like to have only one database...
So the question is how to combine your databases?
---
Rodney Broom
President, R.Broom Consulting
http://www.rbroom.com/
sql
-
Before po
list of all the information yourself. Say on your home computer. Then, update the
web pages by hand as needed.
I may be missing what you need, so let me know.
Hey, everybody else. Any input?
---
Rodney Broom
President, R.Broom Consulting
was told that My SQL can doi it, it has a web thingy
> with it.
> Rodney Broom wrote:
> > It sounds to me like you are trying to build a data driven web site on a
> > server with no database available, as aposed to trying to figure out MySQL.
> > Is that right? If so,
Is anybody else getting this mail when they post?
---
Rodney Broom
President, R.Broom Consulting
http://www.rbroom.com/
sql
- Original Message -
From: <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, Novembe
From: Geetika Tewari <[EMAIL PROTECTED]>
> ...perl script fork several processes...
> ...I think my 'select' statements are not happening concurrently.
Why do you think that?
---
Rodney Broom
President, R.Broom Consulting
http:
|
+--+
Unless I'm missing something, this works as it should.
---
Rodney Broom
President, R.Broom Consulting
http://www.rbroom.com/
-
Before posting, please check:
http://www.mysql.com/manual.php (the
e available, as aposed to trying to figure out MySQL. Is that right? If so,
what level of CGI options do you have?
---
Rodney Broom
President, R.Broom Consulting
http://www.rbroom.com/
sql
-
Before posting, please
yes. But isn't that the point? You want to learn to invent wheels and intend to
pratice wheel making to reach that end.
---
Rodney Broom
President, R.Broom Consulting
http://www.rbroom.com/
sql
-
Before posting, p
hat aren't in team 7."
If so, this should work:
SELECT u.uname
FROM users u
LEFT JOIN team_members t ON u.user_id =3D t.user_id
AND t.team_id =3D 7
WHERE t.team_id is NULL
---
Rodney Broom
President, R.Broom Consulti
From: MySQL <[EMAIL PROTECTED]>
> select numer ||','|| text from Table:
SELECT CONCAT(numer, '||', text) FROM Table;
---
Rodney Broom
President, R.Broom Consulting
http://www.rbroom.com/
-
From: Abhi <[EMAIL PROTECTED]>
> Could you pls let me know how to delete duplicate records in a table?=20
DELETE FROM my_table WHERE [predicate] LIMIT 1;
---
Rodney Broom
President, R.Broom Consulting
http://www.rbroom.
SELECT LAST_INSERT_ID();
---
Rodney Broom
President, R.Broom Consulting
http://www.rbroom.com/
-
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list a
verage across a time period when queries are
actually being run. If we let the server sit idle all day, then the average isn't very
useful.
Mike,
Are you looking for benchmark data, or statistics on your setup?
---
Rodney Broom
President, R.Broom Consulting
http://www.rbr
r
If so, I think that sorting in SQL will be a bit clunky. I would advise either storing
your dates as dates, or using an outside program to sort your month names.
Of course, somebody else might know of something simple that I'm missing.
---
Rodney Broom
P
ibly your OS docs to see what the limit
is.
> Would doing just-one-big-table (with a forum-id) be advisable?
Very possibly. 100,000 records isn't huge, but it could be big enough to put a load on
your machine. Unless you find a definative answer in the docs, I'd try testing both.
he responsibility of the operating envoriment and
not of the application. If you are using a UNIX like OS, type 'man cron'. If not UNIX,
hollar and I'm sure that somebody can tell you how to work it out on your system.
---
Rodney Broom
sql
---
here I was told that the JOINs
weren't a problem. I redisigned the schema in the way that I've indicated and got an
improvement of many times (5-12 times faster). In short, we can add up what the docs
say all we like, but nothing beats actuall clinical testing.
---
Rodney Broom
m.
Start with this doc:
http://www.mysql.com/doc/R/e/Request_access.html
---
Rodney Broom
SQL
-
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the lis
From: Ben Ocean <[EMAIL PROTECTED]>
> I can't even run mysqldump --help without getting that error! What am I
> doing wrong?
'mysqldump' is a system command, not an SQL command. You need to run it from the
comman
t others might. You may not need built-in tools like
"clustering" when you see the relative cost. For instance, if you have to pay $50,000
to get an Oracle solution to a problem, or could use MySQL and spend $10,000 on
in-house programming for that solution, which is b
login='$login'
> ...is SOMETIMES blank where is should be "Robyn".
Yep, but I'll be that a query from the MySQL client never says the word NULL.
---
Rodney Broom
-
Before posting, please ch
e existing
cache on disk and work with copy directly? (which sounds like what you were wanting to
do.)
---
Rodney Broom
-
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.co
p.sql
Try this for an example that doesn't change anything:
echo MySQL-Backup-`date +%Y-%m-%d`.tar.gz
---
Rodney Broom
Programmer: Desert.Net
sql
-
Before posting, please check:
http://www.mysql.com/manual.php (
From: Curtis Maurand <[EMAIL PROTECTED]>
> y'all are kidding, right?
http://www.google.com/technology/pigeonrank.html
---
Rodney Broom
Programmer: Desert.Net
sql
-
Before posting, please check:
http:/
From: Lee, Andrew <[EMAIL PROTECTED]>
> If user_id and passwd are fields in your table and the passwd field is
> encrypted :
> SELECT user_id FROM user WHERE passwd = PASSWORD('plaintext_user_pass')
Woops, I was typing too fast Ramiro. Andrew's query is right
From: Kenneth Hylton <[EMAIL PROTECTED]>
> Basically, if you encrypt the password, then you have to look it up using
> the password function, too.
What he means is this:
SELECT user_id FROM user WHERE PASSWORD(user_pass) = PASSWORD('my_var')
---
Rodney Broom
Progr
for my $row ( @{$list_list} ) {
$dbh->do(qq{DELETE FROM messages WHERE topicid = $row->[0]});
}
Note, my example is rough, and not tuned for performance. But you get the idea. Hollar
if you still need a hand with
From: Walter D. Funk <[EMAIL PROTECTED]>
> ...I'd like to sort them so as the result set becomes like this
What language, if any, are you working in, other than SQL?
---
Rodney Broom
Programmer: Desert.Net
-
d properly. For instance, your MS Windows might
want the shebang at the top to look a certain way, maybe like this:
#! perl
---
Rodney Broom
Programmer: Desert.Net
sql
-
Before posting, please check:
http://
y;
select substring(now(), 6,5) as mon_day,
substring(now(), 6,2) as mon,
substring(now(), 9,2) as day;
---
Rodney Broom
Programmer: Desert.Net
sql
-
Before posting, please check:
http://ww
From: adam nelson <[EMAIL PROTECTED]>
> It's been a while since I've done this, does anybody remember:
> I'd like a query that looks for lawyers...
Have you thought about using an unsigned int and doing bitwise math?
---
Rodney Broom
are using a MicroSoft OS instead of some flavor
of UNIX. I'm afraid that I just don't know how much of your performance will get eaten
up by NT itself.
---
Rodney Broom
Programmer: Desert.Net
Spam filter: sql database
--
n the middle of
the night when nobody is using the database?
> Is there a way to use MySQLDump without overloading?
% nice -n 20 mysqldump ...
---
Rodney Broom
Programmer: Desert.Net
-
Before posting, please
pport it. (Hey folks, does anything else support joined deletes?)
By the way, since poll_votes has a PK of aim_screenname/answer_id, folks can give each
answer for a given poll once. As apposed to just one answer per poll.
---
Rodney Broom
Programm
doesn't work. Although you can drop and rebuild the column something like this
(assuming that 'id' is the primary key):
ALTER TABLE jack drop id;
ALTER TABLE jack
AUTO_INCREMENT=1,
ADD id int unsigned not null auto_increment default '0',
ADD primary key
n the docs about accessing after
you've lost a password, but I don't recall where. Maybe you have another user with
write permission to that table who can update "root"s permissions.
---
Rodney Broom
Programmer: Desert.Net
---
From: Mat Murdock <[EMAIL PROTECTED]>
> ... Like "*java*"
Try:
Like "%java%"
I would bet the the aseriscs are some non-SQL extention of MS Access.
---
Rodney Broom
Programmer: Desert.Net
-
code
You'll find this someplace in:
http://www.mysql.com/documentation/mysql/bychapter/manual_Reference.html
But it's a rather thick document.
---
Rodney Broom
Programmer: Desert.Net
-
Before posting, please
are.
Yep, you're right, but I'm not after middle-ware. I'm after a hook into the RDBMS
itself.
---
Rodney Broom
Programmer: Desert.Net
-
Before posting, please check:
http://www.mysql.com/manual.php (th
dures
---
Rodney Broom
Programmer: Desert.Net
Spam filter: sql database
-
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)
To request this t
itional bandwidth charge if the machine that MySQL is currently on is
the only one that needed to connect to it.
---
Rodney Broom
Programmer: Desert.Net
-
Before posting, please check:
http://www.mysql.com/manual.ph
't worked with Samba, so I don't know
how passwords are managed there, but I'm sure that you could at least write a wrapper
around the call to the Samba password tool to get this done.
Make sense? If not, let us know. I'll help if you need.
---
Rodney Bro
mysqldump --opt -d database_one > copy.sql
To reload into "database_two":
% mysql [options] database_two < copy.sql
# Or
% cat copy.sql | mysql [options] database_two
If you need to create a database:
% mysqladmin create database_two
---
R
N syntax. Try this:
SELECT years.year AS yearlist, count(years.year) AS gamecount
FROM years, games
WHERE years.year = games.release_year
GROUP BY years.year
ORDER BY gamecount DESC, yearlist
---
Rodney Broom
Programmer: Desert.Net
Spam fi
hes against. But the whole searching thing
can become a pretty big subject.
---
Rodney Broom
Programmer: Desert.Net
Spam filter: sql database
-
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
h
se information that we'll need.
- What are the exact field names you are importing from?
- What are the exact field names that get created?
- What program/method are you using to create the DB3 file?
Other folks probably already know, but I'm confused on this part.
---
Rodney Broom
of DB design or MySQL help. I notice that you're schema has
about 15 indexes, I presume that this is to allow for a variaty of fast searching
formats from some program, yes? If so, there may be a way to rethink the interface to
this data. How are you using this data?
---
R
ess to those databases to whomever it sees fit. The question of who is seen
as fit is determined by the GRANT statements used earlier.
The client simply connects to a MySQL server someplace. That server might be local, or
it might be on the other side of the planet.
---
Rodney Broom
Programmer
I can't sleep, I just look for some sound advice. If that doesn't
work, then I like to try some warm milk and a couple of my wife's chocolate chip
cookies.
---
Rodney Broom
Programmer: Desert.Net
Spam Filter: sql database
HERE table1.email is NULL;
---
Rodney Broom
Programmer: Desert.Net
Spam filter: sql database
-
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list arc
w as your current queries. But you'll pay a price once
and not have to pay it again and again.
Let me know if you choose the Perl route and need a hand.
---
Rodney Broom
Programmer: Desert.Net
-
Before posting, please
eed to reload the access privileges. It can be done at the command line
like this:
% mysqladmin -u rootUserName reload
Remember, you may need to add the -p switch and suply a password for this command.
Is this enough info?
---
Rodney Broom
Programmer: Desert.Net
Spam filter: sql databa
ently? Another option might be to pipe the output through a filter. I should
think that a little Perl or sed would be nice.
---
Rodney Broom
Programmer: Desert.Net
Spam filter: sql database
-
Before posting, please
to know everything, you just have to know how to find it fast enough to make your
boss happy.
> Any help with any of those questions is much appreciated.
I'm very encouraged to see a newcomer here. I hope that you get plenty of assistance
from this group. Hint, hint.
---
Rodney
text you've typed to create a
query, or is the query itself actually running slowly?
---
Rodney Broom
Programmer: Desert.Net
Spam filter: sql database
-
Before posting, please check:
http://www.mysql.com/manual.php
From: Jonathan Hilgeman <[EMAIL PROTECTED]>
> On a related note, any Perl gurus know how to force a Perl cron job to stay
> below a certain CPU utilization?
Not a Perl thing. Do a man on 'nice'.
---
Rodney Broom
Programmer: Desert.Net
Spa
ing problem since. I don't
know what the actual cause of the problem was, which worries me. But, for the time
being, the system works.
---
Rodney Broom
Programmer: Desert.Net
-
Before posting, please check:
http://www.my
ysqld
Just to be clear, if the permissions somehow already include 'write' for group or
other, then this chmod won't remove that. I'd suggest this:
% chmod 500 /etc/rc.d/init.d/mysqld
% ls -l /etc/rc.d/init.d/mysqld
-r-x-- 2 root root 4040 May 29 11:20 /etc/
In your examples, ID 2 should NOT get returned. What I'm after is analogous to a Perl
hash where you could say:
if (!exists $colors{2}->{blue}) {
...
}
Make sence?
---
Rodney Broom
Programmer: Desert.Net
Spam filter: sql
From: Sparta Cruz <[EMAIL PROTECTED]>
> > Do you think this was due to software constraints(MySQL), or do you
> > think it had to do with hardware constraints?
I'm sure it was software. Possibly the MyISAM tables I'm using.
> -Original Message-
>
ing about post-processing the data programatically,
but that's a difficult solution for a variety of reasons.
---
Rodney Broom
Programmer: Desert.Net
Spam Filter: SQL
-
Before posting, please check:
http://www.mysql.
From: rc <[EMAIL PROTECTED]>
> is data a reseverd word in mysql?
No.
> On Wed, 31 Oct 2001, Richard W. Wood wrote:
> > I've been trying to add the following table to my database, and I keep
> > getting the error below.
I copy-pasted your SQL and it worked. I
can't
continue. I appoligize. Please, let me know if you bump into a tarred source of this
package.
---
Rodney Broom
Programmer: Desert.Net
-
Before posting, please check:
http://www.mysql.com/manual.php (the
a look at it and see if I can answer your question.
---
Rodney Broom
Programmer: Desert.Net
-
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archiv
From: <[EMAIL PROTECTED]>
> MySQL said: You have an error in your SQL syntax near 'order by
> 'Variable_name' ASC' at line 1
>
> Any ideas as to what this means, and how to fix it?
Hi Dave,
How 'bout sending us the entire SQL statement, pleas
From: Doug Poland <[EMAIL PROTECTED]>
> Have you thought about a web based app? I've successfull steered
> customers from an Access/MDB or VB/MDB applications to HTML based
> apps talking to *nix/apache/php/mysql.
Here, here. I think this is the way to go if you ca
QL. My guess from there (since I don't program
outside of *NIX) would be something like C++ (MS or Borland are two big names that
come to mind), or even MS Visual Basic.
You remember what "BASIC" stands for, right? "Beginner&quo
y myself a copy. Then I heard that it runs about 3K and opted not
to.
---
Rodney Broom
Programmer: Desert.Net
Spam filter: sql
-
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.m
/init.d/mysql.server \
> > /etc/rc.d/rc3.d/S99mysql
> What is the importance of this command?
It links one file to another. Try this:
% man ln
---
Rodney Broom
Programmer: Desert.Net
-
Before posting, please ch
I've got this:
% cp /usr/local/mysql/support-files/mysql.server \
/etc/rc.d/init.d/mysql.server
% chmod 544 /etc/rc.d/init.d/mysql.server
% ln -s /etc/rc.d/init.d/mysql.server \
/etc/rc.d/rc3.d/S99mysql
---
Rod
);
But I wouldn't be willing to have this in the engine if it meant a performance hit
during the times when I wasn't this functionality.
---
Rodney Broom
Programmer: Desert.Net
-
Before posting, please check:
kens::Oracle::tokenize($oracle_schema);
$mysql_sql = SQL::Tokens::MySQL::generate($tokenized);
There would be some obvious problems with things like unsupported data types from one
DB to another, not to mention things like FKs, views, etc.
---
Rodney Broom
ably isn't what you want. You probably want something inside of your
mysql instalation directory.
---
Rodney Broom
Programmer: Desert.Net
-
Before posting, please check:
http://www.mysql.com/manual.php (the manu
EMAIL PROTECTED]
As for why I wrote that...
Alexander Skwar writes:
> Could this user please be removed? It's [EMAIL PROTECTED]
---
Rodney Broom
Programmer: Desert.Net
sql
-
Before posting, please check:
Hi guys,
From: Carl Troein <[EMAIL PROTECTED]>
> Sadly, the admin of this list doesn't give a shit. This
> is rather obvious from
Sorry about that. Here's the answer:
[EMAIL PROTECTED]
---
Rodney Broom
Prog
LECTs per day, then I'd say that you have a problem, but if you're doing 500,000,000
INSERTs and 1 Bil. SELECTs, then I could see some call for your systems to slow down.
---
Rodney Broom
Programmer: Desert.Net
-
ed, hollar back with the errors. I expect that this will be much
easier, and far less prone to problems.
---
Rodney Broom
Programmer: Desert.Net
SpamKey: sql
-
Before posting, please check:
http://www.mysql.com/manu
Nick Torenvliet wrote:
> ...I've run ./configure
Did you run 'make'?
---
Rodney Broom
Programmer: Desert.Net
Keywords: sql, spam-off
-
Before posting, please check:
http://www.mysql.com/manual.php (t
e?
> ...but in 5 tables...
So you've split your data into sets that need to get loaded into five destination
tables, or you upload five sets of data?
> (verifying duplication, ids, etc):
Does this mean that you are checking for duplicates before loading into MySQL?
d find out
what works best for you.
---
Rodney Broom
Programmer: Desert.Net
Spam filter: sql
-
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)
To
Riza-frasin...
---
Rodney Broom
Programmer: Desert.Net
> Your message cannot be posted because it appears to be either spam...
> database,sql,query,table
> From: Anthony E. <[EMAIL PROTECTED]>
>
> > Unknow column 'USER' in 'where clause'.
&
From: Anthony E. <[EMAIL PROTECTED]>
> This comes up with more records than are in USER_TMP.
Is the 'email' column unique in both tables?
Heh, sorry about that. Try this:
select count(USER_TMP.email)
from USER_TMP, USER
where USER_TMP.email = USER.email
and
ound it to be with concernes.
If you write Perl, I would suggest using that. Here's part of why:
http:[EMAIL PROTECTED]/msg01457.html
http:[EMAIL PROTECTED]/msg01461.html
---
Rodney Broom
Programmer: Desert.Net
-
From: Lance Rochelle <[EMAIL PROTECTED]>
> SQL question which I am new to.
> How would I count the number of times a specific entry is in field. For
> instance I have a table that has the following two fields
select count(*) as number, hostname
from your_table
group by hostna
do some type of searching, say on the product ID, you could do this:
SELECT po.*, prod.*
FROM purchase_order po, po_item prod
WHERE po.id = prod.po_id
AND product_id = 8
Does this help?
---
Rodney Broom
Programmer: Desert.Net
---
bject($myresult);
> print "$row->mid is result";
I don't do any PHP, but I'm guessing that your return column name is something like
'max(mid)'. Try this:
$myquery = "SELECT max(mid) as max_mid FROM mboard";
$myresult = mysql_query($myquery);
$row =
1 - 100 of 106 matches
Mail list logo