首页 新闻 会员 周边

怎么将list集合中的数据添加到elatiscsearch中索引中

0
[已关闭问题] 关闭于 2022-08-12 16:32

//创建上下文选择器
adminEntities1 admin = new adminEntities1();
//查询condition表中数据
var index = from count in admin.condition
select count;
List<Conditions> list = new List<Conditions>();
Conditions add;
foreach (var item in index)
{
add = new Conditions();
add.Id = item.id;
add.Name = item.name;
add.Age = (int)item.age;
add.Address = item.address;
add.Height = (double)item.height;
add.Weight = (double)item.weight;
add.Marriage = item.marriage;
list.Add(add);
}

把list集合中的数据添加到ES索引中

宋人鱼的主页 宋人鱼 | 初学一级 | 园豆:14
提问于:2022-08-02 16:24
< >
分享
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册