Search
 
SCRIPT & CODE EXAMPLE
 

SQL

comma seperated join mssql

select SM.ROLLNO,
       SM.NAME, 
       SM.ADDRESS,
       (
       select ','+CM.CourseName
       from dbo.CourseMaster as CM
       where ','+SM.Course+',' like '%,'+CM.CourseId+',%'
       for xml path(''), type
       ).value('substring(text()[1], 2)', 'varchar(max)') as Course
from dbo.StudentMaster as SM;
Comment

PREVIOUS NEXT
Code Example
Sql :: postgres audit table 
Sql :: sql orcale i forgot what my name & password was 
Sql :: mariadb set vertical output format 
Sql :: divide database into structured tables 
Sql :: c# execute transact sql 
Sql :: create bakupd database sqlserver 
Sql :: alter check command 
Sql :: mysql clone table with data and add attribute 
Sql :: sql save select into list 
Sql :: How to Alter column in SQL Server - NAYCode.com 
Sql :: pastashoppen 
Sql :: call function sql oracle with output put line 
Sql :: how to connect pgadmin with excel 
Sql :: cross apply top for each row t1 
Sql :: How to write triggers to increment or decrement the number of employees 
Sql :: SQL ORDER BY With Multiple Columns 
Sql :: sql find gaps in date ranges 
Sql :: closure in sql 
Sql :: Pattern matching alternative sql 
Sql :: sql $ symbol usage 
Sql :: multiple select into sql oracle 
Sql :: how to update the multiple rows in sql 
Sql :: Perfect solution if some records deleted for LAST_ID 
Sql :: org.h2.jdbc.JdbcSQLSyntaxErrorException: Syntax error in SQL statement 
Sql :: error access to system table innodb is rejected 
Sql :: how to know if table in rigt or left in sql 
Sql :: float in sql 
Sql :: how to select multiple columns in sql 
Sql :: django.core.exceptions.ImproperlyConfigured: mysqlclient 1.3.13 or newer is required; you have 0.8.0. 
Sql :: reseed sql identity 
ADD CONTENT
Topic
Content
Source link
Name
3+8 =