Re: locked non-existent row

2011-09-02 Thread Jochem van Dieten
it is called gap locking: http://dev.mysql.com/doc/refman/5.5/en/innodb-record-level-locks.html http://dev.mysql.com/doc/refman/5.5/en/innodb-next-key-locking.html Jochem -- Jochem van Dieten http://jochem.vandieten.net/ -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql

Re: Query Optimization

2011-09-01 Thread Jochem van Dieten
On Aug 30, 2011 6:46 PM, Brandon Phelps wrote: SELECT sc.open_dt, sc.close_dt, sc.protocol, INET_NTOA( sc.src_address ) AS src_address, sc.src_port, INET_NTOA( sc.dst_address ) AS dst_address, sc.dst_port, sc.sent, sc.rcvd,

Re: how things get messed up

2010-02-11 Thread Jochem van Dieten
on them surely is a limitation of that database, not a conceptual disqualification of storing binary data in a database. Jochem -- Jochem van Dieten http://jochem.vandieten.net/ -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http

Re: MySQL View

2009-02-10 Thread Jochem van Dieten
to a select statement, and when you reference that alias the select statement will get substituted back in. Jochem -- Jochem van Dieten http://jochem.vandieten.net/ -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/mysql?unsub

Re: MySQL View

2009-02-10 Thread Jochem van Dieten
On Tue, Feb 10, 2009 at 1:47 PM, Steven Buehler wrote: From: Jochem van Dieten: What the database will do for you behind the scenes is expand your usage of the view. In effect, the database will replace x with its definition. So your query SELECT a FROM x; gets expanded to: SELECT a FROM

Re: Updatable view using subquery??

2009-02-09 Thread Jochem van Dieten
to the y base table. Jochem -- Jochem van Dieten http://jochem.vandieten.net/ -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/mysql?unsub=arch...@jab.org

Re: Distinct Query Problem

2008-12-19 Thread Jochem van Dieten
On Fri, Dec 19, 2008 at 7:03 PM, Tompkins Neil wrote: Basically each product is listed in the master table, and can have a number of suppliers linked to it (ProductTB). The query above will show me a list of products for all suppliers for a particular product. However I want to be able to

Re: feature request: statement SELECT...(INSERT|UPDATE) :)

2008-01-30 Thread Jochem van Dieten
On Jan 30, 2008 12:50 PM, Dmitry E. Oboukhov wrote: Is it possible to add to the syntax of the INSERT operator appoximately in such way: SELECT list INSERT [IGNORE] INTO ... - an added one. SELECT list UPDATE - an added one. PS: I understand that adding the changes into a language is a

Re: creating temp file, modifying data and putting into other table

2008-01-18 Thread Jochem van Dieten
On Jan 17, 2008 9:02 PM, Kerry Frater wrote: Thanks for the input Jochem. If you wish to ignore my code and continue with your own code that of course is fine with me. But why do you expect me to continue to help you if you ignore me anyway? Jochem -- MySQL General Mailing List For list

Re: creating temp file, modifying data and putting into other table

2008-01-17 Thread Jochem van Dieten
On Jan 17, 2008 2:22 PM, Kerry Frater wrote: Can someone please advise. I am looking to create a multiuser friendly way of getting a subset number of rows from a table into another whilst making a modification. create temporary table Ttable1 (select * from masterlist where ref='ABCDE');

Re: Reply-to is to originator rather than to list

2007-10-21 Thread Jochem van Dieten
On 10/21/07, Rob Wultsch wrote: 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

Re: Data Warehousing and MySQL vs PostgreSQL

2007-07-27 Thread Jochem van Dieten
On 7/26/07, Andrew Armstrong wrote: * Table 1: 80,000,000 rows - 9.5 GB * Table 2: 1,000,000,000 rows - 8.9 GB This is a generic star schema design for data warehousing. I have read that it is better if perhaps partitioning is implemented, where new data is added to a partitioned

Re: off-topic unsubscribe concern

