#include <bits/stdc++.h>
using namespace std;
int t, i, a[1010][1010], j, n, x, y, ax[1010], ay[1010], s, f, k;
char c[2020];
int main() {
  scanf("%d", &t);
  while (t--) {
    memset(a, 0, sizeof(a));
    memset(ax, 0, sizeof(ax));
    memset(ay, 0, sizeof(ay));
    memset(c, 0, sizeof(c));
    scanf("%d", &n);
    for (i = 1; i <= n; i++) {
      scanf("%d%d", &x, &y);
      a[x][y] = 1;
      ax[x]++;
      ay[y]++;
    }
    x = 0;
    y = 0;
    s = 0;
    f = 1;
    k = 0;
    while (s < n) {
      while (ax[x] != 0) {
        if (ay[y] > 0) {
          f = 0;
          break;
        }
        y++;
        c[k] = 'U';
        k++;
        if (a[x][y] == 1) {
          s++;
          if (s == n) break;
          ax[x]--;
          ay[y]--;
        }
      }
      if (f == 0 || s == n) break;
      while (ax[x] == 0) {
        x++;
        c[k] = 'R';
        k++;
        if (a[x][y] == 1) {
          s++;
          if (s == n) break;
          ax[x]--;
          ay[y]--;
        }
      }
    }
    if (f == 0)
      printf("NO\n");
    else {
      printf("YES\n");
      for (i = 0; i < k; i++) printf("%c", c[i]);
      printf("\n");
    }
  }
  return 0;
}
