Speaking of Silly Questions

2001-04-06 Thread Oson, Chris M.
Good Day All, I seem to be stuck in a fog. I know the answer is probably easy Let's say I have a query: SELECT * FROM myTable; and it's stored in a file: getData Then I can do something like this... % mysql -A -uuserID -ppassword databaseName < getData and I'll see output. That's fine B

RE: Full Text Search Question

2001-04-03 Thread Oson, Chris M.
nfo http://www.mysql.com/doc/M/y/MySQL_full-text_search.html On 4/3/01 11:07 AM, "Oson, Chris M." <[EMAIL PROTECTED]> wrote: > Hello, > > I have a site that I'm trying to implement a search engine on existing and > archived news stories on a medium text dataty

Full Text Search Question

2001-04-03 Thread Oson, Chris M.
Hello, I have a site that I'm trying to implement a search engine on existing and archived news stories on a medium text datatype in a database. I read the documentation and got it running, but unless I missed something it's not doing what I want it to do. For example, if I put in the keyword

RE: Time function

2001-04-02 Thread Oson, Chris M.
rekha, mysql> select date_format(dateEntered, "%m-%d-%Y %H:%I") as dateEntered, -> date_format(date_add(dateEntered, interval 2 hour), "%m-%d-%Y %H:%I") as '2 Hours Later' -> from newsStories where storyID = 1122; +--+--+ | dateEntered | 2 Hours Later

RE: Complex SQL Query

