Q:

How can I select elements that don't include part of data- attribute value?

I try to hide elements that don't contain part of a text in the data attribute.
Here is an example. The expected result should be hiding all elements that don't contain the key similar to "UK"
<input type="text" id="step3LRGender" data-country="UK IT">
<input type="text" id="step3LRAge" data-country="PL IT">
$('[data-country*="UK"]').show();
$('[data-country!*="UK"]').hide();

A:

Combine your code with :not() as in $('input:not([data-country*="UK"])').hide();
Demo

$('input[data-country*="UK"]').show();
$('input:not([data-country*="UK"])').hide();
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<input type="text" id="step3LRGender" data-country="UK IT">
<input type="text" id="step3LRAge" data-country="PL IT">

You can also use the following:
$('input,div').filter(function() {
  return $(this).data('country').indexOf("UK") > -1 ? $(this).show() : $(this).hide();
});

Demo

$('input,div').filter(function() {
  return $(this).data('country').indexOf("UK") > -1 ? $(this).show() : $(this).hide();
});
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<input type="text" id="step3LRGender" data-country="UK IT">
<input type="text" id="step3LRAge" data-country="PL IT">

<div data-country="UK IT">UK IT</div>
<div data-country="PL IT">PL IT</div>

