.ilike()
找到所有在所述 column
上的值与提供的 pattern 相匹配的记录(不区分大小写).
const { data, error } = await supabase
.from('cities')
.select('name, country_id')
.ilike('name', '%la%')
参数
-
column required
object
要筛选的 `column`. -
pattern required
string
要过滤的模式。
例子
使用 select()
const { data, error } = await supabase
.from('cities')
.select('name, country_id')
.ilike('name', '%la%')
使用 update()
const { data, error } = await supabase
.from('cities')
.update({ name: 'Mordor' })
.ilike('name', '%la%')
使用 delete()
const { data, error } = await supabase
.from('cities')
.delete()
.ilike('name', '%la%')
使用 rpc()
// Only valid if the Postgres function returns a table type.
const { data, error } = await supabase
.rpc('echo_all_cities')
.ilike('name', '%la%')