import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.Scanner;
import java.util.StringTokenizer;
public class Mian {
public static void main(String[] args) {
FastScanner fs = new FastScanner();
int n=fs.nextInt();
while(n-->0){
int x=fs.nextInt();
int y=fs.nextInt();
int a=fs.nextInt();
int b=fs.nextInt();
int A=Math.abs(x-a);
int B=Math.abs(y-b);
if(A==0||B==0){
if(A==0&&B==0){
System.out.println("no");
}else{
if(A>1||B>1){
System.out.println("yes");
}else{
System.out.println("no");
}
}
}else{
int z=gcd(Math.abs(x-a),Math.abs(y-b));
if(z!=1){
System.out.println("yes");
}else{
System.out.println("no");
}
}
}
}
public static int gcd(int a, int b) {
int max, min;
max = (a > b) ? a : b;
min = (a < b) ? a : b;
if (max % min != 0) {
return gcd(min, max % min);
} else
return min;
}
public static class FastScanner {
private BufferedReader br;
private StringTokenizer st;
public FastScanner() {
br = new BufferedReader(new InputStreamReader(System.in));
}
public String nextToken() {
while(st == null || !st.hasMoreElements()) {
try {
st = new StringTokenizer(br.readLine());
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
return st.nextToken();
}
public int nextInt() {
return Integer.valueOf(nextToken());
}
}
}