pginfo <pginfo(at)t1(dot)unisoftbg(dot)com> writes:
> I am using pg 7.3.3 on RH 7.3,
Are you certain the server is 7.3.3? This looks like a mergejoin
estimation bug that was present in 7.3 and 7.3.1, but should be fixed
in 7.3.2 and later.
If it is 7.3.3, I'd like to see the pg_stats rows for
a_acc.ids_vid_doc and a_vid_doc.ids.
regards, tom lane