<?
$rsSections = CIBlockSection::GetList(array(),array('IBLOCK_ID' => $arParams ['IBLOCK_ID'], '=CODE' => $arResult['VARIABLES']['SECTION_CODE']));
if ($arSection = $rsSections->Fetch())
{
echo $arSection['ID'];
}?>
$section = \Bitrix\Iblock\SectionTable::query()
->where('IBLOCK_ID', $iblockId)
->where('CODE', 'КОД РАЗДЕЛА')
->where('ACTIVE', 'Y')
->setSelect(['*'])
->exec()
->fetch()
;