hosted application data design

2004-09-01 Thread Justin French
ng I might be missing something in regards to primary keys... Can a primary key (or unique key) be established on two columns (eg primary key = client_id + post id)? Can an auto-increment column only increment in relation to the client id? Or am I expecting *way* too much out of MySQL and rela

multiple table query

2004-08-30 Thread Justin French
more complex query -- can any one lend a hand? My guess is maybe something like SELECT article.title, article.user_id, user.username FROM article, user WHERE user.id = article.user_id --- Justin French http://indent.com.au -- MySQL General Mailing List For list archives: http://lists.mysql.com

NOT NULL

2004-08-08 Thread Justin French
Can someone give me a quick/clear explanation about why you would create a table with columns of NULL / NOT NULL? I clicked around the MySQL manual last night I *think* I know what's what, but it'd be great to read one clear paragraph that summarises it all. --- Justin F

data design question

2004-07-19 Thread Justin French
nce loss by having all 20,000 articles in one table, with a indexed `siteID` column identifying which site each article belongs to, as opposed to 100 tables (one for each site) holding only their own data?? Should I worry at 40,000? 100,000? Or will the indexing of the siteID keep everything extens

Hierarchical data design

2004-03-16 Thread Justin French
ta model is right for this application. The only catch is I have no idea where to look next. Hours of Googling has returned very little. Any hints on where to look next would be great. --- Justin French http://indent.com.au -- MySQL General Mailing List For list archives: http://lists.mysql.com

Re: Newbie question about stats

2004-02-10 Thread Justin French
On Wednesday, February 11, 2004, at 03:29 PM, Keith Warren wrote: I want to be able to track how many times any particular record is returned from a search, and I have two ideas about how to do this. But because I have little experience with MySQL, I may be totally off > base. This database is

VARCHAR 255 versus TINYTEXT

2004-01-12 Thread Justin French
Hi, Can someone please calrify when I would use VARCHAR 255, and when I would use TINYTEXT (which also has a length of 255)? Thanks, Justin French -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

advice on change of data design

2003-09-04 Thread Justin French
n the user changes his/her email address, it won't affect their primary keys, scattered across many tables... it will just affect how they log in. Any comments? Justin French -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

help deciding on data types

2003-04-04 Thread Justin French
Hi all, I'm currently logging page requests with the following table: CREATE TABLE counters_hits ( pid tinyint(3) unsigned NOT NULL default '0', stamp varchar(30) NOT NULL default '' ) TYPE=MyISAM; In other words, for ever page hit on my site, I'm recording the unix timestamp & page ID. Thi

loading data from a back up file

2003-04-02 Thread Justin French
I have a 2.7meg dump of SQL created by phpMyAdmin [1], however when I try to import this data back into mysql through phpMyAdmin, it times out (understandably), so I guess I need to do this from the command line, but have no idea how to go about this AT ALL... can anyone point me in the right direc

RAND() isn't :)

2003-02-27 Thread Justin French
Hi all, On my LAN server (FreeBSD, MySQL 3.32) the following query works fine, and seems to return 2 random rows from the table: SELECT * FROM disc ORDER BY RAND() LIMIT 2 However, when I upload the scripts to the live server (Linux, MySQL 3.32), the results are VERY un-random -- only very occas

help with query

2003-01-23 Thread Justin French
sorry for the ambiguos subject, but not sure what terms to use! I have four (relevant) tables: category partner(pid,pname,etc) service(sid,sname,cid) sid2pid(sid,pid) This works fine, listing all services available within a category: SELECT service.sid,service.sname FROM service WHERE cid='3'

nested queries

2003-01-23 Thread Justin French
Hi, I'm trying to dig a bit deeper into mysql queries... I've come across an application that i'm building which requires (it would seem on the surface) many queries, do to the relational nature of the data. The actual app is way too complex to explain, but I've come up with a reasonably simple e

relational tables query help

2003-01-20 Thread Justin French
ice_rel.sid And I'm getting "Unknown table 'partners' in field list". Any advice warmly received :) Justin French sql,query - Before posting, please check: http://www.mysql.com/manual

locking + load

2003-01-15 Thread Justin French
Hi all, I'm encountering some problems with code on a PHP/MySQL driven site. It's a long story to document, but the end result is that I have to look at my entire code library looking for problems :) One area that I'm seeking further knowledge about is how MySQL behaves under load. I have a sm

locking + load?

