Re: Does Null == ""?

2003-09-18 Thread Bob Hall
guidance, whatever other problems they cause. > As an aside, it was a sad day when codd died. Michael Stonebreaker may be the Codd of the current generation, but Edward was the Codd of our fathers. Bob Hall -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

Re: Does Null == ""?

2003-09-17 Thread Bob Hall
On Wed, Sep 17, 2003 at 09:58:16PM -0400, Bruce Feist wrote: > Bob Hall wrote: > > >Bruce Feist has initiated a discussion with me off the list, > > Off the list by accident, by the way. I sometimes forget that in this > list I need to do a REPLY ALL. I generally don&

Re: Does Null == ""?

2003-09-17 Thread Bob Hall
d for both (as it should be if it is allowed). But this is coming dangerously close to cleverness, which is a bad quality in a database designer. These problems should occur very rarely. I'll repeat that if you are trying to split NULL into its two meanings, you are probably making a design mistak

Re: Does Null == ""?

2003-09-16 Thread Bob Hall
eate unnecessary confusion. Bob Hall -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

Re: Re Does NULL == ""?

2003-09-16 Thread Bob Hall
faster (produce result sets > faster) when all the data are loaded? There are three formats for the > DDL that I can think of immediately (I'm a newbie at this stuff): Use NULL. Disallow NULL only in columns where you know there will always be data. In the table you describe above, only

Re: Does Null == ""?

2003-09-15 Thread Bob Hall
the main database without the data, then the data isn't essential. If the data isn't essential, then the NULL is usually OK. For unessential attributes, it rarely matters whether the data is not known or not applicable. Bob Hall -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

Re: Does Null == ""?

2003-09-15 Thread Bob Hall
meanings are conventional. The problem with a zero-length string is that it has no conventional meaning. Bob Hall -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

Re: Does Null == ""?

2003-09-15 Thread Bob Hall
n meaning, and it isn't "not applicable". Doing this will cause a lot of confusion. Bob Hall -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

Re: Does Null == ""?

2003-09-15 Thread Bob Hall
On Mon, Sep 15, 2003 at 09:53:11PM -0400, Bruce Feist wrote: > Bob Hall wrote: > > >The meaning of NULL is defined in the SQL specification; it means > >"not known" or "not applicable". > > > Which is just about as useful as not defining it, actual

Re: Does Null == ""?

2003-09-15 Thread Bob Hall
ength strings, and they were nightmares. I can't think of any reason why you would use a zero-length string in a database. Bob Hall -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

Re: don't work

2003-09-12 Thread Bob Hall
. Am running version 4.8 I've always installed MySQL from the ports, so I never had to do those Unix thingies. Never had a problem. The simplest solution is to install from the ports. Bob Hall -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

Re: converting from MS Access

2003-09-12 Thread Bob Hall
g with dbtools; no one can answer your question without knowing what you are doing. Bob Hall -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

Re: SQL Q: Concatenate multiple rows on same column.

2003-08-21 Thread Bob Hall
ed to solve this problem. SQL has very limited formatting capabilities. You need to send the SQL output to an application that will format it for you and generate a report. You can write the app yourself (PHP, Pearl, C, etc, etc) or you can use an existing app with report-formatting capabilities.

Re: I wonder why nobody answered me

2003-06-17 Thread Bob Hall
sums. SELECT r0.Day, SUM(r1.Amount) as S_Am FROM rates AS r0, rates AS r1 WHERE r1.Day <= r0.Day GROUP BY r0.Day This runs fine in vi, but I haven't tried it in MySQL. Some adjustment may be necessary. If you're going to do much of this, I suggest getting a copy of "SQL For

Re: Formatting SQL in Access

2003-02-14 Thread Bob Hall
query database On Fri, Feb 14, 2003 at 11:17:22AM +1100, Daniel Kasak wrote: > You have to use the visual basic constant: vbCrLf Or vbNewLine. Bob Hall - Before posting, please check: http://www.mysql.com/manual.php (

Re: converting MS SQL to MySQL

2003-02-09 Thread Bob Hall
est place to start looking for info is the on-line manual at www.mysql.com. Good luck, and have fun. Bob Hall > I am executing the following: > > CREATE TABLE 'Accounting'( > 'Username' VARCHAR(254) NULL, > 'CallerID' VARCHAR(128) NUL

Re: SQL Syntax Help

2003-02-01 Thread Bob Hall
I think it will avoid confusing the MySQL optimizer. Bob Hall - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mai

Re: opposite of this join

2003-01-21 Thread Bob Hall
don't spend anymore time on it unless your curious yourself. > thanks just the same, > jb > > > |-+--------> > | | "Bob Hall" | > | || | er.net> | > |

Re: opposite of this join

2003-01-21 Thread Bob Hall
lieve you can treat the attends column as a boolean type. Add "AND attends = FALSE" to the WHERE clause to get the events they will not attend. If that works, it answers both of your questions. (You can also use "attends = 0", but "attends = FALSE" is mor

Re: opposite of this join

2003-01-21 Thread Bob Hall
link a person to an event that they're not attending. I've got a entry in the MySQL SQL section of my website called "Whether a row on one side of a many-to-many join is linked to a given row on the other side" that has a solution. http://users.starpower.net/rjhalljr/Serve

Re: Connection ms access to mysql

2003-01-17 Thread Bob Hall
estion is: How are you trying to export your Jet tables? I assume that's what you mean when you refer to "files". If you actually want to put your mdb files on FreeBSD, then you should be asking the freebsd-questions list about Samba. Bob Hall --

Re: MySQL or MS Access ?

2002-06-05 Thread Bob Hall
rs: Depending on circumstances, both Jet and MySQL vary in the number of users they can handle, but under all circumstances, Jet has a lower limit. Bob Hall -- Access Hamsters: Free tools for users, DBAs, and developers. Source Code: More of the same, with source code. SQL: Solutions, troubl

Re: outer joins

2002-03-22 Thread Bob Hall
ble1.id=table2.id) ... > > But how to join > > SELECT . FROM table1 LEFT JOIN table2 ON (table1.id=table2.id) ... > and > SELECT . FROM table2 LEFT JOIN table2 ON (table1.id=table2.id) ... > table1. Idem for table2. Outer join: SELECT ... FROM ... LEFT JOIN ON

Re: SubSelect Problem

2002-03-18 Thread Bob Hall
DISTINCT st.textid, st.title, st.description FROM structure st INNER JOIN subtopic su ON st.textid = su.textid WHERE su.topicid = 'Top'; I haven't run this, so I can't guarantee that it will work. Bob Hall -- Database, table, query.

Re: Need MySQL help with tables and records

2002-03-16 Thread Bob Hall
Each row contains the tech ID and the ticket ID. This makes your SELECT queries a little more complicated, but in the long run it creates fewer problems than any other solution. Bob Hall - Before posting, please check: http://www.

Re: MySQL tables named 'column' cause problems.

2002-03-16 Thread Bob Hall
pid that MySQL lets you create tables with > reserved words, but it stops you from making dumps. Still seems like a bug > to me. Sir, naming a column "column" is generally considered a bad idea, regardless of the DBMS being used. It's like naming a variable "variable".

Re: is MySQL relational?

2002-03-08 Thread Bob Hall
On Fri, Mar 08, 2002 at 02:35:59PM -0500, Bob Hall wrote: > On Fri, Mar 08, 2002 at 04:21:09AM +0200, savaidis wrote: > > Is MySQL a relational database? > > If yes, how is implemented a "one to one" and "one to many" relation? > > Sir, there is no

Re: is MySQL relational?

2002-03-08 Thread Bob Hall
emented in queries, as is the case with all relational database management systems; e.g. Oracle, Sybase, Informix. Bob Hall -- "And Pharaoh spake unto Moses 'Database, table, and query.'" - Before posting, pl

Re: Comments in Documentation

2002-02-23 Thread Bob Hall
not intended to teach you to use MySQL. It's intended as a comprehensive reference document. If you want a primer, buy Paul's book. If you want something free and online for beginners, cruise to the MySQL FAQ. I learned my first programming language from the vendor's reference

Re: I must ask.

2002-02-13 Thread Bob Hall
cy. Speed/efficiency is a minor issue. Integrity constraints are used to prevent people from writing queries that violate relational integrity rules; e.g. create orphan records. And integrity constraints are unrelated to joins, except in the most incidental way. It is possible to use t

Re: I must ask.

2002-02-08 Thread Bob Hall
cy. Speed/efficiency is a minor issue. Integrity constraints are used to prevent people from writing queries that violate relational integrity rules; e.g. create orphan records. And integrity constraints are unrelated to joins, except in the most incidental way. It is possible to use t

Re: calculated fields

2002-01-24 Thread Bob Hall
ch discusses > them if the are indeed included. > If they are not available has anyone suggestions for how I may work around > this lack of functionality. Sir, calculated columns violate third normal form. The standard way of creating calculated columns is to use a query. Bob Hall -- dat

Re: Porting from MS SQL to MySQL

2002-01-21 Thread Bob Hall
2) You need the system NOW, and the bidder has an SQL Server system already developed that will fit your needs and can be installed immediately. It doesn't sound like either of these two conditions describe your situation. Bob Hall --

Re: A difficutl query I cannot do.

2002-01-09 Thread Bob Hall
hs2 Art > 901 Science2Eng1 > French You need to cross tabulate the data. http://www.mysql.com/articles/wizard/index.html Bob Hall - Before posting,

Re: Normalization advice needed

2001-12-27 Thread Bob Hall
er than first normal form. And so on. I've never seen anyone take it past Boyce-Codd normal form. Take it that far if you can. Bob Hall - Before posting, please check: http://www.mysql.com/manual.php (the manual) htt

Re: To Mr Bob Hall (and everybody else who wants to read it)

2001-12-27 Thread Bob Hall
rd to guess the Italian > translation). You can also turn off the warnings globally, on the Edit tab in Tools/Options. Uncheck the appropriate boxes under 'Confirm'. Carsten's solution is probably better in most situations. BTW, this thread is no lo

