1218:
1219: -- cursor to get the next level_sequence
1220: Cursor l_acyv_csr Is
1221: select NVL(MAX(level_sequence),0) + 1
1222: from OKC_ANCESTRYS
1223: where cle_id = p_clev_rec.cle_id;
1224:
1225: -- cursor to get other ascendants
1226: Cursor l_acyv_csr2 Is
1224:
1225: -- cursor to get other ascendants
1226: Cursor l_acyv_csr2 Is
1227: select cle_id_ascendant, level_sequence
1228: from OKC_ANCESTRYS
1229: where cle_id = p_clev_rec.cle_id;
1230:
1231: BEGIN
1232: x_return_status := OKC_API.G_RET_STS_SUCCESS;
1624:
1625: -- cursor to get ancestry records to delete
1626: Cursor l_acyv_csr Is
1627: select cle_id, cle_id_ascendant
1628: from OKC_ANCESTRYS
1629: where cle_id = p_cle_id;
1630:
1631: BEGIN
1632: -- delete all ancestry records if p_cle_id is not null