# Why Automapper Not set id in the newly created object Using Select

**URL:** <https://forum.codewithmosh.com/t/why-automapper-not-set-id-in-the-newly-created-object-using-select/1094>\
**Category:** ASP.NET MVC\
**Created:** [December 2, 2020, 11:07pm UTC](https://forum.codewithmosh.com/t/why-automapper-not-set-id-in-the-newly-created-object-using-select/1094 "2020-12-02T23:07:22Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![HaidarAli](https://avatars.discourse-cdn.com/v4/letter/h/71c47a/32.png) [@HaidarAli](https://forum.codewithmosh.com/u/HaidarAli)\
**Post date:** [December 2, 2020, 11:07pm UTC](https://forum.codewithmosh.com/t/why-automapper-not-set-id-in-the-newly-created-object-using-select/1094/1 "2020-12-02T23:07:22Z")

</div>

{  
modelId: 1,  
isRegistered: true,  
contact:{  
name: ‘Haidar’,  
phone: ‘hsa8@gmail.com’,  
email:‘03450598318’},  
lastUpdate: ‘2000-01-01’,  
features: [3,4]

```
}

```

I Passed the value in Postman and Map it with automapper to Handle Many to Many Relation Ship. But it Passed 0 insted of the Value 3, 4 .Please Help me. It wastes my 21 days. I am searching for my problem but its not solve

```
.ForMember(v => v.Features, opt => opt.MapFrom(vr => vr.Features.Select(Id => new VehicleFeature{FeatureId=Id})))
```