Re: Left join?

2001-12-27 Thread Bob Hall
of the LEFT JOIN keywords is preserved. In a right outer join, the table to the right of the RIGHT JOIN keywords is preserved. So a LEFT JOIN b is the same as b RIGHT JOIN a Table a is preserved in both cases. Bob Hall

Re: SQL sintax problem of a biginner

2001-12-26 Thread Bob Hall
t matches the value '[Forms]![Clients]![Id]'. MySQL can't make any sense of this, so it returns an error message. Grab the ID value before writing your query. Then insert the actual ID value into the pass-through query when you write it. So if the ID is 248, your WHERE clause wo

Re: Question of a Beginner

2001-12-26 Thread Bob Hall
'm confused. If you want the ORACLE equivalen of EXEC SP, you need to post to an ORACLE forum. If you want the MySQL equivalent, please explain what EXEC SP is. Bob Hall -- "In the room women come and go, Speaking of databa

Re: Nested Inner Joins

2001-12-12 Thread Bob Hall
st fine. But you can't put an inner INNER JOIN between the outer INNER JOIN and the ON keyword. Try FROM (inner INNER JOIN clause) INNER JOIN tblMethodType ON ... Do the same thing with the innermost INNER JOIN clause. What you typed above works fine in Access because Access doesn't

