Hi James,
Well if you used [VAR]CHAR/TEXT and then did the INSERT query *with* the
leading 0s, it should work. If the 0s aren't there in PHP, they won't be
stored in the CHAR column though.
But anyway, it's more efficient to stick with SMALLINT... and use the
ZEROFILL attribute on the column. :-)
Hi,
This is bugging me
Using PHP/MySQL.
I have three input fields to hold a user's phone number. The MySQL fields
are set to SMALLINT. If any of the strings to update the DB starts with a 0
(zero), the first number is truncated (0206 becomes 206). Any other
combination where the first digit
Hi,
myphp looks like it's pretty slow going by the times reported in the
examples. :-/ Probably something to do with all that PHP junk loaded
into MySQL. :-)
And no, I don't think you can do any stored procs with it; only apply
PHP functions etc. to database values.
Matt
- Original Messag
These 2 are the queries
explain select * from user where user_id = 123;
-> where user_id is the primary key of user table with 2178576 rows.
explain select * from user_att where user_id = 123 and att_id = 123;
-> where user_id and att_id is the primary key of user_att table with
18513726 rows
I'm running 1Gb on my normal desktop with XP pro...it's sufficient, but
just, if you've got swap disabled. Still gets bogged down sometimes,
almost like it's trying to swap and getting frustrated because it's not
allowed to. I'd be happier with 1.5 or even 2Gb of nice hot
DDR333...these days, ram
First, Thanks for all replies, I'll be going with XP Pro on a P4 machine. The next
question is RAM, I know more is better, but the access database file I'm using now is
120Megs and will stay about the same size. Do I need more than 1G, can I get by with
512M Ram? I will of course turn virtual
Hi,
- Original Message -
From: "Jeremy Zawodny"
Cc: <[EMAIL PROTECTED]>
Sent: Friday, September 19, 2003 5:12 PM
Subject: Re: explain
> On Fri, Sep 19, 2003 at 02:12:02PM -0700, Hsiu-Hui Tseng wrote:
> > Hello,
> >
> > When I do a explain on a query, I got the following:
> > +---
Hi Tom,
Sounds odd... Do other queries that "behave normally" use GROUP BY or
DISTINCT? What are your configuration variables? e.g. SHOW VARIABLES or
mysqladmin variables. Is sort_buffer_size set to some huge value?
Matt
- Original Message -
From: <[EMAIL PROTECTED]>
Sent: Friday, Sept
>Description:
A particular simple mysql query,
including FORMAT, count, and group commands, run on a very small
table, causes mysqld to consume about 1300 Mbytes of swap space
on our sparc solaris systems. Killing and restarting mysqld frees
up that space. All other routine mysql queries seem to
>Description:
A particular simple mysql query,
including FORMAT, count, and group commands, run on a very small
table, causes mysqld to consume about 1300 Mbytes of swap space
on our sparc solaris systems. Killing and restarting mysqld frees
up that space. All other routine mysql queries seem to
> 2 index on this table:
> - one unique index on user_id and att_id (pk)
> - one index on att_id and user_id.
>
> I need to have the following query:
>
> select value from user_att where att_id = ? and value like '?'
> (no wildcard)
> 1. when I do a explain, this query use the second index. But,
I'm still unclear on how to do the decrypt syntax,
forgive me I'm new to DB work, my background is
more security and UNIX admin.
I need help with the data extraction/decryption
SELECT userid, password
FROM user_profile AES_DECRYPT("user","password")
??
What I'm trying to accomplish is I'm u
Im a newbie to MySQL and am trying to evaluate it for our use. Ive been
studying the 4.1 GIS features and cant figure out some relatively simple
things:
- How do I load data (e.g., POINTs) into a GEOMETRY column, either from a
file or from other (NUMERIC) database columns?
It appears tha
On Fri, Sep 19, 2003 at 02:12:02PM -0700, Hsiu-Hui Tseng wrote:
> Hello,
>
> When I do a explain on a query, I got the following:
> +-+
> | Comment |
> +-
Im a newbie to MySQL and am trying to evaluate it for our use. Ive been
studying the 4.1 GIS features and cant figure out some relatively simple
things:
- How do I load data (e.g., POINTs) into a GEOMETRY column, either from a
file or from other (NUMERIC) database columns?
It appears tha
At 3:37 PM -0500 9/19/03, Don Read wrote:
On 19-Sep-2003 Don Read wrote:
On 19-Sep-2003 Dan Anderson wrote:
I am trying to make my PHP script autodetect when a table in a mySQL
database exists, and when it doesn't, create it.
function tableexists($tbl) {
$res = @mysql_query("SELECT 1
At 4:22 PM -0400 9/19/03, Jeff McKeon wrote:
We've got mysql 3.23 installed on a redhat system via the rpm's that
come with RedHat 8.0. I'd like to change the default data directory so
something other than /var/lib/mysql. I know this is supposed to be
possible with a start switch of --datadir=/pa
Paul DuBois wrote:
>
> At 12:40 PM -0600 9/19/03, Jeff Mathis wrote:
> >this looks great. will this work with version 4.04 on solaris?
> >
> >as a side comment, anyone know when 4.1 will get out of the alpha stage?
> >very much looking forward to upgrading, but only when its relatively
> >stable.
No that says that it can figure out the where and prob wont use a key.
The like is probably the cause.
If it was going to use the primary key then the FIELD Key_used
(something like that) would say PRIMARY.
- Dathan Vance Pattishall
- Sr. Programmer and mySQL DBA for FriendFinder Inc.
- http:
Hello,
When I do a explain on a query, I got the following:
+-+
| Comment |
+-+
| Impossible WHERE noticed after reading const tables |
+-
Hi,
I have a table with 18 million of rows. The table structure is
describe user_att
+-+--+--+-+-+---+
| Field | Type | Null | Key | Default | Extra |
+-+--+--+-+-+---+
| user_id | int(11)
On 19-Sep-2003 Don Read wrote:
>
> On 19-Sep-2003 Dan Anderson wrote:
>> I am trying to make my PHP script autodetect when a table in a mySQL
>> database exists, and when it doesn't, create it.
>>
>
>
> function tableexists($tbl) {
> $res = @mysql_query("SELECT 1 FROM $tbl");
> retur
select to_days('2003-11-10') - to_days('2003-11-19')
- Original Message -
From: "Fabio Bernardo" <[EMAIL PROTECTED]>
To: "Mysql (E-mail)" <[EMAIL PROTECTED]>
Sent: Friday, September 19, 2003 4:13 PM
Subject: dates difference
I´d like to write a mysql statemant which takes two dates:
f
We've got mysql 3.23 installed on a redhat system via the rpm's that
come with RedHat 8.0. I'd like to change the default data directory so
something other than /var/lib/mysql. I know this is supposed to be
possible with a start switch of --datadir=/path/to/data but it doesn't
seem to work.
Th
I´d like to write a mysql statemant which takes two dates:
for example:2003-11-10 & 2003-11-19
and results ...9 days
something like :select 2003-11-19 - 2003-11-10
thanks
ahhh yes, thanks for pointing that out. it was not origianlly designed as
such and then the codes changed. time is about the same though
Thanks
[EMAIL PROTECTED] wrote:
I have two tables and am running a simple join between them to get
questions and their repsective response averages from a survey. The
question table has 49 rows and the Response table has 126,732. I'd like to
cut down on the time its taking to run this specific query.
I have two tables and am running a simple join between them to get
questions and their repsective response averages from a survey. The
question table has 49 rows and the Response table has 126,732. I'd like to
cut down on the time its taking to run this specific query...as i'll be
running many li
sorry, I guess I got my answer. the example that I wrote was that exactly
the same query that I had in my program. in the real query I had 3 tables. I
read the mysql note and I found that location of the table to write the link
is important for optimization. by changing the sequence of the tables,
At 1:08 PM -0600 9/19/03, Stout, Jeff wrote:
I have added data into MySQL server 4.0.15
INSERT INTO userdata (userid, password)
VALUES ('user', AES_ENCRYPT ("user","password")
I'm having trouble doing the decrypt
SELECT userid, password (AES_DECRYPT)
FROM userdat
Hi,
SELECT A.fld1, A.fld2, B.fld1 FROM A LEFT JOIN B ON A.lnkfld = B.lnkfld
LIMIT 100;
A and B are big table and this command is very slow. If I use INNER JOIN, is
very fast but I loose some records. How I can write a faster LEFT JOIN
command?
Thanks
--
MySQL General Mailing List
For list arc
Joseph Donato wrote:
Folks,
I am trying to start mysqld and when I do the deamon crashes.
mysqld.log has the following:
030919 14:25:06 mysqld started
030919 14:25:08 Can't start server : Bind on unix socket: Permission
denied
030919 14:25:08 Do you already have another mysqld server running
I have added data into MySQL server 4.0.15
INSERT INTO userdata (userid, password)
VALUES ('user', AES_ENCRYPT ("user","password")
I'm having trouble doing the decrypt
SELECT userid, password (AES_DECRYPT)
FROM userdata blah blah blah
S
At 12:40 PM -0600 9/19/03, Jeff Mathis wrote:
this looks great. will this work with version 4.04 on solaris?
as a side comment, anyone know when 4.1 will get out of the alpha stage?
very much looking forward to upgrading, but only when its relatively
stable.
4.0 went beta in 4.0.3, gamma in 4.0.6,
At 2:37 PM -0400 9/19/03, Dan Anderson wrote:
I am creating a script which will grab a random row from a mySQL table.
Right now the way it is set up each time it calls COUNT(). I was
thinking of creating a script and running it as a cron job to update
count once every 10 minutes and store the numb
At 11:30 AM -0700 9/19/03, Jon Drukman wrote:
At 11:13 AM 9/19/2003, Paul DuBois wrote:
At 10:42 AM -0700 9/19/03, Jon Drukman wrote:
is there any way to get mysqld 4.0.15a from the linux binary
distribution to use another path for my.cnf apart from /etc/my.cnf
/usr/local/mysql/data/my.cnf ~/.my.
On 19-Sep-2003 Dan Anderson wrote:
> I am trying to make my PHP script autodetect when a table in a mySQL
> database exists, and when it doesn't, create it.
>
function tableexists($tbl) {
$res = @mysql_query("SELECT 1 FROM $tbl");
return ($res ? true : false);
}
Regards,
--
Don Rea
I am using MySQL 4.0.15 on Win2K (not by choice, vendor chose this platform)
I user the Database to store user information to Allow RADIUS to authenticate
users against the tables. I have to encrypt the password fields, If I use
MD5 it is a one way algorithm, enable for me to user MD5 I have to
On Fri, Sep 19, 2003 at 11:20:13AM -0700, Daevid Vincent wrote:
> Sorry for the double post. I sent this yesterday without any replies, so I'm
> wondering if it made it out there?
Next time, visit lists.mysql.com and check the archives.
Jeremy
--
Jeremy D. Zawodny | Perl, Web, MySQL, Linux
this looks great. will this work with version 4.04 on solaris?
as a side comment, anyone know when 4.1 will get out of the alpha stage?
very much looking forward to upgrading, but only when its relatively
stable.
jeff
Per Andreas Buer wrote:
>
> Hello Heikki,
>
> "Heikki Tuuri" <[EMAIL PROTECT
Folks,
I am trying to start mysqld and when I do the deamon crashes.
mysqld.log has the following:
030919 14:25:06 mysqld started
030919 14:25:08 Can't start server : Bind on unix socket: Permission
denied
030919 14:25:08 Do you already have another mysqld server running on
socket: /usr/lib/my
I am creating a script which will grab a random row from a mySQL table.
Right now the way it is set up each time it calls COUNT(). I was
thinking of creating a script and running it as a cron job to update
count once every 10 minutes and store the number as an indexed array in
the table. It seem
At 11:13 AM 9/19/2003, Paul DuBois wrote:
At 10:42 AM -0700 9/19/03, Jon Drukman wrote:
is there any way to get mysqld 4.0.15a from the linux binary distribution
to use another path for my.cnf apart from /etc/my.cnf
/usr/local/mysql/data/my.cnf ~/.my.cnf
No, but if you have control over how the s
> Is there some way to do something like:
>
> SELECT * FROM tables WHERE name = "table_name";
>
> And get a result I could test for truth, and thus run my script?
Show tables like 'table_name';
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:htt
Rudolphe,
I saw your posting on the website:
[EMAIL PROTECTED] List Archive
at :
http://www.jsw4.net/info/list-archives/mysql/02-wk41/index.html#00206
We are experiencing the same sort of problem.
Did you ever get a response and/or solve this problem?
Cristl G. Weckenmann
Senior Software E
Sorry for the double post. I sent this yesterday without any replies, so I'm
wondering if it made it out there?
-Original Message-
From: Daevid Vincent [mailto:[EMAIL PROTECTED]
Sent: Thursday, September 18, 2003 11:29 AM
To: [EMAIL PROTECTED]
Subject: Upgrade from 3.23.52 to 4.0.15 all m
* Dan Anderson
> I am trying to make my PHP script autodetect when a table in a mySQL
> database exists, and when it doesn't, create it.
>
> Is there some way to do something like:
>
> SELECT * FROM tables WHERE name = "table_name";
>
> And get a result I could test for truth, and thus run my scrip
At 10:42 AM -0700 9/19/03, Jon Drukman wrote:
is there any way to get mysqld 4.0.15a from the linux binary
distribution to use another path for my.cnf apart from /etc/my.cnf
/usr/local/mysql/data/my.cnf ~/.my.cnf
No, but if you have control over how the server gets started, you can
invoke it with
I am trying to make my PHP script autodetect when a table in a mySQL
database exists, and when it doesn't, create it.
Is there some way to do something like:
SELECT * FROM tables WHERE name = "table_name";
And get a result I could test for truth, and thus run my script?
Thanks in advance,
Da
is there any way to get mysqld 4.0.15a from the linux binary
distribution to use another path for my.cnf apart from /etc/my.cnf
/usr/local/mysql/data/my.cnf ~/.my.cnf
the problem is at my company i am not allowed to install things as root,
so i can't put files in /etc or /usr/local/mysql/data.
* Mark Riehl
> All - We're using MySQL under Linux to capture and analyze
> network traffic. We have two tables that store all the messages sent,
> and, another table that stores all the messages received. The sent
> table has an transmit column (as a double) and the received table has
> a receive
At 3:09 PM +0200 9/19/03, [EMAIL PROTECTED] wrote:
Hello,
I tried to code a (very) small program under windows, this is my first with
C mysql functions :
#include
#include
Try including my_global.h before mysql.h and see if that helps.
int main(void) {
MYSQL *mysrv = NULL;
mysrv = mysql_init(my
At 3:08 PM +0200 9/19/03, Daniele Tagliavini wrote:
Hi,
I have a question for the LIMIT clause.
I have two table with relation 1:n and a query like this :
SELECT tableA.id, tableB.name FROM tableA INNER JOIN tableB ON
tableA.id=tableB.id WHERE something LIMIT x, 20
I want to restrict the result
Matt,
On most platforms, you would generally do a sub select of the form
select playerid
from players p
where not exists
(
select *
from myplayers m
where m.player_id = p.player_id
)
However, as sub selects are only supported in mysql 4.1, you'll need to see
section 1.7.4
Look up Left JOIN. This join will solve your problem.
- Dathan Vance Pattishall
- Sr. Programmer and mySQL DBA for FriendFinder Inc.
- http://friendfinder.com/go/p40688
-->-Original Message-
-->From: Matt MacLeod [mailto:[EMAIL PROTECTED]
-->Sent: Friday, September 19, 2003 8:38 AM
-
This doesn't surprise me. I haven't looked at the code, but I'd bet
that double-quoted, exact phrase matches are handled the usual way by
mysql: First, do a regular fulltext search (using the index) to find
rows with your search words, then check the found rows to see if they
exactly contain
Copy the db from the master to the slave.
- Dathan Vance Pattishall
- Sr. Programmer and mySQL DBA for FriendFinder Inc.
- http://friendfinder.com/go/p40688
-->-Original Message-
-->From: Aris Santillan [mailto:[EMAIL PROTECTED]
-->Sent: Friday, September 19, 2003 3:10 AM
-->To: [EMA
Hi,
I'm building an online fantasy sports game. I want to present a list of
players available to purchase. HOwever I need to filter out the players
the user already has.
I have a table which includes all of the players' information - name,
position, price, etc
I have a table which includes all
It looks like my first issue with slave replication is a verified
bug #1345.
I believe the second one is also because -Q does not quote db names
so I opened a new bug #1348.
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/
From a quick search of the online docs, it seems this is what you need:
http://www.mysql.com/doc/en/Charset-CONVERT.html
but I think it is only in 4.1.0 alpha. Feel free to correct me, I'm no
guru here.
Adam
On 09/18/2003 12:06 PM Marcin Giedz wrote:
- Original Message -
From: "Adam H
We have two 4.0.15 mysql servers set up as master and slave for each other
on HP-UX PA-RISC and Itanium.
A<->B
When using the "HP-UX PA-RISC 2.0, 64-bit only" release, we have problems
with replication. Even though it should have (and "SHOW SLAVE STATUS"
reports) the other server as master, the in
Hi everybody!
This is for Heikki Tuuri:
Do you intend to add fulltext search in innodb tables?
If yes, can you tell me a deadline?
Tanks.
Fernando Bernardino.
__
Acabe com aquelas janelinhas que pulam na sua tela.
AntiPop-u
All - We're using MySQL under Linux to capture and analyze network traffic.
We have two tables that store all the messages sent, and, another table that
stores all the messages received. The sent table has an transmit column (as
a double) and the received table has a received time sent time (from
"Aris Santillan" <[EMAIL PROTECTED]> wrote:
>
> load data from master doesnt work on mysql 3.23.52 version
>
>
> how can i solve this?
You can use mysqldump program or archive master's data dir. Here you can find more
info:
http://www.mysql.com/doc/en/Replication_HOWTO.html
--
For
I have identified a strange case that seems to give false matches when
performing a FULLTEXT IN BOOLEAN search.
Please consider the following:
---
CREATE TABLE `fttest` (
`id` int(10) unsigned NOT NULL auto_increment,
`text` text,
PRIMARY KEY (`id`),
FULLTEXT KEY `text_index` (`text`)
) TYP
Per Andreas Buer <[EMAIL PROTECTED]> wrote:
Hello Heikki,
>
>"Heikki Tuuri" writes:
>
>> I think a 'null' alter table operation:
>>
>> ALTER TABLE innodbtable TYPE=INNODB;
>>
>> does the defragmentation with just one build of the table. And I thi
I can't believe I missed that. The insert statement is in the script - not
sure why it wasn't added - not sure why I missed something so obvious.
David.
- Original Message -
From: "Heikki Tuuri" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, September 18, 2003 11:50 PM
Subjec
Hello,
I tried to code a (very) small program under windows, this is my first with
C mysql functions :
#include
#include
int main(void) {
MYSQL *mysrv = NULL;
mysrv = mysql_init(mystruct);
if ( mysrv == NULL )
{
perror("Struct initialize failed\n");
exit (-1);
}
mysql_close(mystruct
Hi,
I have a question for the LIMIT clause.
I have two table with relation 1:n and a query like this :
SELECT tableA.id, tableB.name FROM tableA INNER JOIN tableB ON tableA.id=tableB.id
WHERE something LIMIT x, 20
I want to restrict the result to 20 row from tableA and n row from tableB and not
is it work?
---
Gustavo Polillo Correa - Analista de Sistemas
Instituto de Biociencias - USP
Sao Paulo - Brasil
Tel/fax : 55-11-3091-7436
---
--
MySQL General Mailing List
For list archive
I would like to do queries to a field TEXT that
contains an XML text.
If for example I have an entry with the text:
MyTitle
When i do the query to search words containing the
word title I would like to obtain
MyTitle
and not because these are tags of the
XMLType
I think this is similar to XMLType
Please accept my apologies for the double-post earlier.
The system sent me a 'self-moderation' challenge requiring me to click
on a link. When I did so, the page said there was no outstanding
challenge and that I should send the message again.
Sorry, Dave
--
MySQL General Mailing List
For list
Hi All,
Has anyone had any experience of using soundex with fulltext searching?
I have looked through the archives and cannot find anything..
I want to avoid building my own idicies for soundex.
Thanks for any help
Andrew
Sql,query
--
MySQL General Mailing List
For list archives: http://lis
On Fri, Sep 19, 2003 at 11:47:38AM +0300, Egor Egorov wrote:
> > I have a server which has been running for about a year now. It
> > started with kernel 2.4.19 and mysql 3.x it has since been
> > continually
> > upgraded so that it is now kernel 2.4.20 and mysql 4.0.13. The
> > server is
> > a Comp
Hi,
Say I have a table with 2 columns. The first is the primary key (int(11), unique,
auto-increment). The second column is a varchar(20) (also unique and indexed). This is
part of a search engine.
Whenever a new document is indexed then for each word I have to do 2 queries: look up
in the ta
Hello Heikki,
"Heikki Tuuri" <[EMAIL PROTECTED]> writes:
> I think a 'null' alter table operation:
>
> ALTER TABLE innodbtable TYPE=INNODB;
>
> does the defragmentation with just one build of the table. And I think it
> also preserves FOREIGN KEY constraints.
>
> Please test it!
It did the job
hi
load data from master doesnt work on mysql 3.23.52 version
how can i solve this?
thanks
> hi
>
> load data from master doesnt work on mysql 3.23.52 version
>
> is there any alternative?
>
>
Jochen Wiedman asked that I post this stack trace.
Please cc me on any replies, as I'm not subscribed to the list.
The original problem description is at the end.
Cheers, Dave
Original Message
Subject: Re: MySQL segmentation faults...
Date: Thu, 18 Sep 2003 20:59:57 +0200
From: J
Jochen Wiedman asked that I post this stack trace.
Please cc me on any replies, as I'm not subscribed to the list.
The original problem description is at the end.
Cheers, Dave
Original Message
Subject: Re: MySQL segmentation faults...
Date: Thu, 18 Sep 2003 20:59:57 +0200
From: J
Anders Bruun Olsen <[EMAIL PROTECTED]> wrote:
>
> I have a server which has been running for about a year now. It
> started with kernel 2.4.19 and mysql 3.x it has since been continually
> upgraded so that it is now kernel 2.4.20 and mysql 4.0.13. The server is
> a Compaq server with dual Pentium
Hi,
buh>/var/db/mysql# tail buh.XXX.XX
030919 0:31:00 Slave I/O thread exiting, read up to log 'cm-bin.086', position
16233275
030919 0:31:00 Error reading relay log event: slave SQL thread was killed
030919 11:08:46 Slave SQL thread initialized, starting replication in log
'cm-bin.086' at
Hi,
I had set up replication between 2 4.0.14 servers and everything seems to work OK.
Except that SHOW SLAVE HOSTS on muster returns nothing. What am I missing ?
tnx,
IOnut
--
IOnut
FreeBSD unregistered ;) user
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
T
:),
i need to do an automatic, dynamic installation
of the win binary distribution. The only thing i know, is
mysql beeing put on a win-machine( >= 98 ) and possibly
the directory it should be placed to.
Did someone work on that before? May i give parameters to the
msi-file, patch it, create a new
"Randy Chrismon" <[EMAIL PROTECTED]> wrote:
>> For LOAD DATA, it works better in 4.1.1, as indicated here:
>
> I read that and immediately went looking on the MySQL site for 4.1.1.
> All I can find is 4.1.0-alpha. Where can I get 4.1.1?
>
You can install it from development source tree:
Hi,
Can someone point to a location where the implementation of indexes on MyISAM tables
is explained? I'm trying to understand exactly (not roughly) how the indexes are
created and used.
Harald
Does anyone think I would have better luck installing MySQL with something
other than an RPM??
-Original Message-
From: James M Kupernik [mailto:[EMAIL PROTECTED]
Sent: Thursday, September 18, 2003 11:59 AM
To: 'mos'
Cc: [EMAIL PROTECTED]
Subject: RE: random access denied
Thank you,
In the last episode (Sep 18), Jeremy Zawodny said:
> On Thu, Sep 18, 2003 at 01:57:17PM +0300, Mikko Noromaa wrote:
> > Is it possible to configure MySQL so that it would allocate a large
> > amount of extra space for the MYD/MYI files, and then use this
> > space as necessary?
>
> I don't know of
88 matches
Mail list logo