#include <bits/stdc++.h>
using namespace std;
const int N = 1e5 + 7;
long long int M = 1000000007;
int main() {
  std::ios::sync_with_stdio(false);
  cin.tie(NULL);
  long long int t;
  cin >> t;
  while (t--) {
    long long int n;
    cin >> n;
    vector<pair<int, int>> a(n);
    for (int i = 0; i < n; i++) {
      int u, v;
      cin >> u >> v;
      a[i] = {u, v};
    }
    sort(a.begin(), a.end());
    string ans = "";
    int curX = 0, curY = 0;
    bool ok = true;
    for (int i = 0; i < n; i++) {
      if (a[i].first < curX || a[i].second < curY) {
        ok = false;
        break;
      }
      if (a[i].first > curX) {
        ans += string(a[i].first - curX, 'R');
        curX = a[i].first;
      }
      if (a[i].second > curY) {
        ans += string(a[i].second - curY, 'U');
        curY = a[i].second;
      }
    }
    cout << (ok ? "YES" : "NO") << '\n';
    if (ok) cout << ans << '\n';
  }
}