Re: Hopefully easy SQL question

2001-11-14 Thread Bob Hall
urned should be: > > 4385 - 1 > 4513 - 2 > 4382 - 3 > 4533 - 7 Sir, try a self join. Do a standard aggregate query to get the max storyIDs, GROUP BY the category ID, and join the max storyIDs to the storyIDs of the

Re: My Book (WAS Re: MySQL Developer's Handbook)

2001-11-13 Thread Bob Hall
write about. > I'd be glad to send you the working TOC outline for feedback. If you're looking for kibbitzers, why not just post the TOC to the mailing list? Bob Hall -- "In the room women come and go, Speaking of database, query, and table."T-Sql Elliot ---

Re: Need help with a query ...

2001-11-02 Thread Bob Hall
at2.Category = 'Football' OR Cat2.Category IS NULL) AND (Cat3.Category = 'Players' OR Cat3.Category IS NULL); If you want the output in the 'Sports:Football:Players' form, you can rewrite

Re: ADO/ODBC question

2001-07-30 Thread Bob Hall
SQL when doing single row inserts over native connections. For code examples, see your friendly neighborhood MS help files. I've devoted more than enough space on a MySQL list to ADO. -- Bob HallHow to invoke the MySQL list daemon: Sql, table, query and databa

Re: mysql.org

