How to detect changes in data while preserving confidentiality (under constraints)?
I'm going to try to make a handwavy argument that this problem doesn't have any great solution.  Criticisms are welcome!  A major assumption here is that my definitions are general enough to cover any possible solution to your problem.

Suppose there exists a scheme consisting of three deterministic algorithms $\operatorname{Broadcast}(X, Y)$, $\operatorname{CompareX}(B_1, B_2)$ and $\operatorname{CompareY}(B_1, B_2)$.  $\operatorname{Broadcast}$ is run by party $A$ and accepts $X$ and $Y$, outputting some "broadcast" value $B$.  $\operatorname{CompareX}$ and $\operatorname{CompareY}$ compare two broadcast values to determine if they were generated from the same $X$ or $Y$ values, respectively, and output $0$ when matching or $1$ when different.

Suppose a broadcast value $B_0$ is received by the attacker, who wishes to determine the secret value $Y$ from which it was generated.  The attacker can use the public algorithms $\operatorname{Broadcast}$ and $\operatorname{CompareY}$ to brute force the $Y$ value as follows:


Choose some arbitrary fixed value $x$ for use as an input to $\operatorname{Broadcast}$.
For each $y$ where $y$ is a guess for $Y$, call $\operatorname{CompareY}(\operatorname{Broadcast}(x, y), B_0)$.  Halt and output $y$ iff $\operatorname{CompareY}$ outputs $0$.


This suggests the option of making $\operatorname{Broadcast}$ or $\operatorname{CompareY}$ slow.  Consider the following scheme:


$\operatorname{Broadcast}(X,Y) = (X, \operatorname{PBKDF}(Y))$, where $\operatorname{PBKDF}$ is a password-based KDF such as scrypt, but using a fixed salt.
$\operatorname{CompareX}$ and $\operatorname{CompareY}$ are simply an equality check on the appropriate field.


If $S$ (the set of possible $Y$ values) is large and $\operatorname{PBKDF}$ is sufficiently slow, this might afford a modest level of security.