Run Code  | API  | Code Wall  | Misc  | Feedback  | Login  | Theme  | Privacy  | Patreon 

SQL

Language: Layout:
- ] Show input
Absolute running time: 0.32 sec, cpu time: 0.17 sec, memory peak: 7 Mb, absolute service time: 0,5 sec 
edit mode |  history  | discussion
select idempresa, count (*)/(select count(*) from empresa) as probabilidad from empresa where idempresa in (select distinct idempresa from empresa) and idindustria in (select distinct idindustria from encadenamiento) group by idindustria, idempresa order by idempresa, idindustria;

    
                
λ
.NET NoSQL database for rapid development