2001-07-21 Thread Bob Hall
one and lack of substantial result make it sound like you had a "frank exchange of views". Since MySQL AB initiated posting events here as they occur, and few people complained about it, I see no reason why either side shouldn't continue, unless we plan to ban all discussion of the ma

Re: mysql.org

2001-07-21 Thread Bob Hall
lack of result make it sound like you had a "frank exchange of views". Since MySQL AB initiated posting events here as they occur, and few people complained about it, I see no reason why either side shouldn't continue. -- Bob Hall mysql list incanta

Re: mysql.org

2001-07-20 Thread Bob Hall
On Thu, Jul 19, 2001 at 09:17:31AM -0400, Bob Hall wrote: > > I think I've made it clear that I'm not enamored of NuSphere's > recent actions, which I think are remarkably bone-headed. At I'm afraid the emotions aroused by recent events have stripped away my thin

Re: mysql.org

2001-07-19 Thread Bob Hall
is MySLQ AB going to contribute that both helps NuSphere and helps create the perception of an atmosphere that welcomes outsiders, and what is the value of MySQL AB's contribution (i.e. how much is NuSphere going to pay for an agreement, either in cash or otherwise). -- Bob Hall mysq

Re: group by concat

2001-07-09 Thread Bob Hall
> >Is it bug or feature? > >Thanks >Marek Sir, what does GROUP BY Concat(col1, col2) do that GROUP BY col1, col2 does not? In other words, I don't see any point in using Concat(). Bob Hall Know thyself? Absurd direction! Bubbles bear no intros

Re: Strange pseudo-coded query

2001-07-01 Thread Bob Hall
a member of the Forms collection (an object in an Access database). [Zip Code] is a field which is a member of the [Zip Code Distance Extractor] form. Rolf quite naturally assumed that you were working with an Access database application (and so did I), and was trying to direct you to the Access h

Re: linking columns

2001-07-01 Thread Bob Hall
iel Sir, use a query to return calculated columns. Don't put them in tables unless you're going to delete or replace the values the calculation was based on and you need to store the results of the calculation. Bob Hall [EMAIL PROTECTED] >>>> Know thyself? Ab

Re: Challenging SQL Problem

2001-07-01 Thread Bob Hall
>Hello, > >I am having a lot of trouble trying to find the best >way to write the SQL to do the following: > >I have a table called "referrals." In this table I >have a column called "ref." The data in the ref column > >are of the form "p/$promo_id/$date". An example would >be "p/26/20010629" whic

Re: Very difficult Query! Help plz!!

