query - select from one, update another

2005-08-07 Thread Sebastian
I have two tables: news and comments. i want to count the number of comments for each newsid and update the count in news.comment comments.newsid belongs to news.id can i do this with sub queries? im using v4.1.x i have many records in the comments table so im not sure what the most efficien

Mysql 4.1.13 Problems

2005-08-07 Thread Peter Nikolic
Hi I am newish to Mysql i recently upgraded my install on suse 9.2 to version 4.1.13 from the Mysql site however since the upgrade i have been having problems trying to write lines in tables . I have noticed that since the update i have multiple instances of mysql running which seem to be

Re: how do i solve this problem?

2005-08-07 Thread Gleb Paharenko
Hello. In old versions of MySQL there was a bug with restoring MERGE tables: http://bugs.mysql.com/bug.php?id=1846 "yousef albarak" <[EMAIL PROTECTED]> wrote: > hello peter, > I used this command to dump the data bases > mysqldump -u root -p [database] > [filename.sql] > and for re

Re: Populating table with test file

2005-08-07 Thread Gleb Paharenko
Hello. I'm not sure about 'myPHPadmin', but if it uses LOAD DATA INFILE you should use \N in the data file, if you want to insert a NULL value in the column. See: http://dev.mysql.com/doc/mysql/en/problems-with-null.html >where I would supply the number (would it start with 0 (zero)

Alter table type/insert_method question

2005-08-07 Thread Verdon Vaillancourt
Hi :) I have a table that is created like such... CREATE TABLE `BRANCH_mod_user_groups` ( `group_id` int(11) NOT NULL default '0', `group_name` varchar(30) default NULL, `description` text, `members` text, PRIMARY KEY (`group_id`) ) TYPE=MRG_MyISAM INSERT_METHOD=FIRST UNION=(HUB_mod_u

Re: Problem detected this morning.

2005-08-07 Thread Gleb Paharenko
Hello. See MySQL Security Alert 2005-01-27: http://lists.mysql.com/announce/256 I recommend you to upgrade. "Fredrick Bartlett" <[EMAIL PROTECTED]> wrote: > What is this all about? McAfee caught this problem. It was in \data as > ofiqa.dll I couldn't delete it until I stopped the

Re: Querying value of lower_case_table_names

2005-08-07 Thread Gleb Paharenko
Hello. What about this: mysql> show variables like 'lower_case_%'; ++---+ | Variable_name | Value | ++---+ | lower_case_file_system | OFF | | lower_case_table_names | 0 | ++---+ I think

OT: Show Constraint_type

2005-08-07 Thread Peter Normann
Hi everybody, [EMAIL PROTECTED] wrote: > I believe you are looking for the SHOW CREATE TABLE > command. If I am using the MySQL CLI, I prefer the output > formatted with the \G terminator instead of the ; > terminator like this > > SHOW CREATE TABLE tablename\G This is a life saver - I wasn't