Skip to content

Instantly share code, notes, and snippets.

View FabioRodrigues's full-sized avatar

FabioRodrigues

View GitHub Profile
package main
import (
"fmt"
"log"
"github.com/vmihailenco/msgpack"
)
func main() {
func main() {
arguments := os.Args
if len(arguments) == 1 {
fmt.Println("Please provide a port number!")
return
}
PORT := ":" + arguments[1]
l, err := net.Listen("tcp4", PORT)
if err != nil {
BEGIN TRAN
DELETE usuarioconhecimentoidioma
FROM usuarioconhecimentoidioma q
JOIN (SELECT c.idusuariomapeamento,
Max(c.ididioma) ididioma,
Count(*) qtd
FROM usuarioconhecimentoidioma c
JOIN usuariomapeamento um
ON c.idusuariomapeamento = um.id
select
c.IdUsuarioMapeamento
,l.NomeUsuario
,l.Id
,count(*) qtd
from UsuarioConhecimentoIdioma c
join UsuarioMapeamento um on c.IdUsuarioMapeamento = um.Id
join login l on um.IdLogin = l.Id
group by c.IdUsuarioMapeamento, l.NomeUsuario, l.Id
having count(*) > 2
--Query 1
SELECT * FROM IDIOMA
--QUERY 2
select
idprocesso,
count(*) as qtdIdiomas
from ProcessoConhecimentoIdioma
group by idprocesso
having count(*) > 2
conclusoes.Any(x=>x.Documento == documentoPlanilha)) && conclusoes.First(x=>x.Documento == documentoPlanilha).QuantidadeConcluida == quantidadeTotal
public class Usuario : EntidadeBase
{
public Usuario()
{
}
public string Login { get; protected set; }
public string Senha { get; protected set; }
public virtual ICollection<Grupo> Grupos { get; protected set; }
@FabioRodrigues
FabioRodrigues / gist:1423016
Created December 2, 2011 12:08 — forked from diegodfsd/gist:1419071
DesabilitarNós
;function checkboxUtil(){
var input
, init;
this.init = function(){
input = $("form input:checkbox")
var self = this;
input.live('click', function () {
var elemento = $(this);
@FabioRodrigues
FabioRodrigues / gist:1423015
Created December 2, 2011 12:07 — forked from diegodfsd/gist:1419071
DesabilitarNós
;function checkboxUtil(){
var input
, init;
this.init = function(){
input = $("form input:checkbox")
var self = this;
input.live('click', function () {
var elemento = $(this);
@FabioRodrigues
FabioRodrigues / gist:1418984
Created December 1, 2011 18:57
DesabilitarNós
<script type="text/javascript">
$(document).ready(
function () {
// DesabilitarTodosNaoChecados();
var input = $("form input:checkbox");
input.click(function () {
var elemento = $(this);
DesabilitarTodosNaoChecados(elemento);
});
}