如何在网格视图中搜索全名 [英] How to search full name in grid view

查看:106
本文介绍了如何在网格视图中搜索全名的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在全名任何地方搜索的查询是什么



SelectCommand =SELECT Name,InvestmentType,StartDate,EndDate,Phone,Address FROM PaymentTracker1FilterExpression =名字喜欢'{0}%'



例如名字是Madhu goud

当我搜索Madhu时显示记录但是当我搜索为goud时没有显示



i想要在我搜索为madhu或goud时显示记录

what is the query for search anywhere in full name

SelectCommand="SELECT Name, InvestmentType,StartDate,EndDate,Phone,Address FROM PaymentTracker1" FilterExpression="Name LIKE '{0}%'"

for example a Name is Madhu goud
it is showing records when i search as Madhu but not showing when i search as goud

i want to show records when i search as madhu or goud

推荐答案

FilterExpression =Name LIKE'%{0}%'
FilterExpression="Name LIKE '%{0}%'"


Name LIKE '%{0}%'


如果您想使用姓氏进行搜索,那么

If you want to search with last name then
Name LIKE '{0}%'



如果你想用名字搜索那么


If you want to search with first name then

Name LIKE '%{0}'



,两者都可以使用


and for both you can use

Name LIKE '%{0}%'


这篇关于如何在网格视图中搜索全名的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