2003-01-15 Thread Justin French
Hi all, I'm encountering some problems with code on a PHP/MySQL driven site. It's a long story to document, but the end result is that I have to look at my entire code library looking for problems :) One area that I'm seeking further knowledge about is how MySQL behaves under load. I have a sm

Re: total idiot

2002-12-09 Thread Justin French
IL PROTECTED]) wrote: > There is data in the logs. So you mite be able you use them to recreate the > data? > Simon > > -Original Message- > From: Justin French [mailto:[EMAIL PROTECTED]] > Sent: 09 December 2002 09:05 > To: MySQL > Subject: total idiot > >

total idiot

2002-12-09 Thread Justin French
ut their own back-up, but i'm assuming the worst. Does MySQL "remember" anything itself? Does it have any back-up mechanisms? Justin French http://Indent.com.au Web Development & Graphic Design

help with picking the right index(s)

2002-12-02 Thread Justin French
out if the row already exists b) quickly inserting the row if it doesn't I'm not worried about how long reporting the stats takes. Or am I worried about nothing? sql,query Justin French http://Indent.com.au Web Deve

Re: [PHP] copying tables

2002-11-20 Thread Justin French
gt; multiple times and need the same information to start off with. Justin French http://Indent.com.au Web Developent & Graphic Design - Before posting, please check:

help with a query accross multiple tables (pt 2)

2002-11-20 Thread Justin French
, or links to a magical page that enables me to find out for myself :) Thanks, Justin French http://Indent.com.au Web Developent & Graphic Design - Before posting, please chec

Re: Inserting values from PHP.

2002-11-19 Thread Justin French
TED]> > To unsubscribe, e-mail > <[EMAIL PROTECTED]> > Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php > > Justin French http://Indent.com.au Web Developent & Graphic Design -

Re: help with selecting accross multiple, related tables...

2002-11-19 Thread Justin French
The aim being to show a list of all threads that have been active (posted, > and/or replied to) within a certain timeframe. > > > Getting the tiemstamp for "last week" is easy in PHP, more trying to figure > out the logic of the query... > > >

help with selecting accross multiple, related tables...

2002-11-19 Thread Justin French
"last week" is easy in PHP, more trying to figure out the logic of the query... Many thanks, Justin French http://Indent.com.au Web Developent & Graphic Design - Before po

Re: Good MySQL Webhosting Company

2002-09-11 Thread Justin French
This get asked every couple of days. Check the archives. FWIW, I host with Experhost.com Justin on 12/09/02 3:34 PM, [EMAIL PROTECTED] ([EMAIL PROTECTED]) wrote: > Hello All, > Can any one suggest a good company to host a MySQL+PHP website ? > > Thanks > > --

Re: Goodday

2002-09-10 Thread Justin French
I think the only filters on this list are that it must contain 'sql' or 'query'... The message starts with 'Attn: mysql', so I guess it got thru. Justin on 10/09/02 11:55 PM, Clive Smart ([EMAIL PROTECTED]) wrote: > How did this get past the filters? > > Ocita Gabriel wrote: >> Attn: mysq

Re: best way to search a col with csv's?

2002-09-09 Thread Justin French
results, not be ignored just because he's popular :) I'd rather strip out some noise words like 'a' & 'the' BEFORE using the search term in a query, in order to maintain control. Any ideas? Justin on 09/09/02 4:35 PM, Justin French ([EMAIL PROTECTED]) wrote: >

best way to search a col with csv's?

2002-09-08 Thread Justin French
on "Smith"). I'd like it all to be case insensitive. Many thanks in advance. Justin French - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/

getting the id each side of a given id

2002-09-03 Thread Justin French
hi all, given a certain id # (eg 4), how would i query the value either side of it (usually 3 and 5). In theory, yes, it'd be 3 + 5, but in the case of the following table: 1 4 5 it'd be 1 + 5, and this: 3 4 7 it'd be 3 + 7. Even more interesting would be obtaining some sort of an error whe

JOIN?

2002-09-01 Thread Justin French
more complex in the WHERE, or am I way off track? Any links to articles, FAQs, etc etc, or query snippets would be greatly appreciated... I'm using MySQL in conjunction with PHP if that helps... Justin French - Befo

windows installation -- users

2002-05-12 Thread Justin French
Hi all, I'm a total newbie when it comes to windows set-ups... I've managed to get Apache and PHP4 running nicely on an old Pentium laptop running Win95, and have managed to install MySQL with ease. However, I'm not all that sure how to set up users (or even what the default user "root"'s passwo