select * from [dbo].[t_usuari]

select ROW_NUMBER() OVER (order by cdg_usr) as ID,cdg_usr,[Des_usr],[Psw_usr] from [dbo].[m_usuari]


select modu.Cdg_opc,modu.Des_opc,opc.Num_item,opc.Des_item, sopc.Num_cor,sopc.Des_cor,sopc.Swt_cor  from t_opcion as sopc 
inner join d_opcion opc on sopc.Cdg_opc=opc.Cdg_opc and sopc.Num_item=opc.Num_item
inner join m_opcion modu on opc.Cdg_opc=modu.Cdg_opc
inner join d_usuari perm on opc.Cdg_opc=perm.Cdg_opc and opc.Num_item=perm.Num_item
where perm.Cdg_usr='SUPERVISOR' order by 1,3


select  ROW_NUMBER() OVER (order by cdg_opc) as ID,cdg_opc,des_opc,Swt_opc from [dbo].[m_opcion]
select  ROW_NUMBER() OVER (order by cdg_opc) as ID,cdg_opc,des_opc,Swt_opc from [dbo].[m_opcion]