Concatenation Operator

murray83

Games Collector
Local time
Today, 23:21
Joined
Mar 31, 2017
Messages
827
Below code is almost perfect but for just one addition where i have it SUBSTR i want it then to CONCANT the numbers into one nice string

have tried google and after reading a few articles tried adding the CONCANT but it just went into error so any help would be great cheers :cool:

Code:
SELECT DISTINCT

Container_Id, From_Loc_Id, Final_Loc_Id, Priority, Task_Type, SUBSTR(Consignment,11,4)

FROM 

Move_Task

WHERE

-- Task Type T = Marshall

Task_Type = 'T' AND Final_Loc_Id LIKE 'HRS%'

ORDER BY Priority DESC
 

Attachments

  • exp.png
    exp.png
    5.3 KB · Views: 59
there is no Substr() function in VBA (maybe foxpro or Dbase have).
its equivalent is Mid() in vba.
 
sorry. its transact sql.
its not Concant, should be Concat(). this function is available starting with mssql 2012.
 

Users who are viewing this thread

Back
Top Bottom