The phrase ‘Barking up the Wrong Tree” means to make the wrong choice; to ask the wrong person; to follow the wrong course.
You can use the phrase ‘Barking up the Wrong Tree’ when explaining that you are not the right person to address.
Example of Use: “I have been trying to solve this math problem for 30 minutes, but I think I’ve been barking up the wrong tree.”
The origin of the idiom 'barking up the wrong tree' dates back to early 1800s America, when hunting with packs of dogs was very popular. The term was used literally at first, when wily prey animals such as raccoons would trick dogs into believing they were up a certain tree when in fact they had escaped. Thus, dogs barking at the base of an empty tree were said to be “barking up the wrong tree.”