I use a single strand of electric fencing around the base of the fence about 6 inches off the ground and about that far away. I have ducks that are loose and the fence is primarily to contain my hogs and to give me peace of mind as people frequently abandon dogs on our dead end street. We use flockshock brand which is relatively inexpensive. The ducks go in and out of the hogs area as they like to play in the mud (go figure, they have their pond). Rarely the birds do get shocked but it doesn't seem to bother them.
I've included a picture so you can see how low the fence is and how well they keep in even hogs.
I've included a picture so you can see how low the fence is and how well they keep in even hogs.