yes, it's possible, even in an older dog.
I have 4 dogs, 3 of which wanted to attack my chickens. Like you said, my dogs were used to seeing the chickens in their run. Once they came out though, they wanted to chase them.
I took one dog at a time on a leash around the chickens and told them "no!" (With a leash correction) if they showed interest in the chickens. After a while, the dog knows it will be corrected when it looks at the chickens. Put your dog in a sit/stay if possible while around the chickens. If you can get that to work, you can let the leash down and stand in the end, correct the dog if it makes an attempt to move towards the birds. Eventually, your dog will know he'll be reprimanded if he pays any attention to the chickens.
My chickens got used to the dogs keeping their distance so when one came close, the chickens actually attacked the dog which sent him running! One time, one of the dogs had the nerve to go into the run to scope out scraps. When a chicken realized an interloper was in the run, she rushed in and pecked the dog until she ran out whimpering.