I could not formulate it briefly and clearly, I will try to illustrate with an example.
There is a table And
小褌芯谢斜械褑 袗1 | 小褌芯谢斜械褑 袗2 | 肖谢邪谐 | 校泻邪蟹邪褌械谢褜 Table B
校泻邪蟹邪褌械谢褜 | 小褌芯谢斜械褑 袙1 | 小褌芯谢斜械褑 袙2 Table C
校泻邪蟹邪褌械谢褜 | 小褌芯谢斜械褑 小1 It is necessary, depending on the value of the flag from table A (0 or 1, for example), to connect with it either table B or table C, so that the result is as follows:
小褌芯谢斜械褑 袗1 | 小褌芯谢斜械褑 袗2 | 肖谢邪谐 | 校泻邪蟹邪褌械谢褜 | 小褌芯谢斜械褑 袙1 | 小褌芯谢斜械褑 袙2 袗11 | 袗21 | 0 | 58 | 袙14 | 袙25 袗12 | 袗22 | 0 | 92 | 袙17 | 袙29 Either way:
小褌芯谢斜械褑 袗1 | 小褌芯谢斜械褑 袗2 | 肖谢邪谐 | 校泻邪蟹邪褌械谢褜 | 小褌芯谢斜械褑 小1 袗15 | 袗26 | 1 | 82 | 小1 袗18 | 袗28 | 1 | 94 | 小1 Is it possible to somehow implement it in one request?