Re: Reply-to is to originator rather than to list
Some good advice, applying to both mailing lists and businesses: Always reply-to-all, unless there is a good reason not to. My 2 cents. Rob Wultsch schreef: I was previously on a list where the reply-to was setup as it is on the mysql list, with the originator receiving a response rather than list. It ended up that that setting was the default, and had not been changed when the list was setup. Is there a good reason why the reply-to is setup as it is on this list? I forget to change the destination address for most every email I write, I would guess I am not alone, and I do not think that this is good for the list. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: database structure
CREATE TABLE `tags` (`tagid` INT(11) UNSIGNED AUTO_INCREMENT PRIMARY KEY, `location` VARCHAR(255) NOT NULL DEFAULT '') ENGINE=INNODB; CREATE TABLE `dimension_type` (`id` ..., `type` VARCHAR(255) NOT NULL DEFAULT '') ENGINE=INNODB; CREATE TABLE `tags_shape_dimensions` (`tag` INT(11) UNSIGNED, `dim` INT(11) UNSIGNED, `value` VARCHAR(255) NOT NULL DEFAULT '') ENGINE=INNODB; 1) You fill the dimension_type table with all the possible characteristics (in fact, characteristics would be a better name for that table) you will be using, with the advantage of being able to very easily add an extra characteristic later down the road. 2) You fill the tags table with all your differenent tags and locations. 3) You fill in the tags_shape_dimensions table with your tag and any characteristic that applies to it and its associated value. You would select data from these tables by using JOIN's. A bit difficult to grasp if you're an absolute beginner, but you'll never want to go back afterwards. Greetz, boro Hiep Nguyen schreef: On Mon, 2 Jul 2007, Borokov Smith wrote: Or: Tag ShapeDimension (type enum('height', 'thickness', etc), value VARCHAR() or INT()) TagsShapeDimensions (FOREIGN KeY TAG, FOREIGN KEY ShapeDimension) 1 less table Greetz, boro Rajesh Mehrotra schreef: Hi, You can do this in four tables: 1. Tag 2. Shape (with an additional field, let us call it X, describing how many data elements each shape has) 3. ShapeElements : one record describing each data element (length, width etc.) for each shape. Record count for each shape: X 4. Data Table : X number of records for each TagID. References ShapeElements. The number of table will remain fixed at four, no matter how many shapes you have. And your SQL statements will be generic, most of the times, regardless of the shape. Sincerely, Raj Mehrotra hccs - Experts in Healthcare Learning (516) 478-4100, x105 [EMAIL PROTECTED] -Original Message- From: Hiep Nguyen [mailto:[EMAIL PROTECTED] Sent: Monday, July 02, 2007 8:53 AM To: mysql@lists.mysql.com Subject: database structure Hi all, i'm seeking for help/suggestion on how to create relationship for this scenario: I have one table (tag) with the following fields: tagid, location, weight, grade, heat, shape, diameter, length, width, height, ... (and many other fields) what i want to do is move the shape field into a different table, however, each shape will have different dimensions for sample: rod bar has diamter and length, but square/flat bar has width, height (thickness), and length. wire has only diameter. but i also don't want to create a huge table to hold all the possible fields in all shapes, so i'm thinking create a table per shape: round table (diameter, length) square table (width, height, length) i-beam table (flange height, flange thickness, web thickness) angle table (leg1, leg2, thickness) ... and so on. in turn, i have 2 tables: tag, shape + as many table as there are shapes my question is: is there a better to do this? how do i query with this structure? i'm a bit confuse on how to manipulate data if each shape have diffent fields??? Thank you for all your help (sorry for a long email) T. Hiep i'm a novice and confused, can you enlight a little bit more? example of data if possible. thanks, T. Hiep -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: question about Queries per second avg
C.R.Vegelin wrote: ... How should I interpret Queries per second avg ? How about as 'queries per second on average' :) -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: question about Queries per second avg
I have to admit, Google doesn't provide much information. Let's take a closer look and see if we can't figure out ourselves what that value means. Here is the output of `mysqladmin status` on my development box: Uptime: 7510 Threads: 3 Questions: 4123 Slow queries: 0 Opens: 713 Flush tables: 1 Open tables: 64 Queries per second avg: 0.549 The number of queries would be Questions + Slow queries. See if you can spot where mysqladmin gets its time count and use it to divide the previous sum. Your box isn't underperforming, it just isn't under a high load. Question answered ? grtz C.R.Vegelin wrote: Thanks Christophe, Question rephrased: how do you explain 0.05 q/s = 20 s/q with an immediate response ? Cor - Original Message - From: Christophe Gregoir [EMAIL PROTECTED] To: C.R.Vegelin [EMAIL PROTECTED] Cc: mysql@lists.mysql.com Sent: Friday, April 06, 2007 8:35 AM Subject: Re: question about Queries per second avg C.R.Vegelin wrote: ... How should I interpret Queries per second avg ? How about as 'queries per second on average' :) -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: question about Queries per second avg
Ofcourse, the number of queries is just the value of Questions. Christophe Gregoir wrote: I have to admit, Google doesn't provide much information. Let's take a closer look and see if we can't figure out ourselves what that value means. Here is the output of `mysqladmin status` on my development box: Uptime: 7510 Threads: 3 Questions: 4123 Slow queries: 0 Opens: 713 Flush tables: 1 Open tables: 64 Queries per second avg: 0.549 The number of queries would be Questions + Slow queries. See if you can spot where mysqladmin gets its time count and use it to divide the previous sum. Your box isn't underperforming, it just isn't under a high load. Question answered ? grtz C.R.Vegelin wrote: Thanks Christophe, Question rephrased: how do you explain 0.05 q/s = 20 s/q with an immediate response ? Cor - Original Message - From: Christophe Gregoir [EMAIL PROTECTED] To: C.R.Vegelin [EMAIL PROTECTED] Cc: mysql@lists.mysql.com Sent: Friday, April 06, 2007 8:35 AM Subject: Re: question about Queries per second avg C.R.Vegelin wrote: ... How should I interpret Queries per second avg ? How about as 'queries per second on average' :) -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: ORDER BY question
Hey Mike, Sounds like you would be better of with an ENUM of integers, e.g. ENUM(-1,1,2,3) where -1 stands for to be started, 1 for started and so on. To answer your question: ORDER BY `status` = 'to be started', `status` = 'started', `status` = 'finished', `status` = 'canceled' Mike van Hoof wrote: Hello everybody, I got a small problem with ordering on en ENUM field. The values in this field are: - to be started - started - finished - canceled And i want to order on this field, but in the direction the are above here (and not alpabetically). Is that possible? - Mike -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: indexes and size
Hiep Nguyen wrote: i believe date is a reserved word for mysql. don't use reserved word for the column name. it's confused. Using reserved words may be confusing, but it is fine as long as you put them between backticks, as I'm sure the OP is aware of. On Tue, 20 Mar 2007, Peter wrote: Hello, I have a a large a table which a field called date, type date. When I select a smaller range e.g 3 months system uses the index 'date'. That is for let's say 2 million rows. If I select wider date range mysql stops using key. It says possible key date, but do not use it and goes over all 28 Million rows. If I use force index the query becomes even slower. Table type is Myisam. Please advise what should I tune so mysql uses the index without force index and query becomes faster. Thanks :-) Peter -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Can't Bind to Port
Drew Jenkins wrote: - Original Message From: Borokov Smith [EMAIL PROTECTED] To: Drew Jenkins [EMAIL PROTECTED] Cc: mysql@lists.mysql.com Sent: Friday, March 2, 2007 6:21:59 PM Subject: Re: Can't Bind to Port netstat -nlp | grep 3306 Option p requires a protocol. What protocol should I give it? Drew Maybe on FreeBSD :) do netstat -nl | grep 3306 then it should show you which process is occupying port 3306. and you can take it up from there. greetz, boro greetz, boro Drew Jenkins wrote: Hi; I just installed MySQL from FreeBSD port. I specified using openssl. Outside of that, I changed nothing. I copied over the /etc/my.cnf as is, leaving the innodb stuff commented out. In preparing to install my database, I got this error: server312# mkdir /usr/local/localhost server312# chown mysql:mysql /usr/local/localhost/ server312# /usr/local/libexec/mysqld -uroot -hlocalhost --max_allowed_packet=999M InnoDB: The first specified data file ./ibdata1 did not exist: InnoDB: a new database to be created! 070302 15:58:29 InnoDB: Setting file ./ibdata1 size to 10 MB InnoDB: Database physically writes the file full: wait... 070302 15:58:29 InnoDB: Log file ./ib_logfile0 did not exist: new to be created InnoDB: Setting log file ./ib_logfile0 size to 5 MB InnoDB: Database physically writes the file full: wait... 070302 15:58:29 InnoDB: Log file ./ib_logfile1 did not exist: new to be created InnoDB: Setting log file ./ib_logfile1 size to 5 MB InnoDB: Database physically writes the file full: wait... InnoDB: Doublewrite buffer not found: creating new InnoDB: Doublewrite buffer created InnoDB: Creating foreign key constraint system tables InnoDB: Foreign key constraint system tables created 070302 15:58:29 InnoDB: Started; log sequence number 0 0 /usr/local/libexec/mysqld: Table 'mysql.general_log' doesn't exist 070302 15:58:29 [ERROR] Can't start server: Bind on TCP/IP port: Address already in use 070302 15:58:29 [ERROR] Do you already have another mysqld server running on port: 3306 ? 070302 15:58:29 [ERROR] Aborting 070302 15:58:30 InnoDB: Starting shutdown... 070302 15:58:32 InnoDB: Shutdown completed; log sequence number 0 46403 070302 15:58:32 [Note] /usr/local/libexec/mysqld: Shutdown complete # ps wax|grep mysqld 3986 p1- I 0:00.01 /bin/sh /usr/local/bin/mysqld_safe 4034 p1- I 0:11.16 /usr/local/libexec/mysqld --basedir=/usr/local --datadir=/var/db/mysql --user=mysql --pid-file=/var/db/my server312# nmap localhost Starting Nmap 4.11 ( http://www.insecure.org/nmap/ ) at 2007-03-02 16:02 UTC Interesting ports on localhost.by2012.com (127.0.0.1): Not shown: 1672 closed ports PORT STATE SERVICE 22/tcp open ssh 25/tcp open smtp 110/tcp open pop3 143/tcp open imap 993/tcp open imaps 3306/tcp open mysql 8021/tcp open ftp-proxy 8080/tcp open http-proxy I presume everything went well here until it went to bind to the port. There's no other MySQL running on the server, so why can't it connect to the port? This server isn't yet set up with an URL, so if it's reading from rc.conf or what have you, that could be tripping it up. Please advise. TIA, Drew Finding fabulous fares is fun. Let Yahoo! FareChase search your favorite travel sites to find flight and hotel bargains. http://farechase.yahoo.com/promo-generic-14795097 Looking for earth-friendly autos? Browse Top Cars by Green Rating at Yahoo! Autos' Green Center. http://autos.yahoo.com/green_center/ -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]