[v6r12] new ps and fk dfc

This PR contains a new sql schema with enforced Foreign Key, as well as stored procedure. The managers to call the various PS are also included. It also contains numerous bug fixes 
if fileName is "" anyway you are not using the lfn but for failed dict, which... is it really useful?