Why does the Brady's test, the reaction of 2,4-dinitrophenylhydrazine with aldehydes and ketones, fail with carboxylic acids?
2,4-Dinitrophenylhydrazine (2,4-DNP or 2,4-DNPH) reacts readily with aldehydes and ketones via a condensation reaction (the lone pair of electrons on the terminal amino group in 2,4-DNPH makes it a strong nucleophile and the condensation starts by the nucleophilic 2,4-DNPH attacking the electrophilic carbonyl carbon) to produce the corresponding hydrazone. The hydrazine is usually a brightly colored yellow, orange or red compound, so the reaction is often used to test for the presences of an aldehyde or ketone
2,4-DNPH does not react with amides, esters or carboxylic acids. As shown below for the case of an ester, an extra resonance structure can be drawn for these 3 types of compounds as compared to a ketone. This extra resonance structure delocalizes some of the positive charge away from the carbonyl carbon onto the adjacent hetero-atom (oxygen in the case of the ester or carboxylic acid, nitrogen in the case of an amide). This makes the carbonyl carbon less electrophilic in these compounds, and consequently attack by the nucleophilic 2,4-DNPH is less favored.
It's for the same reason that you can't make amides from a carboxylic acid and an amine: the amine deprotonates the acid. The carboxylate anion is resonance-stabilized and the carbonyl carbon is insufficiently electrophilic. You couldn't form a tetrahedral intermediate.
Same here: the hydrazone is formed from a ketone through nucleophilic attack on the carbon, the intermediate being a hemiacetal. You won't get a hydrazide derivative here, although from an ester with sufficiently forcing conditions you might.