現在選択されているアイテムのリスト位置を知っていて、そのアイテムに対して何らかのアクションをトリガーするボタンがListViewの外側にあり、ListView行(または各行内の子ビュー)をクリック可能にするだけではありません。右?
リストのアダプタから情報を取得できます。getItem(int position)は、位置にあるリストアイテムによって表されるオブジェクトを返すため、オブジェクトに格納されている場合は、必要な情報を直接取得できます。getView(int position)は行のビューを返し、findViewById(int id)を使用してTextViewを取得できるようにします。
アダプターをまだ持っていない場合は、getAdapter()を使用してListViewからアダプターを取得できます。
// ListView myListView = the ListView in question
// int selectedRow = the currently selected row in the ListView
// Each row in the ListView is backed by an object of type MyCustomDataClass
int dbRowId;
Adapter adapter = myListView.getAdapter();
MyCustomDataClass data = (MyCustomDataClass) adapter.getItem(selectedRow);
dbRowId = data.getDatabaseRowId();
// OR
dbRowId = data.rowId;
// OR whatever method the object has for getting the ID.
// OR
View listViewRow = adapter.getView(selectedRow);
TextView dbRowView = (TextView) listViewRow.findViewById(R.id.rowid);
String dbRowAsString = dbRowView.getText().toString();
dbRowId = Integer.parseInt(dbRowAsString);
また、ユーザーが行を選択して別のボタンを押すのではなく、ListView行をタップする方が自然であるかどうかを検討することもできます。リノの答えはもっとうまくいくかもしれません。