I suppose the problem is that table1.table1_id and table2.table1_id are
of different types. The first one is INT UNSIGNED and the second is just
INT.
abdulazeez alugo wrote:
Table1 is as below:
CREATE TABLE table1(table1_id INT UNSIGNED NOT NULL AUTO_INCREMENT,
PRIMARY KEY(tabl
# perror 150
MySQL error code 150: Foreign key constraint is incorrectly formed
What does table1 look like?
abdulazeez alugo wrote:
Yeah I used the mysql_error and it returned Can't create table
'.\website\table2.frm' (errno: 150). So what does that say?
Date: Tue, 7 Apr 2009 17:38:
Perhaps you don't have permissions to create tables?
It would have been much clearer if your script was like this:
$result=mysql_query($your_create_table_statement);
if($result){ print"Successful";}
else {print "Unsuccessful: ".mysql_error()}
abdulazeez alugo wrote:
Hi guys,
Please can anyo
What about source?
use foobar;
source some/dir/file1.sql;
source some/dir/file2.sql;
...
Though, your solution is much simplier.
Michael Dykman wrote:
No include is possible, but this is done pretty routinely:
cat *.sql | mysql ...
- michael dykman
On Wed, Apr 1, 2009 at 10:19 AM, Jør
I think you meant ORDER BY `registers`..
Jay Blanchard пишет:
[snip]
I´ve got a page where a ought to get 20 registers in ramdom order but i want
to display it in an alphabetical order.
Someone knows if there is a way to get that 20 random registers in
alphabetical order?
[/snip]
SORT BY `
T * FROM `sav00_sava0400_dbf` WHERE `emissao` BETWEEN '1999-12-01
00:00:00' AND '2000-12-31 23:59:59';
--
BR,
Eugene Kosov
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Jay Pipes wrote:
SELECT * FROM `sav00_sava0400_dbf`
emissao BETWEEN '2000-01-01' AND '2000-12-31'
UNION ALL
SELECT * FROM `sav00_sava0400_dbf`
emissao BETWEEN '1999-12-01' AND '1999-12-31'
Why not:
SELECT * FROM `sav00_sava0400_dbf`
emissao BETWEEN '1999-12-01' AND '2000-12-31'
?? ;)
-
same.
HTH, Cor
- Original Message - From: "Eugene Kosov" <[EMAIL PROTECTED]>
To:
Sent: Wednesday, June 21, 2006 2:58 PM
Subject: Index on MERGE table
Hi everyone!
I have a bunch of MyISAM tables and one MERGE table. All have same
structure. It seems to me indecies
omthing strange.
Index cardinality is 81 while table contains over than 12 millions of
different values.
I've tried recreating indecies but this didn't help.
I couldn't find anything relevant in documentation.
How should I create index on MERGE table?
Thanks in advance!
--
Re
mysqldump --verbose --add_drop-table --all-databases > backup_06082006.sql
or
mysql --add_drop-table < backup_06082006.sql
or maybe
mysql < --add_drop-table backup_06082006.sql
mysqldump --opt...
This will add DROP TABLE .. IF EXISTS to a dump.
--
MySQL General Mailing List
For list
Ben Burford wrote:
Hello,
Do I need to delete the table 'Indian'??
Try --add_drop-table option
man mysqldump
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
led"
but the table is still locked.
What can be a reason for this behavior? Is it a known bug? I couldn't
find corresponding bugreport at bugs.mysql.com.
Thanks in advance!
--
BR,
Eugene Kosov
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Thanks a lot!! :D
You were right. There was a bug. Upgrading to mysql 4.1.20 solved my
problem.
Daniel da Veiga wrote:
Check http://bugs.mysql.com/bug.php?id=12915
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAI
Try number of CPU's*2 for thread_concurrency
thread_concurrency = 4
...
--
BR,
Eugene Kosov
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
1/4 of what it should have been. I started
running an OPTIMIZE TABLE command every few hours, took a couple of
seconds each time, and performance stayed good.
Thanks for advice. I think I should I give this a try.. :)
Eugene Kosov wrote:
Hi, list!
I have a little table (about 0.5 milloin records
Hi, list!
I have a little table (about 0.5 milloin records) which is kind of
queue. My perl script takes records from it one by one and does somes
actions.
Here's my table structure:
mysql> desc queue;
+--+-+--+-+---+---
7;2/4/2007', '123000', '234', '2', '232', '435', '23', '',
'345', '23', '', '345', '23', '');
INSERT INTO `orders` VALUES ('1232006', 'Sciouscenter', '124323wgwr',
'
Hi, Brian!
First of all I think next time you should better attach your database
structure. It'll be much easier to understand your problem if you will...
Maybe you're asking for something like this:
SELECT project_name, elecremain, controlremain, otherremain, elecremain
+ controlremain + ot
Good day!
Can you be more concrete? I believe nobody in this list can read your
thoughts.
What tells mysql? What do you see in logs?
prathima rao wrote:
i have a hp server . i have installed mysql 4 in that when ever i shut down
the system and start again the mysql server does not start it sa
oreover, do you have a problem with new password format?
Eugene Kosov wrote:
Hi, everyone!
I have transfer user's database and grants from one mysql server
(4.1.15) to an older one (4.0.26). I don't know user's password and
have only it's hash. How can I convert hashed pass
omething similar
to OLD_PASSWORD(), but with 4.1's hashed password as a parameter?
Any links, man references, etc. are welcome!
Thanks in advance!
--
Regards,
Eugene Kosov.
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
nk query below should help you.
SELECT
accounts.name,
COUNT(properties.property_id) AS totalcount,
SUM(IF(status='Active' AND 'approval='Active', 1, 0))
FROM accounts LEFT JOIN properties USING(account_id)
GROUP BY accounts.account_id;
Regard
'password';
Replace USAGE in query above with priveleges set you want for your new account.
See http://dev.mysql.com/doc/mysql/en/grant.html for more info.
Regards,
Eugene Kosov
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Dwi Putra L wrote:
But not two days ago, suddenly the software can not
work properly. Everytime the software run, there
is message which mentioning something about field
size error.
The same messages, about field size error, still
occured, although I have set
Ehrwin Mina wrote:
That isn't true. If you make a ps, you will see something like "mysql
-p x ".
As I said before, you can use something like:
"mysql -uUser --password=`cat password_file` db"
FYI,
Nuno is correct you cannot see the password in the 'ps' and my script
)
Refer to http://dev.mysql.com/doc/mysql/en/union.html for more details.
Regards,
Eugene Kosov
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Christian Wollmann wrote:
By the way: Perhaps you could tell me how I can determine/change the encoding
of the database?
SHOW CREATE DATABASE db_name;
ALTER DATABASE db_name
[[DEFAULT] CHARACTER SET charset_name]
[[DEFAULT] COLLATE collation_name];
http://dev.mysql.com/doc/mysql/en/c
Gregory Machin wrote:
Hi all.
I'm writing a php script to store the contents of html and php pages
in a data base, it works well until there are mysql queries in the
pages source then give errors such as this one.
Query failed: You have an error in your SQL syntax near 'temp'
how do stop mysq
Privet!
Yogesh wrote:
HI,
I have a client that runs php+mysql application and it has a problem with "ORDER BY
some_varchar_field" sql expression. The DB is in russian cp1251 encoding and "order
by" doesnt produce an alphabetically ordered result. our mysql server default charset is
latin1 a
Eugene Kosov wrote:
Chris Faulkner wrote:
HI
I have a query like this
select * from table where (
( field1 = 'VALUE1' and field2 like 'VALUE2%' ) OR ( field3 = 'VALUE1'
and field2 like 'VALUE2%' ) )
I have created two composite indexes - one on fi
Chris Faulkner wrote:
HI
I have a query like this
select * from table where (
( field1 = 'VALUE1' and field2 like 'VALUE2%' )
OR
( field3 = 'VALUE1' and field2 like 'VALUE2%' )
)
I have created two composite indexes - one on field1 + field2 and one
on field3 + field2. Explain on the SQL
[EMAIL PROTECTED] wrote:
Hi,
i try to use mysql with stunnel (http://stunnel.org) in order to encrypt my
mysql connections. I know that mysql-4.x supports SSL but i can't compile it on
my windows box.
When i try to use stunnel on my windows box, it works,
i just have to use this command :
m
Manish wrote:
Hi,
Platform is red hat linux-9..
my hardware is 2.8GHz pentium-4 with 512 GB ram..
softwares are Bugzilla 2.18 ,mysql-standard-4.0.15-pc-linux-i686,
httpd-2.0.40-21
now problem is when i m trying to take back up of mysql by passing the
command..
/usr/local/mysql/b
Dennis Duggen wrote:
Hi list
Im new to the list so i hope it's the right place for my post.
For a projekt i am combining different tables. Everything seems to work,
but in some rows the "Kode" field VARCHAR(10) ends up as INT. I will try
to explain with an example.
Table1
46
47
48
67
Table2
B
34 matches
Mail list logo