Re: Group by base on latest time field, possible?

2006-08-09 Thread The Nice Spider
not works. it's still show same result. any idea? - Original Message - From: "Quentin Bennett" <[EMAIL PROTECTED]> To: "The Nice Spider" <[EMAIL PROTECTED]>; Sent: Thursday, August 10, 2006 12:43 PM Subject: RE: Group by base on latest time field, possible? > Try > > select thread, sub

Re: cell colors PHP/MySQL

2006-08-09 Thread Ligaya Turmelle
Brian E Boothe wrote: i'm needing assistance in table Cell color thru MySQL i have a project were im listing a projects in a table either Complete / Active / Pending / now im needing these refrances cells to change Color whenver its lists them out on a page, [Complete] = green[Active] =

Adding index -- Need help

2006-08-09 Thread Ratheesh K J
Hello All, Need a suggestion for this: We have tables which have very few number of rows ( less than 600 ). For a long period of time the number of rows are going to remain almost the same. 1) Is it better to index the columns of such tables? 2) There are Joins on this table and then a search

RE: MySQL Replication Binary Logs - How Long to Keep?

2006-08-09 Thread Logan, David (SST - Adelaide)
Hi Warren, I would generally keep the binary log until you have done a full backup. Once that is done, all the transactions that are contained in those logs are now committed and saved in your database backup. All binary logs may be deleted that were created before that backup took place. The mai

RE: Group by base on latest time field, possible?