2001-06-28 Thread Bob Hall
ults of the first query and sum the scores in each group, the following should work: SELECT Sum(Score) FROM Planetarion WHERE Score > $x AND Score < $y AND Size > $a AND Size < $B GROUP BY X, Y; Bob Hall [EMAIL PROTE

Re: select query for duplicate records

2001-06-27 Thread Bob Hall
ete Sir, try the following. SELECT DISTINCT device, hostname FROM GROUP BY hostname HAVING Count(*) > 1; Only one of the two or more devices will be listed. If you want to include cases where the same device has been listed twice with the same hostname, leave out the DISTINCT. WOMM (Works

Re: Good book for MySQL and Perl DBI?

2001-06-24 Thread Bob Hall
eleasing 'MySQL and Pearl for the Web'. If that's what you're interested in, the book is due at the end of July. There's a little information about the book at www.newriders.com. I'm going through a review copy and it looks pretty good. The publisher said that

Re: VB, SQL: ...WHERE Mitglieder.geb='1978-08-26' doesn't work

2001-06-15 Thread Bob Hall
t;) > >Here I get an Error-Message: > >"Runtime-Error 3464, ..." With DAO, the query has to pass through the Jet Engine, so you need to adjust for Jet's idiosyncrasies. "WHERE Mitglieder.geb = #1978-08-26#" That's my best guess. Bob Hall Know

Re: mysql query urgent!!!

2001-06-12 Thread Bob Hall
) ) ) AS time_group FROM User; SELECT time_group, Count(*) FROM time_groups GROUP BY time_group; It works on my machine. The time_group values are chosen so that they will display in the proper

Re: RE: JOIN to the same table multiple times

2001-06-10 Thread Bob Hall
Employees WHERE Dept = $dept AND Site = $site; If you're going to set up databases, you should get a book on relational databases. There's a number of books on the market, and the one's I've seen all seem to be equally good. I own a copy of 'Relational Databases Clearly E

Re: SQL question

2001-06-10 Thread Bob Hall
f his code assume a procedural language (e.g. PL/SQL or Transact-SQL), so you will need a client app to fully implement the solutions using MySQL. Bob Hall Know thyself? Absurd direction! Bubbles bear no introspection. -Khushhal Khan Khatak MySQL list magic words: sql query database

Re: Update phone inner join tmpphone....

2001-06-09 Thread Bob Hall
rted by MySQL?? No sir. Updating a table based on data in another table won't be supported until version 4 comes out. Bob Hall Know thyself? Absurd direction! Bubbles bear no introspection. -Khushhal Khan Khatak MySQL list magic words: sql query database --

RE: JOIN to the same table multiple times

2001-06-09 Thread Bob Hall
ROM department LEFT JOIN sites S1 ON >deptsite1=S1.sitekey LEFT JOIN sites S2 ON deptsite2=S2.sitekey ORDER BY >$order $dir"; What's the $dir for? Does this statement fail in both PHP and the MySQL interface, or only in PHP? You can avoid dealing with aliases entirely if you nor

Re: Nulls appear not be respected

2001-06-06 Thread Bob Hall
PostgreSQL is not compliant and MySQL is. All comparisons with NULL should return UNKNOWN, and a WHERE clause should only return rows where the WHERE condition is TRUE, not FALSE or UNKNOWN. You made a logic error, not a syntax error, and MySQL gave you the correct result. Bob Hall Know thysel

Re: JOIN-problems

2001-06-03 Thread Bob Hall
en, Finland Sir, your query doesn't work on my machine. I either have to GROUP BY orderID, or drop orderID and Name from the SELECT clause. I'm not sure what you're trying to do, so I don't know which to suggest. Bob Hall Know thyself? Absurd

Re: SQL Problem