2001-03-28 Thread Oson, Chris M.
Aaron, Are you inserting both values at once? Or inserting the startdate first, then updating the stopdate later. You may or may not be able to do this in one query. To determine how much time is being spent between Midnight and 6am... select if ( time_to_sec(time_format(dateMod

RE: MySQL vs MS-SQL performance

2001-03-27 Thread Oson, Chris M.
Mike, Excuse me if I'm wrong, but isn't using persistent connections more server resource intensive? I'm trying to optimize the database on a heavy site, and I decided not to use persistent connections. Chris -Original Message- From: Michael Betts [mailto:[EMAIL PROTECTED]] Sent: Tue

RE: RTFM (was: *sigh* Re: Is it a bug? )

2001-03-26 Thread Oson, Chris M.
Cal, >> >> I would love to see this list split into 2 lists. MySQL-Newbies and >> MySQL-non-newbies. Non-newbies would be either an invitation-only list or >> you have to pass a test to get in. (The test would contain questions that >> are all in the manual, we don't care if you know, we care if

RE: Re[2]: MySQL vs Microsoft SQL

2001-03-26 Thread Oson, Chris M.
James, >> Gotta say that this is a bad reason to choose one product vs. >> another... because it lacks a GUI to build queries? Undertanding SQL >> is all well and good, but I can tell you that I would give anything to >> have a query builder that works like the one for MS SQL server. You may >>

RE: MySQL vs Microsoft SQL

2001-03-23 Thread Oson, Chris M.
For what it's worth, here's my $0.02... --> Is there something that you can do with MS SQL and you can not do with MySQL? MSSQL - has support for triggers, stored procedures, views, XML, and transactions. I would mention subqueries, but subqueries are on the way with mySQL. MySQL -

RE: replace qeustion

2001-03-21 Thread Oson, Chris M.
UPDATE Table_1 SET C = 20 WHERE A = 10 AND B = 18 you might want to read a basic SQL book before asking this type of question HTH, christopher oson -Original Message- From: soon chee keong [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 21, 2001 6:59 AM To: [EMAIL PROTECTED] Subj

RE: selecting null values

2001-03-21 Thread Oson, Chris M.
Peter, try SELECT * FROM table WHERE title IS NULL LIMIT 1; HTH, Christopher Oson -Original Message- From: Peter Szekszardi [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 21, 2001 5:36 AM To: [EMAIL PROTECTED] Subject: selecting null values Hi, I have a database which has a text

Optimizing JOINS -- related matter

2001-03-08 Thread Oson, Chris M.
Hello, On a related matter, do the various JOIN's (LEFT, INNER, and OUTER) use a temp file when processing? Table pollResponses: +-+---+--+-+-++ | Field | Type | Null | Key | Default | Extra | +-

RE: more date problems

2001-03-01 Thread Oson, Chris M.
Why can't you do something along the lines of: select count(*) from pollResults where dayofyear(now()) = dayofyear(dateEntered) and year(dateEntered) = 2001; -Original Message- From: Atle Veka [mailto:[EMAIL PROTECTED]] Sent: Thursday, March 01, 2001 5:51 PM To: Daren Cotter Cc: Quentin

Hopefully Easy SQL Join Question

2001-02-22 Thread Oson, Chris M.
Good Day All I have two tables... Table 1 --- MSRSectionID ContractID Heading 1 1107 Technical Progress: 7107 Technical Problems: 13 107 Administrative Acti

RE: Printed MySQL manual

2001-02-21 Thread Oson, Chris M.
Paul, I'm not sure if this is in the manual, but do you have some sort of general timeframe when mySQL 4.0 will be available for the masses? Christopher Oson [Big Fan Of Your mySQL Book] -Original Message- From: Paul DuBois [mailto:[EMAIL PROTECTED]] Sent: Wednesday, February 21, 2001

RE: Percent?

2001-02-15 Thread Oson, Chris M.
How about... mysql> select concat(50/1432, '%') as percentage; ++ | percentage | ++ | 0.03% | ++ 1 row in set (0.00 sec) mysql> select concat(1324/4.14, '%') as percentage; ++ | percentage | ++ | 319.8068% | ++ 1 row i

RE: Please HELP easy ANSWER

2001-02-09 Thread Oson, Chris M.
CREATE TABLE custinfo ( id tinyint(4) DEFAULT '0' NOT NULL AUTO_INCREMENT, ); 1. Your primary key is on a TINYINT field. If TINYINT is SIGNED, possible values are... -127 to +127 If TINYINT is UNSIGNED possible values are.

RE: Boolean Datatype

2001-02-06 Thread Oson, Chris M.
Maybe, but you could define a constant.. CONST TRUE "T" CONST FALSE "F" INSERT INTO logInfo2 (logID, ipAddress, boolVars) VALUES (null, '192.192.192.192', TRUE) -Original Message- From: Russ Davies [mailto:[EMAIL PROTECTED]] Sent: Tuesday, February 06, 2

RE: Boolean Datatype

2001-02-06 Thread Oson, Chris M.
Why not try using ENUM? http://www.mysql.com/doc/E/N/ENUM.html You could setup your table like this: CREATE TABLE logInfo2 ( logID INT NOT NULL UNIQUE, ipAddress VARCHAR(20) NOT NULL DEFAULT 'None', boolVarsENUM ('T', 'F') DEFAULT 'F' ) SELECT ipAddress FROM

RE: Select a range from 0-9 or A-z

2001-02-06 Thread Oson, Chris M.
Try: select whatever from whatever where field like '[0-9]%' http://www.mysql.com/doc/P/a/Pattern_matching.html -Original Message- From: Ung, Seng [mailto:[EMAIL PROTECTED]] Sent: Tuesday, February 06, 2001 9:03 AM To: [EMAIL PROTECTED] Subject: Select a range from 0-9 or A-z hi: Her

RE: Are all SQL-databases based on the same query-language?

2001-01-31 Thread Oson, Chris M.
SQL is a language that is based on standards that are modified every so often. So, yes, in general there are SQL statements that you put together will work with Access, MSSQL, Informix, DB2, and Oracle, etc. But *THE* key issue is that each DBMS application has it's own hooks that are nativ

RE: Please help!

2001-01-31 Thread Oson, Chris M.
At the risk of getting flamed for something that may or may not be in the manual, at the beginning of Paul's email % perror 127 127 = Record-file is crashed When I did a man perror from Solaris 2.6, it says that perror returns the last system error. I guess what's confusing me is that an erro

RE: Selecting * from 2 tables

2001-01-26 Thread Oson, Chris M.
assuming that each table only has one element, you could do a select * from 2 table. If you don't and you need to combine everything, then you're trying to do a UNION. mySQL doesn't support UNION's yet. one way to do a union is to create a temporary table then use two queries to fill the tempo

RE: [PHP-DB] substring equiv in PHP

2001-01-24 Thread Oson, Chris M.
did you try substr? http://www.php.net/manual/en/function.strstr.php -Original Message- From: Lucas Rockwell [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 24, 2001 1:14 PM To: PHPDB Subject: [PHP-DB] substring equiv in PHP Hello, I am wondering what PHP's equilivent of the SQL s

Full-Text Query

2001-01-22 Thread Oson, Chris M.
Good Day All, This will work... mysql> SELECT storyID, title, summary, MATCH summary AGAINST (LCASE('news')) AS probability -> FROM newsStories WHERE MATCH summary AGAINST (LCASE('news')) > 0 LIMIT 0, 5; But this will not... mysql> SELECT COUNT(*), MATCH summary AGAINST (LCASE('news')) AS

RE: [PHP-DB] Date function.

2001-01-19 Thread Oson, Chris M.
mysql> select name from tableName -> where month(birthDate) = 7; -Original Message- From: Sharif Islam [mailto:[EMAIL PROTECTED]] Sent: Friday, January 19, 2001 8:56 AM To: [EMAIL PROTECTED] Subject: [PHP-DB] Date function. This is a simple mysql question i am having problme with.

RE: Creating the database

2001-01-17 Thread Oson, Chris M.
You need to flush privileges after you add a new user. FYI... Paul DuBois' mySQL book covers this in great detail and should be considered the Bible for mySQL Check the manual for flushing priliges if you don't have available access to this book... -Original Message- From: Carlos Corz

RE: sub queries

2001-01-16 Thread Oson, Chris M.
You can get around subqueries by using JOIN's. mySQL may not have all the bells and whistles that some other db applications may have, but more often than not, there is a way to get around it. Paul DuBois covers this in his mySQL book very well. -Original Message- From: Mark Marshall [

RE: What type of a Column for "True" or "False"?

2001-01-16 Thread Oson, Chris M.
Why not use ENUM? create table test bool ENUM('t', 'f') default 't' not null, val1 char(15), val2 int ... ... It will "map" T to a 0 and F to 1. It's nearly identical to what you're doing, but it may seem more intuitive to some. Cheers, Chris Oson -Original Messa

Lazy

2001-01-10 Thread Oson, Chris M.
Is there any way that the list in question can be broken up into two lists? For example, ASP has two (actually, alot more) lists called ASPFreeForAll, and ASPAdvanced which cater to the various knowledge levels of each list's participants. The ASPAdvanced list is moderated by the person who cre