Oct 29, 2004 #1 Johnny42 Technical User Jul 13, 2004 127 CA SELECT DISTINCT(item) CONCAT(item,' - ',itemno) FROM ICITEM can this work ?
Oct 29, 2004 #2 r937 Technical User Jun 30, 2002 8,847 CA probably not that's mysql, right? do you realize there is a forum for mysql? see forum436 DISTINCT is not a function it is a keyword which ensures that only distinct rows are returned by the query in your case, it will return one row for every distinct combination of item and itemno rudy http://r937.com/ SQL Consulting Upvote 0 Downvote
probably not that's mysql, right? do you realize there is a forum for mysql? see forum436 DISTINCT is not a function it is a keyword which ensures that only distinct rows are returned by the query in your case, it will return one row for every distinct combination of item and itemno rudy http://r937.com/ SQL Consulting
Oct 29, 2004 Thread starter #3 Johnny42 Technical User Jul 13, 2004 127 CA using pervasive, eg: ID Description a blah a blah c boy d girl s dog result: a - blah c - boy d - girl s - dog Upvote 0 Downvote
using pervasive, eg: ID Description a blah a blah c boy d girl s dog result: a - blah c - boy d - girl s - dog
Oct 29, 2004 #4 dnoeth Instructor Oct 16, 2002 545 DE SELECT DISTINCT CONCAT(item,' - ',itemno) FROM ICITEM Dieter Upvote 0 Downvote
Oct 29, 2004 Thread starter #5 Johnny42 Technical User Jul 13, 2004 127 CA tried SELECT DISTINCT CONCAT(item,' - ',itemno) FROM ICITEM got this : ODBC Error: SQLSTATE = 37000, Native error code = 0 Invalid parameter count for scalar function CONCAT. Upvote 0 Downvote
tried SELECT DISTINCT CONCAT(item,' - ',itemno) FROM ICITEM got this : ODBC Error: SQLSTATE = 37000, Native error code = 0 Invalid parameter count for scalar function CONCAT.
Oct 29, 2004 #6 PHV MIS Nov 8, 2002 53,708 FR You may try this : SELECT DISTINCT item || ' - ' || itemno FROM ICITEM Hope This Helps, PH. Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244 Upvote 0 Downvote
You may try this : SELECT DISTINCT item || ' - ' || itemno FROM ICITEM Hope This Helps, PH. Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
Oct 29, 2004 #7 r937 Technical User Jun 30, 2002 8,847 CA according to the pervasive documentation (and this was the first time i've ever even looked into it), the CONACT function takes two arguments so i would try SELECT DISTINCT CONCAT(CONCAT(item,'-'),itemno) ... rudy http://r937.com/ SQL Consulting Upvote 0 Downvote
according to the pervasive documentation (and this was the first time i've ever even looked into it), the CONACT function takes two arguments so i would try SELECT DISTINCT CONCAT(CONCAT(item,'-'),itemno) ... rudy http://r937.com/ SQL Consulting