First, check what the number means

“Twenty-kilogram dumbbell press” might mean twenty kilograms in each hand or twenty kilograms total. A barbell record may or may not include the bar. Before interpreting a training plan or someone else's result, resolve that ambiguity.

In your own log, “2 × 20 kg” and “40 kg total, including bar” make the convention clear.

The equipment changes the task

Separate dumbbells allow different hand paths and require independent control. A bar connects the hands. Range of motion, grip, getting into position, and familiarity can differ. A heavier total barbell load does not establish that dumbbells are inferior; it may simply be a more loadable task for that person.

A workable way to switch

Use the target repetition range and intended effort to find a manageable load for the new exercise. Allow for the unfamiliar setup rather than testing an online conversion immediately.

Keep the two exercises as separate progress records. If your dumbbell performance improves while your barbell result stays unchanged, that is not necessarily contradictory. Strength includes both muscular capacity and practiced coordination. A comparison is most informative when it asks about the particular movement you actually trained.