For example, here is my tagged tag. There is a main tag, "information technology", and there is his pseudonym, "it". I want, when inserting a new entry in the table of posts marked with the tag "it", to check if it already exists in the tags table, and if so, if it has a value in the real_id field, and, if so, insert it into the table of posts an entry with tag_id = 1, not two.
