Re: order by, group by

2001-11-13 Thread Christan Andersson
> > > 1'en''blue circle''this is a blue ' > > > 1'no''bla cirkel' 'dette er ei bla cirkel' > > > 2'en''green leaf' 'this is a green leaf from a tree' > > > 2'sv''grönt löv' 'detta är ett grönt löv från ett träd' > > > > > > if the language priority

Re: order by, group by

2001-11-13 Thread DL Neil
> > let say that the table (id,language,name,description) where id,language is > > the primary key so that 1 id can have several languages > > > > the data in the database looks like this > > > > 1'en''blue circle''this is a blue ' > > 1'no''bla cirkel' 'dette er ei bla ci

Re: order by, group by

2001-11-13 Thread Shankar Unni
Christan Andersson wrote: > what I really want is the following.. > let say that the table (id,language,name,description) where id,language is > the primary key so that 1 id can have several languages > > the data in the database looks like this > > 1'en''blue circle''this is a blu

Re: order by, group by

2001-11-13 Thread Christan Andersson
> >will return all articles even if they do not have an english translation, > >BUT here is the problem.. which language will be the one I recieve? > >Svedish? english? French? > > > There seems to be a little confusion here regarding grouping and > ordering. What do you mean by "the one I receive

Re: order by, group by

2001-11-13 Thread Shankar Unni
Christan Andersson wrote: >lets say that I have this table.. articles(id,language,name,description) >what I would like to do is retrieve 1 row per unique id in the chosen >language > >select * from articles where language='en'; > >that is quite simple, unfourtunally, not all articles have the de

Re: order by, group by

2001-11-13 Thread Christian Andersson
> > Im trying to make a "data" system that is language-independent, ie the data > > stored can have any language therefore the same information is stored > > several times but with different values (depending on language) > > =Is this correct? > "data" ~ news reports/magazine articles > "article"

Re: order by, group by

2001-11-13 Thread DL Neil
this loop for every table that is language dependent) > and I'm not to stupid... the language-specific tables holds just that > language specific data, (and the keys) the ordinary data that is not > language specific, I have in a seperate table.. > I hope this explains better what I wan

Re: order by, group by

2001-11-13 Thread Benjamin Pflugmann
Hi. If I understand correctly what you want to archieve, this is covered in the tutorial part of the manual: http://www.mysql.com/doc/e/x/example-Maximum-column-group-row.html and the short answer is "no, only with temporary tables, until sub-queries are implemented". Bye, Benjamin.

Re: order by, group by

2001-11-13 Thread Christian Andersson
t one.. ( do not have any other database to test with, so I cannot try it out) but thanks anyway.. - Original Message - From: "Carl Troein" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Tuesday, November 13, 2001 1:23 PM Subject: Re: order by, group by >

Re: order by, group by

2001-11-13 Thread Christan Andersson
not language specific, I have in a seperate table.. I hope this explains better what I want to do, and I would appreciate ANY ideas on how to do this better.. /Christian Andersson - Original Message - From: "M. A. Alves" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> S

Re: order by, group by

2001-11-13 Thread M. A. Alves
On Tue, 13 Nov 2001, Carl Troein wrote: > As far as I understood the original post, the question was if > there's a way to get MySQL to perform an ORDER BY prior to > doing the GROUP BY. Yes it was but "prior to" does not make much sense and that is why I asked the original poster for an example.

Re: order by, group by

2001-11-13 Thread Carl Troein
DL Neil writes: > "All keywords used must be given in exactly the order shown above. For example, a >HAVING clause must come after > any GROUP BY clause and before any ORDER BY clause." As far as I understood the original post, the question was if there's a way to get MySQL to perform an ORDER

Re: order by, group by

2001-11-13 Thread M. A. Alves
mysql On Mon, 12 Nov 2001, Christian Andersson wrote: > Is it possible in myslq to do an order by before an group by? For me it is not clear why would you want to do that. Can you give an example? -- , M A R I O data miner, LIACC, room 221 tel 351+226078830, ext 121 A M A D O Rua Cam

Re: order by, group by

2001-11-13 Thread DL Neil
> Looks like no one knows the answer to this question... =or we don't want to state the obvious/seem rude when saying "RTFM" 7.19 SELECT Syntax "All keywords used must be given in exactly the order shown above. For example, a HAVING clause must come after any GROUP BY clause and before any ORDER

Re: order by, group by

2001-11-13 Thread Christan Andersson
Looks like no one knows the answer to this question... - Original Message - From: "Christian Andersson" <[EMAIL PROTECTED]> To: "MySQL Mailing list" <[EMAIL PROTECTED]> Sent: Monday, November 12, 2001 10:30 PM Subject: order by, group by > I asked before, but got no answer, so I ask aga

Please help!!!!!!Re: order by...group by...complicated query

2001-09-01 Thread hassan el forkani
>hi, > >i am trying to build a message board in php with mysql as back end; > >what i want to do is to query the database in a certain way that the >result is returned in the correct order for php to display the discussion >thread properly > >here is my table structure: > >mysql> show fields fr