2001-05-28 Thread Bob Hall
>I have a problem adapting a multiple select to MySQL. >Can someone help me ? > >Here is my request (Oracle format) > >SELECT Tactic.teamCode FROM Tactic WHERE >Tactic.teamCode NOT IN (SELECT Game.teamCode1 FROM Game, Turn WHERE >Game.gameTurn = Turn.code) >AND Tactic.teamCode NOT IN (SELECT Game.

Re: Problems with sum() in a query.

2001-05-24 Thread Bob Hall
your actual tables and actual SELECT statement. Bob Hall >The errors are in the example below not in the code that i'm working >with. the group by would be school_name or school_id otherwise the >query would error and I wouldn't be experiencing the oddities that I >am. >

Re: Problems with sum() in a query.

2001-05-23 Thread Bob Hall
;SELECT >school_name, >(sum(cost_a)+sum(cost_b)+sum(cost_c)) as total >FROM >schools >GROUP BY school Sir, the obvious error is that "school" is not a column in your table. Try grouping by school_id. Bob Hall > >With the desired result > >school_1 125000.00 >

Re: JOIN optimization

2001-05-22 Thread Bob Hall
p and Tipical tables. SELECT B.batID, T.tipical FROM Battery B, tmp_spe TS, tmp_tip TT, Bat_Tip BT, Tipical T WHERE B.batID=TS.batID AND B.batID=TT.batID AND B.batID = BT.batID AND BT.tipID = T.tipID You can join to the Special table in the same way. >Well, I know that'

Re: Q: SQL query problems

2001-05-22 Thread Bob Hall
elect a.eid from a,b where b.gid = and a.eid != b.eid > >but it didn't work out. > > >Any help is welcome! THX > >-- >greetings - WEMMER Alexander <[EMAIL PROTECTED]> Sir, you want to join a and b and return all rows from a, so you want an outer join. SELECT

Re: I have a question

2001-05-21 Thread Bob Hall
php on line 10 > >What do I do? Sir, I take it that the Access database consists of linked tables connected to MySQL tables via ODBC. If so, http://www.iserver.com/support/virtual/mysql/odbc/. Make sure that all MySQL base tables (the tables the Access tables are linked to) have primary

Re: recursive select

2001-05-16 Thread Bob Hall
rns all boss/subordinate pairs: SELECT e1.name, 'is the boss of', e2.name FROM emp e1, emp e2 WHERE e1.id = e2.head_id; To return the boss 2 levels up, use SELECT e1.name, 'is the boss of the boss of', e3.name FROM emp e1, emp e2, emp e3 WHERE e1.id = e2.head

Re: Large scale statistical analysis

2001-05-16 Thread Bob Hall
. Or if 10% of your objects are the subject of 90% of your SELECT statements, you could copy those 10% and their measurements to separate tables and make them available for quick searches, with the full database still available for slower searches. If you haven't done so alrea

Re: EXCEPT statement in MYSQL?

2001-05-15 Thread Bob Hall
RE u2.userid IS NULL; > >G'luck, >Peter Well, that's half the solution. That gives you the difference of user1 and user2, but you also need the difference of user2 and user1. You could run both difference queries and INSERT INTO a temp table. After both insert queries, you

Re: INNER JOIN problem

2001-05-14 Thread Bob Hall
on joined in. Rewrite your FROM clause so that you always have 'INNER JOIN ON'. Or you can replace the INNNER JOINs with commas and move the ON conditions to the WHERE clause. Bob Hall Know thyself? Absurd direction! Bubbles bear no introspec

Re: group by and order by

2001-05-14 Thread Bob Hall
Excel app that creates regression models of programmers' salaries, so god knows when I'll get around to the rewrite. Bob Hall Know thyself? Absurd direction! Bubbles bear no introspection. -Khushhal Khan Khatak MySQL list magic words: sql query database ---

Re: Problem with multi-part keys

2001-05-03 Thread Bob Hall
---+--+-+---+--+ >-+ > > >The bottom line is that I'd like to know if MySQL has a feature that >makes it use a key even if the optimizer doesn't think it'a good one. > >Thanks in advance. > >Regards, >Alex

Re: Agregrate in joined table result

2001-05-03 Thread Bob Hall
2 | 11.00 | 20010501052542 | iwan| 10.00 >| >| 1 | 3 | 11.00 | 20010501052542 | iwan| 10.00 >| >| 1 | 4 | 10.00 | 20010501035956 | iwan| 10.00 >| >+---+-+---++-+-

Re: JOIN query gone awry

2001-05-03 Thread Bob Hall
| | | 0 | | >| dt_label| varchar(6) | YES | | NULL| | >+-+-+--+-+-+---+ >9 rows in set (0.03 sec) > >Dan Huston Sir, the join is working fine. That's the w

Re: Viewing data from the previous row

2001-04-28 Thread Bob Hall
o do this in one select statement > > > is this even possible? > > > > > > Roger Karnouk > > > [EMAIL PROTECTED] Sir, the following works on my machine: SELECT t1.period, t2.sales AS current_sales, Sum(t2.sales) AS cum_total FROM table t1, table

Re: An interesting SELECT problem

2001-04-28 Thread Bob Hall
Hindostan (1) >Hindostan (2) >Hyderabad (1) >Hyderabad (2) >Hyderabad (3) >Marian Watson (28-10-1841) >Marion Watson (08-03-1842) >Marian Watson (08-06-1842) > >Anyone got any ideas? > >Thanks in advance > >Howard Picken >[EMAIL PROTECTED] Bob Hall Know thysel

Re: min () - sql troubles

2001-04-24 Thread Bob Hall
ECT t1.name, t1. distance, Min(t1.speed) FROM table1 t1, table1 t2 WHERE p1.name = p2.name GROUP BY t1.distance HAVING Min(t1.speed) = Min(t2.speed); I haven't run this, but I think it's correct. Bob Hall Know thyself? Absurd dir

Re: SQL Syntax question

2001-04-21 Thread Bob Hall
7; after ON isn't serving any function, other than to confuse MySQL. Secondly, you are trying to join two tables, but your ON clause joins a column from mlsnumber to another column from mlsnumber. If this is not the error mentioned above, then you need to join a column in mlsnumber to

Re: sql: DATETIME - MONTH( select problem)

2001-04-17 Thread Bob Hall
#x27;$current_month') AND >>end >= CURDATE() >> >>Greetings from Sweden >>Jimmy. Sir, try (MONTH(start) >= $current_month AND MONTH(end) <= $current_month) AND end >= CURDATE() The MS Titanic (my wintel machine) just sank again, so I don't have a

Re: Outer and left join definition

2001-04-15 Thread Bob Hall
we solved both problems by using the manual. Dr. Pangloss was right; this really is the best of all possible worlds! (Sorry. It's Sunday morning and I'm feeling really silly.) >any ideas? Never. I'm not allowed, according to my last date. She said "Don't get any id

Re: Outer and left join definition

2001-04-14 Thread Bob Hall
ts, and SQL specifies the result without telling the computer how to produce the result. Your previous experience isn't going to help much in understanding SQL. Bob Hall Know thyself? Absurd direction! Bubbles bear no introspection. -Khushhal Khan Khatak MySQL list magic words: sql query dat

Re: I Need your help

2001-04-12 Thread Bob Hall
gt; ME.Emplacement > > > > > > Thank you. > >Is this an late April Fool's prank? Why not use OR with >the (M.Mot like 'wordX%') phrases? AFAIK there is no >INTERSECT verb in MySQL. Is there? > >David Actually, what he needs is AND. OR would

Re: RE - MYSQL recovery/reliability under powerfail conditions

2001-04-12 Thread Bob Hall
>Hi > >We are evaluating various RDBMS for use on within an airborne server >(Embedded NT4.0) environment. > >This environment does not have reliable power. Aircraft are powered cycled >without regard for delicate OS environments etc. Here in south Arlington, Va., the power also cycles without re

Re: How update 1 of two identical rows.

2001-04-11 Thread Bob Hall
w_table SELECT * FROM old_table GROUP BY Date, DB_amount, CR_amount Delete old_table. Change the name of new_table to old_table. And finally, redesign your table to avoid this kind of embarrassment. You don't want to make a habit of deleting tables in order to overcome design probl

Re: Primary key ID gets messed up after deleting/adding

2001-04-10 Thread Bob Hall
t point out that you can use REPLACE instead of DELETE and INSERT, and it will delete rows where the primary key matches the primary key in the new rows, and then insert the new rows. This will avoid 'holes'. Bob Hall Know thyself? Absurd direction! Bubbles bear no introspection.

Re: Multi-level JOIN query

2001-04-07 Thread Bob Hall
the table definitions and stating which columns are used in the joins. > Does somebody know a good (general) solution for this? Temporary >tables could help, but i deal with lot's of data and I'm afraid it would >be very slow. > > Thanks! > > Christian

Re: date select question (better explained)

2001-04-07 Thread Bob Hall
;TIA > >Llorenc Sole >Maresme Netcom, S.L. Sir, the following retrieves the date for the Sunday of the current week that runs from Sunday to Saturday. Use Data_add() to add 7 and 13 days for next Sunday and the following Saturday. SELECT Date_sub(

Re: Foreign Keys

2001-04-07 Thread Bob Hall
raints that prevent you from inserting or altering values in a foreign key that are not in the referenced key, or deleting the rows in the referenced table that the foreign key refers to. This means that the programmer has to be careful to avoid writing code that creates orphan records, since M

Re: Calculations in a field?

2001-04-04 Thread Bob Hall
>"Bob Hall" <[EMAIL PROTECTED]> wrote: > > Quorting someone else who's name is no longer present: > > >Is there any way to make one field in a table calculate another field. > > >I'm making a DB that calculates commissions. So in the mo

Re: Calculations in a field?

2001-04-03 Thread Bob Hall
lassic example of something that should not be in a table. Calculated fields belong in queries. Bob Hall Know thyself? Absurd direction! Bubbles bear no introspection. -Khushhal Khan Khatak - Before posting, please che

Re: Mysqld crashes with my DELETE query.

2001-04-03 Thread Bob Hall
>Bonjour, > > I have a table created with : > >CREATE TABLE intraday_PAR ( > symbole char(20) NOT NULL default '', > date datetime NOT NULL default '-00-00 00:00:00', Don't use reserved words for column names. > first double(17,5) NOT NULL default '0.0', > high double(

Re: Can't recover a bad corrupeted table...

2001-04-02 Thread Bob Hall
>Hello Bob, first at all thank you for your support. > >Bob Hall wrote: > >>Let me see if I understand you correctly. You created a new table >>(CREATE TABLE?) and you imported data from a file that had nothing >>to do with MySQL (comma or tab delimited file?)

Re: Is updating a subsection of a field possible?

2001-04-02 Thread Bob Hall
Sir, use the Replace function. Regex isn't necessary. >I've got a table with 500+ records in it now... and I need to update just a >small section of one of the fields (an URL) to change a parameter on it... > >I know I'm probably going to be told "NO", but I thought I'd ask before I go >start wri

Re: Can't recover a bad corrupeted table...

2001-03-31 Thread Bob Hall
ATE TABLE statements are creating corrupted tables, then I believe that the server itself is corrupted. If I were in your shoes, I would reinstall, after backing up everything short of the refrigerator. Perhaps someone else can give you better advice. Bob Hall >I tried -r >I tried -o >

Re: Selecting 3 days worth of data with an offset of 5 days fromnow()

2001-03-31 Thread Bob Hall
WHERE datestamp BETWEEN Date_sub(CURRENT_DATE, INTERVAL 5 DAY) AND Date_sub(CURRENT_DATE, INTERVAL 7 DAY) >Hello all > >I am looking for a way to return 3 days worth of data with an offset >of five days (in the past) from today. > >For example, say we had the following dates and today

Re: GROUP BY Question (p2)

2001-03-30 Thread Bob Hall
Sir, try SELECT g1.name, g1.score, g1.id FROM grades g1, grades g2 WHERE g1.name = g2.name GROUP BY g1.name, g1.score HAVING Max(g1.score) = Max(g2.score); Bob Hall >Q: I have the following table "grades". > >++++ >| na

Re: Can't recover a bad corrupeted table...

2001-03-30 Thread Bob Hall
Sir, I looked quickly through the mass of data supplied below, and it looks like you only tried myisamchk with the -r -q option combination. Try it with just -r. If that doesn't work, try it with -o. If that doesn't work, restore from backup. Got backup? Bob Hall >Antoni

  1   2   >