Some people will feed the dog when dinner is over and they think that's different, but the dog can't tell when it's dinner time and will bug you until you stop dinner and then feed him. So think about the chain of behavior that you're rewarding here. Learn here https://tr.im/am6Cw
Contrary to what you're being told here, feeding your dog "people food" is not what's making him beg. I'm a professional trainer and always feed my dog human quality training treats (cut up chicken, cheese, beef, turkey, etc.) and those of us trainers who do this never have a begging problem. Our dogs know that they get "paid" for correct behavior and never from the table. You could feed your dog dogfood from the table and have a begging problem. It isn't *what* you're feeding, but *when* and *where* you feed him that counts.
If you have a problem with begging, the odds are that you have other problems as well. Consider taking your dog to a basic training class to teach him to obey when you ask him to do something or stop doing something undesirable. Dogs that bark and pester you have learned bad habits-- from you! Going to a training class will help you unlearn those and help you get into better habits.