Search
 
SCRIPT & CODE EXAMPLE
 

SQL

how to ignore the data based on specific keywords?

with data(No,Name ) as(
select 1,   'kumar unknow raja' union all
select 2,   'kumarunknowraja sameple' union all
select 3,   'kumartradraja testing' union all
select 4,   'kumar trad raja' union all
select 5,   'trad' union all
select 6,   'unknow' 
),
param (name) as (
select 'unknow' union all
select 'trad'
),
data2 (No,Name ) as(
select No,data.Name from data
join param on data.name = param.name 
union all
select No,data.Name from data
join param on data.name like ('% ' + param.name + '%')
union all
select No,data.Name from data
join param on data.name like ('%' + param.name + ' %')
)
select distinct * from data2
order by No
Comment

PREVIOUS NEXT
Code Example
Sql :: http://localhost:9200/_cluster/allocation/explain 
Sql :: call object contructor and call methods of object 
Sql :: how to make full text search dynamic in mysql 
Sql :: normal mysql large import 
Sql :: sql set devault value with existing column 
Sql :: list column names of multiple tables psql 
Sql :: SQL Equal to Operator (=) 
Sql :: PBI TO SQL 
Sql :: flask sqlalchemy decimal 
Sql :: sql create tablwe 
Sql :: error database connection 
Sql :: dasebase_url-postgres for windows 
Sql :: configurasi database whmcs 
Sql :: how to get data from 2 database 
Sql :: visual c++ 2019 redistributable package mysql workbench 
Sql :: sqlite escape single quote 
Sql :: closure in sql 
Sql :: rollback to in sql 
Sql :: which is the order of precedence among following operator IN OUT AND OR in sql 
Sql :: mysql vs sql server performance benchmark 
Sql :: sql select column name like from multiple tables 
Sql :: postgres grep entire database 
Sql :: ring MySQL Create Database 
Sql :: employee name starting with in sql 
Sql :: how to find lowest salary by departments ? 
Sql :: mysql utc to toronto time 
Sql :: what is in operator 
Sql :: selecting names ending with vowels in sql 
Sql :: connecting fastapi to mysql server 
Sql :: check if two tables are identical sql 
ADD CONTENT
Topic
Content
Source link
Name
8+7 =