Text
Desvantagens:
SELECT Nome_Artista,Nome
FROM Artista A,Usuário_Titular S,Escuta E,Toca T,Usuário U
WHERE E.Usuário_ID = U.Usuário_ID
AND E.Música_ID = T.Música_ID
AND T.Artista_ID = A.Artista_ID
AND A.cidade = S.cidade
AND U.Usuário_ID = S.Usuário_ID;
SELECT Nome_Artista
FROM Artista,(SELECT DISTINCT Artista_ID,Lista_ID FROM Produz) AS P1
WHERE Artista.Artista_ID = P1.Artista_ID
AND NOT EXISTS (SELECT *
FROM Produz P2
WHERE P1.Lista_ID = P2.Lista_ID
AND P2.Artista_ID <> P1.Artista_ID)
AND EXISTS (SELECT *
FROM Compõe,Toca T1
WHERE Compõe.Música_ID = T1.Música_ID
AND P1.Lista_ID = Compõe.Lista_ID
AND NOT EXISTS (SELECT *
FROM Toca T2
WHERE T2.Música_ID = Compõe.Música_ID
AND T1.Artista_ID <> T2.Artista_ID));
Vantagens:
[Rabl T, 2012]
[Rabl T, 2012]
redis-cli
redis> SET mykey "Hello"
"OK"
redis> GET mykey
"Hello"
redis> MSET key1 "Hello" key2 "World"
"OK"
redis> MGET key1 key2 nonexisting
1) "Hello"
2) "World"
3) (nil)
redis> GET mykey
"Hello"
redis> STRLEN mykey
(integer) 5
redis> APPEND mykey " World"
(integer) 11
redis> SETRANGE mykey 6 "Redis"
(integer) 11
redis> GET mykey
"Hello Redis"
redis> SET mykey "10"
"OK"
redis> INCR mykey
(integer) 11
redis> DECR mykey
(integer) 10
redis> INCRBY mykey 5
(integer) 15
redis> GET mykey
"11"
redis> SET myfloat 10.50
"OK"
redis> INCRBYFLOAT myfloat 0.1
"10.6"
redis> SET key1 "Hello"
"OK"
redis> EXISTS key1
(integer) 1
redis> EXISTS nosuchkey
(integer) 0
redis> TYPE key1
"string"
redis> DEL key1 key2 key3
(integer) 2
redis> SADD myset "Hello"
(integer) 1
redis> SADD myset "World"
(integer) 1
redis> SADD myset "World"
(integer) 0
redis> SMEMBERS myset
1) "World"
2) "Hello"
redis> SISMEMBER myset "Hello"
(integer) 1
redis> SCARD myset
(integer) 2
redis> SMEMBERS myset
1) "World"
2) "Hello"
redis> SADD myotherset "Hello" "there"
(integer) 1
redis> SINTER myset myotherset
1) "Hello"
redis> SDIFF myset myotherset
1) "World"
redis> ZADD myzset 1 "one" 2 "two" 3 "three"
(integer) 3
redis> ZADD myzset 1 "uno"
(integer) 1
redis> ZRANGE myzset 0 -1 WITHSCORES
1) "one"
2) "1"
3) "uno"
4) "1"
5) "two"
6) "2"
7) "three"
8) "3"
redis> ZRANGE myzset 2 3
1) "three"
redis> RPUSH mylist "one"
(integer) 1
redis> RPUSH mylist "two"
(integer) 2
redis> RPUSH mylist "three"
(integer) 3
redis> RPOP mylist
"three"
redis> LRANGE mylist 0 -1
1) "one"
2) "two"
redis> LPOP mylist
"one"
redis> LRANGE mylist 0 -1
1) "two"
redis> HMSET myhash field1 "Hello" field2 "World"
"OK"
redis> HMGET myhash field1 field2 nofield
1) "Hello"
2) "World"
3) (nil)
redis> HKEYS myhash
1) "field1"
2) "field2"
redis> HGETALL myhash
1) "field1"
2) "Hello"
3) "field2"
4) "World"
redis> GEOADD Sicily 13.361389 38.115556 "Palermo" 15.087269 37.502669 "Catania"
(integer) 2
redis> GEODIST Sicily Palermo Catania
"166274.1516"
redis> GEORADIUS Sicily 15 37 100 km
1) "Catania"
redis> GEORADIUS Sicily 15 37 200 km
1) "Palermo"
2) "Catania"
redis> GEOPOS Sicily Palermo Catania NonExisting
1) 1) "13.36138933897018433"
2) "38.11555639549629859"
2) 1) "15.08726745843887329"
2) "37.50266842333162032"
3) (nil)
Modelo Entidade Relacionamento
Solving big data challenges for enterprise application performance management (2012)
Rabl T, Gómez-Villamor S, Sadoghi M, Muntés-Mulero V, Jacobsen H, Mankovskii S
fernando.scattone@usp.br