I have a listview where people name and when I click on a person I use the adapter.getitem(position)
that takes the person's name, however, I needed to get the id of the person and not the name. Does anyone know how I can do this? Briefly I need to bring 2 database data, the name and the id, however only present the name in the listView and get the id when clicking. there are similar names, so I need the id.
obs: I'm currently doing something I do not know if it's gambiarra or it's smart. list the names and when I click on the name use the option to get the id. It's working right now but it's not good practice.