2007-07-08 Thread Jochem van Dieten
On 7/8/07, Mogens Melander wrote: On Fri, July 6, 2007 17:55, Michael Dykman wrote: I have been on this list for a pretty long time but in the last few months I have started to receive random 'confirm unsubscribe' messages..They always seem to originate from a Roadrunner IP (I have not

Re: Why doesn't the InnoDB count() match table status?

2007-03-27 Thread Jochem van Dieten
On 3/27/07, Tim Lucia wrote: -Original Message- From: Maciej Dobrzanski Sent: Tuesday, March 27, 2007 6:46 AM To: mysql@lists.mysql.com Subject: Re: Why doesn't the InnoDB count() match table status? MyISAM and InnoDB (and there are plenty more). RDBMS is not an Office

Re: MySQL to Postgres

2007-02-05 Thread Jochem van Dieten
On 2/5/07, Jim C. wrote: CREATE TABLE credits ( person integer NOT NULL default '0', chanid int NOT NULL default '0', starttime timestamp NOT NULL default '1970-01-01 00:00:00+00', role VARCHAR NOT NULL, CONSTRAINT role_check CHECK role IN

Re: MySQL to Postgres

2007-02-05 Thread Jochem van Dieten
On 2/5/07, Jim C. wrote: When I uncomment some of these statements I get an error in regards to a comma. What I'm afraid of is that perhaps there is a compatibility issue such that an INSERT command on Postgres can't take as many records as MySQL. What version are you running? Jochem --

Re: MySQL to Postgres

2007-02-03 Thread Jochem van Dieten
On 2/2/07, Jim C. [EMAIL PROTECTED] wrote: I'm having to move some data from MySQL to Postgres. I used mysqldump --compatible=postgresql, but the compatibility is extremely lacking. It looks more like the person that designed the schema has payed very little attention to the SQL standard. You

Re: How scaleable is MySQL 5's Innodb with multi-core CPU's?

2007-01-02 Thread Jochem van Dieten
On 1/1/07, mos wrote: At 12:49 PM 1/1/2007, Jochem van Dieten wrote: On 1/1/07, mos wrote: http://www.mysqlperformanceblog.com/2006/11/30/interesting-mysql-and-postgresql-benchmarks/ http://tweakers.net/reviews/649/6 Has this been fixed? As the article on the MySQL Performance Blog

Re: How scaleable is MySQL 5's Innodb with multi-core CPU's?

2007-01-01 Thread Jochem van Dieten
On 1/1/07, mos wrote: Is there a problem with InnoDb scaling with multi-processor CPU's? Apparently after reading the Tweakers.net article, with only 40 simultaneous users the performance of MySQL 5 will collapse.

Re: interesting benchmark at tweakers.net

2006-12-19 Thread Jochem van Dieten
On 12/19/06, David Sparks wrote: I noticed an interesting benchmark at tweakers.net that shows mysql not scaling very well on hyperthreading and multicore cpus (see links at end of email). Does anyone know what engine they are using for their tests? (Innodb, myisam, berkdb heheh) InnoDB, the

Re: MAX() and GROUP BY question

2006-11-12 Thread Jochem van Dieten
On 11/10/06, [EMAIL PROTECTED] wrote: Hello everybody Can you explain me please how to get the entire row where ID is maximum per given status_id Mysql 4.0.xx Have you checked the manual? There is an entire page specifically about the group-wise maximum. Jochem -- MySQL General Mailing List

Re: MyISAM vs InnoDB

2006-11-07 Thread Jochem van Dieten
On 11/6/06, Leandro Guimarães Faria Corcete DUTRA wrote: Em Thu, 02 Nov 2006 10:22:18 -0800, Jochem van Dieten escreveu: PostgreSQL supports 2 phase commit. IIRC except for transaction interleaving, join and suspend/resume it supports XA. I think that puts it about on par with Ingres

Re: MyISAM vs InnoDB

2006-11-02 Thread Jochem van Dieten
On 11/2/06, Leandro Guimarães Faria Corcete DUTRA wrote: Em Wed, 01 Nov 2006 09:34:05 -0600, mos escreveu: Is there a better open source database out there for that amount of data? Several. MySQL's own MaxDB, PostgreSQL, Firebird if you are into Borland stuff, Ingres if you need XA

Re: MyISAM vs InnoDB

2006-11-01 Thread Jochem van Dieten
On 11/1/06, mos wrote: Sure, I've thought of those too. But has anyone gotten Firebird to store 700-800gb tables? Can you split Firebird's .gdb file across drives? The main problem with tables of that size is maintaining the index. My upper limit for MySQL is 100 million rows. After

Re: MyISAM vs InnoDB

2006-11-01 Thread Jochem van Dieten
On 11/1/06, mos wrote: At 02:27 PM 11/1/2006, Jochem van Dieten wrote: What is the big deal of a TB? Now, if you get past 20 TB you might want to team up with one of the commercial PostgreSQL supporters (Fujitsu, EnterpriseDB, Greenplum etc.), but Sun even sells appliances for 100 TB

Re: Innodb Locks

2006-10-03 Thread Jochem van Dieten
On 10/2/06, Robert DiFalco wrote: Is there a detailed source for when innodb creates row or table locks? The sourcecode. I have a situation where one thread is performing this in one transaction: UPDATE SomeTable SET WHERE SomeTable.id = N; This is invoked after another thread

Re: problem with InnoDB

2006-09-07 Thread Jochem van Dieten
On 9/7/06, [EMAIL PROTECTED] wrote: I need to know the number of rows that a query will return before actually executing the query. So I am sending select count(*) before sending select *. Actually I need to reject queries if the number of records that it will return is huge, to avoid my server

Re: More than 4 CPUs?

2006-08-19 Thread Jochem van Dieten
On 8/19/06, Wai-Sun Chia wrote: On 8/19/06, Jochem van Dieten wrote: Tweakers.net did a benchmark comparing a trace of the queries generated by their own website on a T1 to a dual Opteron. The article is in Dutch, but the graphs speak for themselves: http://tweakers.net/reviews/633/7 http

Re: More than 4 CPUs?

2006-08-18 Thread Jochem van Dieten
On 8/12/06, Miles Teg wrote: Sun also has some awesome CoolThreads offerings (SPARC architecture), but I haven't had a chance to benchmark one yet. With 32 concurrent threads on a single 8 core 4 way threaded cpu, I'd like to see how MySQL's performance is on those systems. Does anyone have

Re: Can Innodb reuse the deleted rows disk space?

2006-07-29 Thread Jochem van Dieten
On 7/28/06, Dan Nelson wrote: In the last episode (Jul 28), leo huang said: So, the deleted rows' disk space in tablespace can't re-use when I use Innodb, can it? And the tablespace is growing when we update the tables, even the amount of rows do not increase. It can be re-used after the

Re: Show tables replacement

2006-07-06 Thread Jochem van Dieten
On 7/6/06, Ed Reed [EMAIL PROTECTED] wrote: Anyone have an idea on this? Upgrade. Or at least stop repeating the question. Jochem -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

Re: Docs team looking for tech writer

2006-06-20 Thread Jochem van Dieten
On 6/20/06, Stefan Hinz wrote: The MySQL documentation team is looking for another technical writer. For this we need the best and the most dedicated people around. You may work from anywhere in the world as long as you have the necessary skills and technical facilities to communicate across

Re: MySQL (GPL License)

2006-06-08 Thread Jochem van Dieten
On 6/8/06, mos wrote: At 08:15 PM 6/7/2006, you wrote: I believe that if you are only using MySQL for your company's internal needs, whether from a web server or for deployment to other company-owned locations, you don't need a commercial license. Unfortunately that's not what MySQL AB

Re: ugly SQL for a report...

2006-05-29 Thread Jochem van Dieten
On 5/29/06, Cory wrote: I have the following query that is running VERY slowly. Anyone have any suggestions? --- SELECT pnr.ID ID_pnr, pnr.reservationdatetime, pnr.conf_number, pnr.created_by, GROUP_CONCAT(pp.name_last,', ',pp.name_first ORDER BY name_last DESC SEPARATOR 'br') names, (SELECT

Re: ugly SQL for a report...

2006-05-29 Thread Jochem van Dieten
On 5/29/06, Cory Robin wrote: SELECT pnr.ID ID_pnr, pnr.reservationdatetime, pnr.conf_number, pnr.created_by, GROUP_CONCAT(pp.name_last,', ',pp.name_first ORDER BY name_last DESC SEPARATOR 'br') names, (SELECT SUM(pf.base_fare*(SELECT COUNT(1) FROM pnr_passengers pp WHERE

Re: OOC: Reply / Return Address of this List

2006-04-18 Thread Jochem van Dieten
On 4/18/06, Jason Teagle wrote: 1. Please always reply to the List. Who runs this list? Could it please be configured to send replies back to the list rather than the individual? Please read the faq before rehashing issues that have been beaten to death. Jochem

Re: RIGHT JOIN better than INNER JOIN?

2006-03-21 Thread Jochem van Dieten
On 3/21/06, Robert DiFalco wrote: I apologize if this is a naive question but it appears through my testing that a RIGHT JOIN may out perform an INNER JOIN in those cases where they would produce identical result sets. i.e. there are no keys in the left table that do not exist in the right

Re: A difficult query- urgent for me

2006-01-15 Thread Jochem van Dieten
On 1/15/06, [EMAIL PROTECTED] wrote: Actually there is a table with columns a and b . So i want if a contains a particular word than a's value should return else 'b' value should return. SELECT CASE WHEN a = 'Good' THEN a ELSE b END FROM table Jochem

Re: 'LIKE' for numbers

2005-12-18 Thread Jochem van Dieten
On 12/18/05, Andy Pieters [EMAIL PROTECTED] wrote: Is there any operator for mysql that behaves like LIKE but can act on numbers. No. But with a bit of creativity you can use arithmetic to come to a predictae that does the same: SELECT * FROM table WHERE floor(log10(floor(x / y)))

Re: Heikki: What will become of InnoDb once MySQL license runs out

2005-11-07 Thread Jochem van Dieten
On 11/6/05, mos wrote: Sure but if people have commercial applications that use InnoDb, then what? Is there a surprise tax waiting for them next year? Nothing changes for the licenses you already have. If you have an application that is both incompatible with the GPL and depends on InnoDB and

Re: Can't reference column aliases

2005-11-07 Thread Jochem van Dieten
On 11/7/05, mos wrote: Why isn't there a way to reference column aliases in the columns list or where clause? Because the SQL standad says so. See chapter 7 of ISO/IEC 9075-2:2003. select if(score50,-5,0) failing_score, if(score50, 1, 0) passing_score, attendance/totaldays

Re: Heikki: What will become of InnoDb once MySQL license runs out

2005-11-05 Thread Jochem van Dieten
On 11/5/05, Ezra Taylor wrote: To Mysql users: Just to remind you all, Oracle is a business that expects to make money. As you all know, Mysql is a threat to the fat cats such as Oracle,DB2,MSSql and others. If you think Oracle is going to play fair with us I

Re: Heikki: What will become of InnoDb once MySQL license runs out

2005-11-05 Thread Jochem van Dieten
On 11/5/05, Mark wrote: Is there anyone who can shed some light on this without the anti-Orcacle hysteronics? No. Those who know have to go through proper channels. Oracle is a public company and the disclosure of its future actions has to go through proper channels or it will incur the wrath

Re: Will SELECT COUNT(*) FROM TABLE ever be cheap on INNODB?

2005-11-01 Thread Jochem van Dieten
On 11/1/05, Kevin Burton wrote: MyISAM has a cool feature where it keeps track of the internal row count so that SELECT COUNT(*) FROM FOO executes in constant time. Usually 1ms or so. The same query on INNODB is O(logN) since it uses the btree to satisfy the query. Are you sure? Finding a

Re: Checking Multiplicity Constraints and Retrieving Details from Error Messages

2005-10-20 Thread Jochem van Dieten
On 10/20/05, Martijn Tonies wrote: That doesn't help: check constraints are evaluated only on insert and update, not on delete. That's why you need an assertion. Hmmm, would that be SQL standard? Or implementation specific? It is at the very least implied in the SQL standard. From a

Re: Multiple INNER JOINS

2005-10-20 Thread Jochem van Dieten
On 10/19/05, Peter Brawley wrote: I am having problems with the following query: I am trying to join Tax_Bands and Property_Types to Properties but the query seems to be joning Tax_Bands to Properties. That query generates no error in 5.0.13. There have been several cascading join bugs,

Re: Checking Multiplicity Constraints and Retrieving Details from Error Messages

2005-10-20 Thread Jochem van Dieten
On 20 Oct 2005 10:13:56 +0200, Harald Fuchs wrote: Jochem van Dieten writes: Back in reality you don't enforce this using DDL. Apart from the fact that I wouldn't know a single database that implements ASSERTIONs according to the SQL standard, can you imagine having to run some SELECT fk

Re: Checking Multiplicity Constraints and Retrieving Details from Error Messages

2005-10-19 Thread Jochem van Dieten
On 10/19/05, Martijn Tonies [EMAIL PROTECTED] wrote: First of all, is there any way of limiting the number of rows in a table, referencing to the same element of another table? For example, force a manager not to have more than 10 employees under his control. In a way this can be seen as

Re: Checking Multiplicity Constraints and Retrieving Details from Error Messages

2005-10-19 Thread Jochem van Dieten
On 10/19/05, Martijn Tonies [EMAIL PROTECTED] wrote: First of all, is there any way of limiting the number of rows in a table, referencing to the same element of another table? For example, force a manager not to have more than 10 employees under his control. In a way this can be seen as

Re: MySQL 5.0.x

2005-07-14 Thread Jochem van Dieten
On 7/14/05, Joerg Bruehe wrote: Rick Robinson wrote: However, the online manual is not cloned, so while we are building 5.0.9 there can also be new text for 5.0.10 changes that gets integrated into the online manual, and this may become visible earlier than 5.0.9 gets published. Why are

Re: [Fwd: Hi Glen, could I ask a favor regarding the MYSQL list?]

2005-07-12 Thread Jochem van Dieten
On 7/12/05, Gleb Paharenko wrote: auto_parser wrote: Would you be able to forward the following message to the mysql list. I keep getting bounce-backs with the following: Recipient: mysql@lists.mysql.com Reason:Mail from HELO priv-edtnes27.telusplanet.net rejected because it

Re: effective handling of fuzzy dates (MySQL/PHP)

2005-06-29 Thread Jochem van Dieten
On 6/29/05, me you wrote: For the most part, the data entered is correct and uses the full -MM-DD format, however, I've got numerous dates that are incomplete. For example: an event happened in 1967, but the exact month and day are not known. I've been storing that data, in other forms,

Re: SQL help

2005-06-26 Thread Jochem van Dieten
On 6/26/05, 2wsxdr5 wrote: Can someone tell me why this query works... SELECT UserKey FROM( SELECT UserKey, Count(GiftKey) Gifts FROM Gift Group BY UserKey ) GC WHERE GC.Gifts = 3 Why this construction and not simply: SELECT UserKey FROM Gift GROUP BY UserKey HAVING Count(GiftKey) =

Re: Combining several sum queries

2005-06-22 Thread Jochem van Dieten
On 6/22/05, David Kagiri wrote: When i run the queries below they all work just fine SELECT sum(consultation)+ sum(laboratory) FROM nairobi,familymembers WHERE familymembers.dependantid = nairobi.memberid and familymembers.memberid = AKI1 SELECT sum(consultation)+ sum(laboratory)

Re: Shifting dates

2005-06-22 Thread Jochem van Dieten
On 6/21/05, Sebastian wrote: i never understand why people use datetime anyway.. unix timestamp is so much easier to work with. Unix epoch is by definition UTC. Sometimes I want to work with dates in some local timezone. In other databases that have a more complete implementation of the SQL

Re: Query Complexity (big 'O')

2005-06-21 Thread Jochem van Dieten
On 6/21/05, Dan Bolser wrote: I am interested in the theoretical time / space complexity of SQL queries on indexed / non-indexed data. I doubt this is the right list for theory. Specifically I want to know the complexity of a query that does a 'cross tabulation' SELECT X,

Re: Query help - Joining adjacent rows?

2005-06-21 Thread Jochem van Dieten
On 6/21/05, comex wrote: I have a table: create table example(time datetime, username varchar(255)); Please tell me you didn't actualy use time as identifier :) timeusername 2005-06-21 15:58:02 user1 2005-06-21 14:58:02 user1 2005-06-21 11:57:51 user2 2005-06-21 10:57:51

Re: Subselect in an Update query

2005-06-18 Thread Jochem van Dieten
On 6/17/05, [EMAIL PROTECTED] wrote: There is one caveat: It is not currently possible to modify a table and select from the same table in a subquery. That is not the only problem: there is no guarantee the subquery will only return one record. So even if MySQL wouldn't have this limitation

Re: Seriously.. When are we going to get subqueries?!

2005-06-09 Thread Jochem van Dieten
On 6/9/05, Kevin Burton wrote: Jeff Smelser wrote: Thats funny.. looks like it will be added to 5.1.. Dunno why they think fixing it is adding a feature.. WOW! That's just insane! This seriously has to be fixed in 5.0 or sooner... Chill out man. It is not like it is returning the wrong

Re: INSERT DELAYED and NOW()

2005-06-09 Thread Jochem van Dieten
On 6/9/05, Jeremiah Gowdy wrote: I am proposing that when a query is received by MySQL, a timestamp could be taken immediately, and that timestamp could travel with the query until it is actually processed. For delayed inserts, the query would still sit in the insert queue, and it would

Re: INSERT DELAYED and NOW()

2005-06-09 Thread Jochem van Dieten
On 6/9/05, Jeremiah Gowdy wrote: Does this seem to break SQL / application logic in some fashion? Not worse then it is currently broken :) According to the SQL standard CURRENT_TIMESTAMP, which in MySQL is a synonym for NOW(), is supposed to have a value that does not change during a

Re: Seriously.. When are we going to get subqueries?!

2005-06-09 Thread Jochem van Dieten
On 6/9/05, Keith Ivey wrote: I'm a little surprised that case-sensitivity is such a big deal. What sort of programmers randomly vary their capitalization from one occurrence of an identifier to the next Inconsistencies in the capitalization aren't necessarily introduced by a programmer.

Re: Seriously.. When are we going to get subqueries?!

2005-06-09 Thread Jochem van Dieten
On 6/9/05, Roger B.A. Klorese wrote: If you're the first person this has bothered He isn't, search the bugbase. (Including reports that are closed because it is documented, without providing a fix, workaround or even recategorizing as feauture request.) and if the limitations don't provide

Re: Seriously.. When are we going to get subqueries?!

2005-06-09 Thread Jochem van Dieten
On 6/9/05, Bartis, Robert M (Bob) wrote: Its an email alias. You're asking for help from people you don't even know. You should therefore present your needs clearly and concisely. You should expect there to be questions. You should expect to not always get timely information. you should

Re: Timestamp and it's usage (Re: Seriously.. When are we going to get subqueries?!)

2005-06-09 Thread Jochem van Dieten
On 6/9/05, Martijn Tonies wrote: http://dev.mysql.com/doc/mysql/en/timestamp-4-1.html Absolutely brilliant document *g* ... So now, it makes a difference if it's the first TIMESTAMP column, if it's running in MaxDB mode, if it has a defaulf of NULL (which will be silently changed), if it

Re: Seriously.. When are we going to get subqueries?!

2005-06-09 Thread Jochem van Dieten
On 6/9/05, [EMAIL PROTECTED] wrote: Okay, so I understand the idea about one field being the creation time, and the other being the last modified time (which a particularly pedantic application might regard as being one-and-the-same, at time of first-creation) and so I see you might want to

Re: basic sql join question...

2005-05-29 Thread Jochem van Dieten
On 5/29/05, Philip George [EMAIL PROTECTED] wrote: +--++---+--+ | quantity | name | price | subtotal | +--++---+--+ |1 | orange | 0.97 | 0.97 | |3 | pear | 1.09 | 3.27 |

Re: update / subquery

2005-05-29 Thread Jochem van Dieten
On 5/29/05, Lieven De Keyzer wrote: From: Chris Lieven De Keyzer wrote: UPDATE account SET role_id = (SELECT role_id FROM role WHERE rolename = admin) WHERE username = test This gives me an: ERROR 1064 (0): You have an error in your SQL syntax. Check the manual that corresponds to

Re: performance on single column index with few distinct values

2005-05-29 Thread Jochem van Dieten
On 5/28/05, Terence wrote: Master ID is used to distinguish multiple helpdesks. In this table there are 100k records, but only 10 distinct master_id's. ticket_id master_id 1 1 2 1 3 2 4 2 5 3 ... ...

Re: basic sql join question...

2005-05-29 Thread Jochem van Dieten
On 5/29/05, Philip George wrote: On May 29, 2005, at 1:41 AM, Jochem van Dieten wrote: http://dev.mysql.com/doc/mysql/en/group-by-modifiers.html already read that. the join in my example is more complicated than anything depicted on that page. The join is irrelevant. Your join returns

Re: basic sql join question...

2005-05-29 Thread Jochem van Dieten
On 5/29/05, Philip George wrote: On 5/29/05, Philip George wrote: On 5/29/05, Jochem van Dieten wrote: http://dev.mysql.com/doc/mysql/en/group-by-modifiers.html already read that. the join in my example is more complicated than anything depicted on that page. please explain. actually

Re: Opteron HOWTO?!

2005-05-10 Thread Jochem van Dieten
On 5/9/05, Kevin Burton wrote: So... it sounds like a lot of people here (Dathan and Greg) have had problems deploying MySQL on Opteron in a production environment. To me it sounds more like a lot of people have had problems running Linux on x86-64 systems. Jochem -- MySQL General Mailing

Re: LENGTH() and UTF-8

2005-05-09 Thread Jochem van Dieten
On 5/9/05, Andreas Steichardt wrote: We are storing UTF-8 data in out mysql database and we need to get the length of the data. But length() doesn't return the number of characters but the pure number of bytes. Look at OCTET_LENGTH() and CHAR_LENGTH(). (While OCTET_LENGTH() is a synonym,

Re: amPiguous!

2005-05-07 Thread Jochem van Dieten
On 5/7/05, Dan Bolser wrote: Why are columns included in the join between two tables ambigious? Because MySQL does not follow the SQL standard (ISO/IEC 9075-2:2003). select pk from a inner join b using (pk); ERROR 1052 (23000): Column 'pk' in field list is ambiguous!!! Is this a bug,

Re: amPiguous!

2005-05-07 Thread Jochem van Dieten
On 5/7/05, Chris wrote: Somethign else to think about as well, look at this slight modification: select pk from a left join b using (pk); Now, it's not likely this is a valid query for your table structure It is very likely it is. It is even an example in the MySQL manual. but, in

Re: amPiguous!

2005-05-07 Thread Jochem van Dieten
On 5/7/05, Dan Bolser wrote: On Sat, 7 May 2005, Jochem van Dieten wrote: On 5/7/05, Dan Bolser wrote: select pk from a inner join b using (pk); ERROR 1052 (23000): Column 'pk' in field list is ambiguous!!! Is this a bug, or is it like this for a reason? It drives me nuts, because

Re: why NOT NULL in PRIMARY key??

2005-04-26 Thread Jochem van Dieten
On 4/26/05, Jigal van Hemert wrote: http://dev.mysql.com/doc/mysql/en/silent-column-changes.html mentions that Columns that are part of a PRIMARY KEY are made NOT NULL even if not declared that way. And http://dev.mysql.com/doc/mysql/en/create-table.html tells me that A PRIMARY KEY is a

Re: why NOT NULL in PRIMARY key??

2005-04-26 Thread Jochem van Dieten
On 4/26/05, Jigal van Hemert wrote: From: Jochem van Dieten Why is this? Because the SQL standard says so. A true observation, but still no explanation or reason why ;-P I consider it a good enough explanation of why MySQL doesn't allow it. As to why the SQL standard doesn't allow

Re: Two columns query from a single column table?

2005-03-15 Thread Jochem van Dieten
On Tue, 15 Mar 2005 17:43:29 -0600, [EMAIL PROTECTED] wrote: I need to do this: From this table +--+ |id|Data | |--|---| | 1|Something 1| | 2|Something 2| | 3|Something 3| | 4|Something 4| | 5|Something 5| | 6|Something 6| +--+ Get this query

Re: Switching to InnoDB turns out dissapointing

2005-03-01 Thread Jochem van Dieten
On Tue, 1 Mar 2005 18:09:37 -0600, Alfredo Cole wrote: El Mar 01 Mar 2005 17:32, Gary Richardson escribió: InnoDB uses transactions. If you are doing each row as a single transaction (the default), it would probably take a lot longer. I assume you're doing your copying as a INSERT INTO

Re: mysql vs postgresql

2005-02-25 Thread Jochem van Dieten
On Fri, 25 Feb 2005 11:21:26 -0600, mos wrote: http://sunsite.mff.cuni.cz/MIRRORS/ftp.mysql.com/doc/en/MySQL-PostgreSQL_features.html There is a reason this page was removed from the MySQL site: some of it was never correct in the first place, and the rest was severly outdated. Don't you

Re: wikipedia down, slashdot covering, mysql mentioned

2005-02-22 Thread Jochem van Dieten
On Wed, 23 Feb 2005 00:22:55 +0200, Heikki Tuuri wrote: a buggy fsync() in Linux is one of the possible reasons here. If an InnoDB tablespace gets corrupt in a power outage, it is most probably caused by a bad fsync() implementation or configuration in the operating system or hardware. An

Re: Plus sign doesn't concatenate strings in MySQL?

2005-01-15 Thread Jochem van Dieten
On Sat, 15 Jan 2005 11:11:05 -0500, Robert Alexander wrote: Each language is going to have its own personality. If they all did things the same way, we wouldn't have the wealth of different ones to choose from. DBMS's are not languages, they are implementations. Might not be a good idea,

Re: Plus sign doesn't concatenate strings in MySQL?

2005-01-15 Thread Jochem van Dieten
On Sat, 15 Jan 2005 11:37:02 -0500, Dave Merrill wrote: This is my first foray into different flavors of sql, and I'm discovering how incompatible they really are. I expected that core basics would be the same, with each manufacturer adding some proprietary extensions, and failing to support

Re: create sequence

2005-01-13 Thread Jochem van Dieten
On Thu, 13 Jan 2005 11:21:31 -0600, Scott Purcell wrote: I would like to create a sequence object in mysql that I could use in multiple tables through a application I am developing. Sequences are currently not supported in MySQL. Jochem -- MySQL General Mailing List For list archives:

Re: General Sql question

2004-12-04 Thread Jochem van Dieten
On Fri, 03 Dec 2004 10:58:30 -0700, Steve Grosz wrote: I wrote my query as select Cust_ID, Cust_Name from mailings where ucase(Name) = ucase(Cust_Name) When it runs, I get a error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for

Re: Row level security requirements, can I still use MySQL?

2004-11-18 Thread Jochem van Dieten
On Thu, 18 Nov 2004 10:45:37 +0100, Jonas Ladenfors wrote: Hello, I am in the position where I need row level user access, this is crucial in my current project. I know this has been discussed before and the answer has been use views when they become availble. But views would still allow the

Re: Row level security requirements, can I still use MySQL?

2004-11-18 Thread Jochem van Dieten
On Thu, 18 Nov 2004 13:07:11 +0100, Jonas Ladenfors wrote: Anyway I was given a link by Mark Leith (thanks!) on Oracle row level access that seems interesting. Here it is (not MySQL but the mind-work might be interesting). http://www.securityfocus.com/infocus/1743 It does not meet your

Re: List annoyance

2004-11-10 Thread Jochem van Dieten
On Wed, 10 Nov 2004 07:42:29 +, Stephen Moretti (cfmaster) wrote: Why is this list reply to sender and not reply to list? Why don't you read the FAQ? Jochem -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL

Re: Transfering data from postgresql to MySQL

2004-10-18 Thread Jochem van Dieten
On Mon, 18 Oct 2004 18:08:24 +0800, Patrick Hsieh wrote: I am planing to transfer data from postgresql to mysql. Is there any useful tools, scripts or utilities to achieve this? pg_dump First dump the schema, edit that until you have something MySQL understands. Then dump the data using

Re: Adding DSN into Coldfusion Admin?

2004-10-15 Thread Jochem van Dieten
On Fri, 15 Oct 2004 10:26:22 -0600, Steve Grosz wrote: Ok, with leaving the : off the end, and just typing telnet web-server2 3306 I get some jibberish on the screen, and a 'connection lost' message after a few seconds. That's coming from a machine on the same side of the firewall as the Sql

Re: Adding DSN into Coldfusion Admin?

2004-10-15 Thread Jochem van Dieten
On Fri, 15 Oct 2004 11:36:23 -0600, Steve Grosz wrote: I also get the jibberish, and a connection lost error message. Is it something in MySql server that I'm not setting up correctly? That probably means you can reach the MySQL server and the problem is on OSI-layer 5-8 :-) Could you go into

Re: CREATE VIEW gets all mangled up when doing SHOW CREATE VIEW

2004-10-05 Thread Jochem van Dieten
On 05 Oct 2004 11:46:18 +0200, Harald Fuchs wrote: Martijn Tonies writes: MS SQL, or Firebird, for example, store the view-source as defined - this includes comments, spacing etc etc... In short: it becomes usuable. MySQL should do this too. From reading these lists, I think MySQL only

Re: CREATE VIEW gets all mangled up when doing SHOW CREATE VIEW

2004-10-05 Thread Jochem van Dieten
On 05 Oct 2004 12:02:44 +0200, Harald Fuchs wrote: Martijn Tonies [EMAIL PROTECTED] writes: I was asking if the view-source can be stored, so that it can be retrieved the way I created it. Do you agree or disagree? I disagree. A proper information_schema implementation is much more than

Re: CREATE VIEW gets all mangled up when doing SHOW CREATE VIEW

2004-10-04 Thread Jochem van Dieten
On Tue, 5 Oct 2004 00:27:45 +0530, Eldo Skaria wrote: I suppose these are the ways with Databases. They don't work the way we like them to. So please adjust with it. For this matter I think, any RDBMS will be doing their or paddings to the scripts when they are loading it in memories. But

Re: Licensing issues

2004-08-31 Thread Jochem van Dieten
On Tue, 31 Aug 2004 08:23:01 -0400, Scott Hamm [EMAIL PROTECTED] wrote: Since I'm trying to implement a new database replacing Access Database for intranet environment at my work, do I still need a license since I am not exporting my works out of my company. If you don't

Re: Is their still any reason why Stored Procedure calls are not supported in MySql?

2004-08-31 Thread Jochem van Dieten
On Tue, 31 Aug 2004 18:47:57 -0400, Jacob, Raymond A Jr wrote: http://software.tangent.org/download/myperl-0.8.tar.gz at http://tangent.org. Looking at the readme file myperl is mysql userdefined function that executes perl code contained in a table in the select statement. The command line

Re: Correct date query syntax

2004-08-26 Thread Jochem van Dieten
On Thu, 26 Aug 2004 11:31:46 -0500, Yong Wang [EMAIL PROTECTED] wrote: I have a database which contains date attribute in string format (like 2004-08-12). I want to genearte a report based on period time. I use the syntax: date1 ='2004-08-12' date2='2004-08-18' SELECT * FROM account

Re: Order by with one exception

2004-08-13 Thread Jochem van Dieten
On Wed, 11 Aug 2004 23:40:27 -0700, Scott Haneda [EMAIL PROTECTED] wrote: I made a mailing list archiver, I thread discussions by subject. I chose to not use message-id's since so many people hijack threads. Why not select/group on subject, and then thread on messageid. Given this case:

Re: Difference between PostgreSQL and MySQL

2004-08-11 Thread Jochem van Dieten
On Wed, 11 Aug 2004 10:00:32 -0500, Josh Trutwin wrote: On Tue, 10 Aug 2004 23:34:49 +0200 Jochem van Dieten wrote: On Tue, 10 Aug 2004 16:00:12 -0500, Josh Trutwin wrote: MySQL's command line interface and programming API also are nicer for newer users. Why in the world do I need

  1   2   >