I would like to get specific column from DV table based on input from user.
db :
animal weight height
cat 40 20
wolf 100 50
first i need to get what animal user wants
input1='cat'
and then information about the input1 like weight or height
input2='weight'
animalwho=Wildlife.objects.get(animal=input1)
So if i put animalwho.weight
it give me 40
But i want to get column based on input2 as input 2 might be height or any other
I tried animalwho.input2
but it does not work.
Is that possible to get column based on input2?
Would apopreciate any help