No, this is not a good idea.
One reason is that only the minimum gain-bandwidth product is specified. You can count on it being at least that, but it could be, and probably is in any one part, somewhat higher. The net result is that frequencies above the gain-bandwidth product will have unpredictable attenuation.
Another issue is that while gain-bandwidth is a useful spec, it is only a very simplified model of what the opamp does. There are other issues, like slew rate and the difference between large signal and small signal responses.
Yet another issue is that the opamp won't magically pass all frequencies below the gain-bandwidth product. Generally you want to stay 10x below it to be able to ignore it. The 2 MHz signal is only 2.5x below the gain-bandwidth product, meaning you can only count on a gain of 2.5 at that frequency. That means the simplifying assumptions of a typical feedback system are being violated. Those are based on the gain being infinite, or at least "large" (again, 10x is a common margin) compared to the closed loop gain.
If you want to pass 2 MHz and attenuate 20 MHz, get a amp that can pass the 2 MHz properly, then add a deliberate filter to attenuate the 20 MHz.
But wait, there's more. As the input frequency goes up, the opamp no longer works like a opamp at all. Feeding it signals much above the unity gain frequency can cause side effects, like intermodulation distortion, rectification, or other nasty non-linear phenomena you can't predict. So get a opamp that can properly buffer up to 2 MHz, then add a low pass filter before the opamp to attenuate the unwanted higher frequencies.
Open loop Vout / Vin isn't constant - it rolls off with frequency and obeys the gain-bandwidth product approximation: -

What you may be being confused with is the DC open loop gain and, from the diagram above that would be quoted in a data sheet as 1 million.
Best Answer
GBP is the to do with the open loop gain of the op-amp. If you have a closed-loop circuit then GBP can help you find where the flatness of the frequency response starts to be eroded.
GBP - if it has an open loop DC gain of 1 million and unity gain at 1MHz then the GBP is said to be 1 million.
This is useful to know because if you have an op-amp that has a GBP of 1 million and you have a manufactured a closed loop gain of 100 then I would expect the gain to remain flat up to about 10kHz then roll-off gently at 6 dB / octave: -
Here is an extract from the data sheet for the AD8606 op-amp and I've drawn four red lines on it at 10kHz, 100kHz, 1MHz and 10MHz. The line at 10MHz is important because this is the unity gain point of the op-amp i.e. it has a GBP of 10,000,000. If this was all we knew we could predict the open loop gain at 10kHz by dividing 10,000,000 by 10,000 to get 1,000 (this would be the open loop gain at 10kHz and of course a gain of 1,000 is 60 dB - exactly as seen in the graph.