2006-08-09 Thread Quentin Bennett
Try select thread, subject, max(time) from jos_sb_messages group by thread order by 3 -Original Message- From: The Nice Spider [mailto:[EMAIL PROTECTED] Sent: Thursday, 10 August 2006 4:10 p.m. To: mysql@lists.mysql.com Subject: Group by base on latest time field, possible? I want the

Group by base on latest time field, possible?

2006-08-09 Thread The Nice Spider
I want the group by result take the latest field, but my query result look like get the random row. Here I described: Thread SubjectTime - 5 Re:test 33 1155203794 5 test 33 1155203772 8 test 4

MySQL Replication Binary Logs - How Long to Keep?

2006-08-09 Thread Warren Crigger
I've just recently set up MySQL replication amongst two servers so I'm not too familiar with it. I was cleaning up my /var filesystem and found the binary data below being stored in /var/lib/mysql, taking up 1.5gb. I did a little reading on mysql.org docs. My interpretation was that you can ha

RE: cell colors PHP/MySQL

2006-08-09 Thread Logan, David (SST - Adelaide)
http://www.php.net there are many code examples here. That is a probably more appropriate place for such a question Regards --- ** _/ ** David Logan *** _/ *** ITO Delivery Specialist - Database *

Re: Moving Databases from v4.0.23 to v5.0.24

2006-08-09 Thread Kurt Cypher
Jimmy Guerrero wrote: Hello, REPEAT is indeed a reserved word in MySQL in 5.0 http://dev.mysql.com/doc/refman/5.0/en/reserved-words.html Jimmy Guerrero Sr Product Manager MySQL, Inc Thanks for the quick response. As it turns out, this may be a moot point, as the database in question hasn't

RE: Moving Databases from v4.0.23 to v5.0.24

2006-08-09 Thread Jimmy Guerrero
Hello, REPEAT is indeed a reserved word in MySQL in 5.0 http://dev.mysql.com/doc/refman/5.0/en/reserved-words.html Jimmy Guerrero Sr Product Manager MySQL, Inc > -Original Message- > From: Kurt Cypher [mailto:[EMAIL PROTECTED] > Sent: Wednesday, August 09, 2006 3:13 PM > To: mysql@lis

Moving Databases from v4.0.23 to v5.0.24

2006-08-09 Thread Kurt Cypher
I'm in the process of setting up mysql v5.0.24 on a new server. The server it's replacing is running mysql v4.0.23. I've run mysqldump to get a text file of SQL statements to read into mysql on the new server, and everything seems to work fine until it gets to a particular section of the mysq

Re: forcing leading 0 for numeric fields

2006-08-09 Thread Mark Leith
Jonathan Mangin wrote: - Original Message - From: "George Law" <[EMAIL PROTECTED]> To: "MYSQL General List" Sent: Wednesday, August 09, 2006 3:40 PM Subject: forcing leading 0 for numeric fields Hello All, I have what is probably a simple question. I have a table of phone numbers, b

PHP code for Record Table Cell color

2006-08-09 Thread Brian E Boothe
My Record Display Code : id Projectid Date Company Location Issue Status Notes class="style1"> class="style1">?> class="style1">$row_issues['Projectid']; ?> class="style1">?> class="style1">$row_issues['Company']; ?> class=

Re: forcing leading 0 for numeric fields

2006-08-09 Thread Jonathan Mangin
- Original Message - From: "George Law" <[EMAIL PROTECTED]> To: "MYSQL General List" Sent: Wednesday, August 09, 2006 3:40 PM Subject: forcing leading 0 for numeric fields Hello All, I have what is probably a simple question. I have a table of phone numbers, broken into npa,nxx,stati

forcing leading 0 for numeric fields

2006-08-09 Thread George Law
Hello All, I have what is probably a simple question. I have a table of phone numbers, broken into npa,nxx,station So, 8001231234npa =800 nxx=123 station=1234 Some queries pull data from this table in the format: select * from table where concat(npa,nxx,station)=8001231234 That is

Re: cell colors PHP/MySQL

2006-08-09 Thread Nicholas Vettese
Wouldn't using a 'switch' statement work better? Just please do not ask me to show an example. :) - Original Message - From: "Chris White" <[EMAIL PROTECTED]> To: Sent: Wednesday, August 09, 2006 3:30 PM Subject: Re: cell colors PHP/MySQL On Wednesday 09 August 2006 12:24 pm, Bri

Re: cell colors PHP/MySQL

2006-08-09 Thread Chris White
On Wednesday 09 August 2006 12:24 pm, Brian E Boothe wrote: > i'm needing assistance in table Cell color thru MySQL > i have a project were im listing a projects in a table either Complete > / Active / Pending / now im needing these refrances cells to change > Color whenver its lists them out on

cell colors PHP/MySQL

2006-08-09 Thread Brian E Boothe
i'm needing assistance in table Cell color thru MySQL i have a project were im listing a projects in a table either Complete / Active / Pending / now im needing these refrances cells to change Color whenver its lists them out on a page, [Complete] = green[Active] = Blue[Pending] = ye

Re: how to store quotes in mysql?

2006-08-09 Thread afan
thanks for your response. I'm already working on the php "part" but just wondered how "bad" is to have backslash in front of quotes. thanks. -afan > [EMAIL PROTECTED] wrote: >> hi to all. >> >> battling this problem on several forums and mailing lists, I got >> confused: >> when store string t

Re: how to store quotes in mysql?

2006-08-09 Thread Renato Golin
[EMAIL PROTECTED] wrote: hi to all. battling this problem on several forums and mailing lists, I got confused: when store string that contains quotations (ie afan's "php" shop) in mysql does it have to be stored with backslashes (afan\'s \"php\" shop) or just the way it is? my login's telling me

RE: how to store quotes in mysql?

2006-08-09 Thread Kristen G. Thorson
> -Original Message- > From: Chris White [mailto:[EMAIL PROTECTED] > Sent: Wednesday, August 09, 2006 11:43 AM > To: mysql@lists.mysql.com > Subject: Re: how to store quotes in mysql? > > On Wednesday 09 August 2006 08:37 am, Kristen G. Thorson wrote: > > > > [ stuff here ] > > > > kgt >

Re: Probably naive update question

2006-08-09 Thread Dan Buettner
Agreed, in your case it may be 6 of one, half a dozen of the other. If you were calling a stored procedure to autheticate someone, as in CALL autheticate(username, password) then you could conceivably later alter your entire authentication database model without ever having to touch your applicat

Re: how to store quotes in mysql?

2006-08-09 Thread Chris White
On Wednesday 09 August 2006 08:37 am, Kristen G. Thorson wrote: > > [ stuff here ] > > kgt I'm confused.. did you read my email? Most of what you said doesn't seem to correlate with what I said. Can you quote the specific lines that you're disagreeing with? -- Chris White PHP Programmer/DBacil

RE: how to store quotes in mysql?

2006-08-09 Thread Kristen G. Thorson
> > battling this problem on several forums and mailing lists, I got > confused: > > when store string that contains quotations (ie afan's "php" shop) in > mysql > > does it have to be stored with backslashes (afan\'s \"php\" shop) or > just > > the way it is? my login's telling me the way it is. a

Re: how to store quotes in mysql?

2006-08-09 Thread Chris White
On Wednesday 09 August 2006 07:49 am, [EMAIL PROTECTED] wrote: > hi to all. > > battling this problem on several forums and mailing lists, I got confused: > when store string that contains quotations (ie afan's "php" shop) in mysql > does it have to be stored with backslashes (afan\'s \"php\" shop)

Support for JDBC 4.0?

2006-08-09 Thread Steven Buroff
Does anyone know if there are plans to add support for JDBC 4.0 to the java connector? I'm particularly interested in support for the Connection.createQueryObject(Class cls) method. Thanks. Steve Buroff

how to store quotes in mysql?

2006-08-09 Thread afan
hi to all. battling this problem on several forums and mailing lists, I got confused: when store string that contains quotations (ie afan's "php" shop) in mysql does it have to be stored with backslashes (afan\'s \"php\" shop) or just the way it is? my login's telling me the way it is. am I wrong?

Re: manual on stored procedures and triggers

2006-08-09 Thread Chris White
On Wednesday 09 August 2006 07:27 am, Vittorio ZuccalĂ  wrote: > Hello, > i'm searching for a manual about stored procedures and triggers. > I'm new about this arguments but i want to study them. > Unfortunally, mysql online manual is not rich about examples so, can you > suggest me > some online ma

manual on stored procedures and triggers

2006-08-09 Thread Vittorio ZuccalĂ 
Hello, i'm searching for a manual about stored procedures and triggers. I'm new about this arguments but i want to study them. Unfortunally, mysql online manual is not rich about examples so, can you suggest me some online manuals on stored procedures and triggers? Thank you, Vittorio --

inner outer joins

2006-08-09 Thread Brian E Boothe
hi all Can someone provide a small project using inner and outter joins with querys thanks alot -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

Re: SSH Server for MySQL-5.0.22 Server on WinXP-SP2

2006-08-09 Thread Asif Lodhi
Hi Alan and others, On 8/7/06, Alan Vinh <[EMAIL PROTECTED]> wrote: I would like to know how they got MySql to work with SSL... :) Sorry fellows. I should have gone through the docs first. As it happens, My

Re: Probably naive update question

2006-08-09 Thread Chris Sansom
At 8:49 -0500 9/8/06, Dan Buettner wrote: Chris, I'm not aware of a way to use "ordinary" SQL (insert, update) for this, but the use of a stored procedure would work for you. I've not done it with MySQL (never had a need) but did things like this extensively with Sybase. In rough terms: CREATE

List-Unsubscribe

2006-08-09 Thread [EMAIL PROTECTED]
List-Unsubscribe -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

Re: Probably naive update question

2006-08-09 Thread Dan Buettner
Chris, I'm not aware of a way to use "ordinary" SQL (insert, update) for this, but the use of a stored procedure would work for you. I've not done it with MySQL (never had a need) but did things like this extensively with Sybase. In rough terms: CREATE PROCEDURE sp_chances(IN xxx INT) RETURNS I

Re: MySQL 5.0.24 hard time with VB 3.5.4 and 3.6

2006-08-09 Thread Renato Golin
Abdullah Ibn Hamad Al-Marri wrote: Invalid SQL: INSERT IGNORE INTO session (sessionhash, userid, host, idhash, lastactivity, location, styleid, languageid, loggedin, inforum, inthread, incalendar, badlocation, useragent, bypass, profileupdate)

MySQL 5.0.24 hard time with VB 3.5.4 and 3.6

2006-08-09 Thread Abdullah Ibn Hamad Al-Marri
Hello folks, I'm having hard time with MySQL, I posted this issue t the vb board, and they claimed it's MySQL issue. I have this issue since I upgraded to MySQL 5.0.22 and now it's still I going on since I upgraded to MySQL 5.0.24 too. Database error in vBulletin 3.6.0: Invalid SQL:

Expressions, SQL Aggregate functions & SELECT Performance - index usage

2006-08-09 Thread Asif Lodhi
Hi, I am having to write queries that contain operators such as MOD and DIV in addition to other normal arithmetic operators to add, multiply, divide, etc. I am also using MAX(), MIN() in the same queries. Actually, I am using INSERT ... SELECT MAX() * X ... FROM TABLE idiom to calculate the max

How to set "User" variables (not system/session ones) at database startup

2006-08-09 Thread Asif Lodhi
Hi, I want to set certain _user_ variables, which I will create myself, at the database startup time so that all clients can use the values stored [only one time at the beginning] in those variables instead of computing the same each time in triggers or other code. It's just like the package-lev

Probably naive update question

2006-08-09 Thread Chris Sansom
I have a field representing the chances the user has to get a password right, which is initially 3. I would like, if possible in a single query, to be able to decrement it if it's still > 0 and return the value. Something like this: UPDATE table SET chances = IF(chances > 0, chances - 1, 0) WH

Re: question about the query against to the federated engine tables

2006-08-09 Thread Paul McCullagh
As a storage engine, federated does not have the information as to exactly which columns have been selected. This information is simply not passed down to the engine. However, if there is index support for a query then MySQL will indicate to the engine if it is only interested in the columns o