Re: Problem With Join Syntax

2006-06-14 Thread Albert Padley
.mysql.com From: Chris White <[EMAIL PROTECTED]> Subject: Re: Problem With Join Syntax On Wednesday 14 June 2006 10:55 am, Albert Padley wrote: A typical set of data looks like this: id | inputfieldid | userid | value 1 1 2 John 2 2 2 Sm

Re: Problem With Join Syntax

2006-06-14 Thread Keith Roberts
2006, Chris White wrote: > To: mysql@lists.mysql.com > From: Chris White <[EMAIL PROTECTED]> > Subject: Re: Problem With Join Syntax > > On Wednesday 14 June 2006 10:55 am, Albert Padley wrote: > > A typical set of data looks like this: > > > > id | inputfi

Re: Problem With Join Syntax

2006-06-14 Thread Albert Padley
Dan, Thanks. I'll take a further look at GROUP_CONCAT. Albert On Jun 14, 2006, at 1:16 PM, Dan Buettner wrote: Albert, MySQL's GROUP_CONCAT function might work for you: http://dev.mysql.com/doc/refman/5.0/en/group-by-functions.html In your case something like this: SELECT userid, GROUP_CON

Re: Problem With Join Syntax

2006-06-14 Thread Dan Buettner
Albert, MySQL's GROUP_CONCAT function might work for you: http://dev.mysql.com/doc/refman/5.0/en/group-by-functions.html In your case something like this: SELECT userid, GROUP_CONCAT(value) GROUP BY userid HTH, Dan Albert Padley wrote: I have the following table schema in MySQL 4.1.18 which I

Re: Problem With Join Syntax

2006-06-14 Thread Chris White
On Wednesday 14 June 2006 10:55 am, Albert Padley wrote: > A typical set of data looks like this: > > id | inputfieldid | userid | value > 1 1 2 John > 2 2 2 Smith > 3 3 2 [EMAIL PROTECTED] > > I am trying to come up with a query

Problem With Join Syntax

2006-06-14 Thread Albert Padley
I have the following table schema in MySQL 4.1.18 which I didn't create, but have to work with. CREATE TABLE `phplog_userinput` ( `id` int(11) NOT NULL auto_increment, `inputfieldid` int(11) NOT NULL default '0', `userid` int(11) NOT NULL default '0', `value` varchar(150) NOT NULL defau

RE: Problem with join syntax

2002-05-23 Thread Roger Baklund
* andy > thanx for your help. Anyhow this statement does not return the wanted > fields. > > I would like to return the website and the signature of the > user, but only > if those values are available. There might be none of them available, but > maybe 1 or even both. > > this query: > SELECT >

Re: Problem with join syntax

2002-05-23 Thread andy
hey are there. Thanx for your help, Andy - Original Message - From: "Roger Baklund" <[EMAIL PROTECTED]> To: "mysql" <[EMAIL PROTECTED]> Cc: "andy" <[EMAIL PROTECTED]> Sent: Monday, May 20, 2002 3:56 PM Subject: Re: Problem with join syntax >

Re: Problem with join syntax

2002-05-20 Thread Roger Baklund
* andy <[EMAIL PROTECTED]> > thank you roger for your reply. > > I am wondering how to form the stmt if I do already know the user_id > > I tryed this, but it does not work though. Anyhow there has to be a from > field. But on which table? > > SELECT w.website, c.comment >LEFT JOIN user_websit

Problem with join syntax

2002-05-18 Thread andy
Hi there, I have some trouble with the syntax of join query and some perfomance isues. I did split my data due to the rules of normalisation. So there is a website table and a comment table and I would like to find out if the user with the id '10215' has a stored comment or website. Here is my