Super Mario 3D Land
Sandmaarghs make their debut appearance in the the first stage of World 3 and later appear in the first stage of World 5 and the first stage of the sixth Special World, which are all desert levels. Their main pattern of attack has them burrow underneath their target and rise up, but while above-ground they can be destroyed by anything.
Mario & Luigi: Paper Jam
Sandmaarghs make their Mario & Luigi debut in Mario & Luigi: Paper Jam, with their habitat being Doop Doop Dunes. In the field, a Sandmaargh rises from below in order to eat a Bro. This can be easily avoided easily and the monster will be thus rendered vulnerable, but if the Sandmaargh has his prey, he will get the first attack, which cannot be avoided and causes big damage.
The Sandmaargh attacks by inhaling a hero. That hero has to use his hammer to knock objects into the Sandmaargh's mouth. Getting eaten causes lots of damage.