How to create random dynamic 2D arrays in SystemVerilog?

In reply to UVM_LOVE:

Have you tried using data[width] instead of data[i] in the constraint?