I am new to redis, now I want to get all the keys in one db, not knowing about keys or key patterns. After googling, I found sodu code about my problem, but I don't have a key or data field in this code:
var connection = ConnectionMultiplexer.Connect(new ConfigurationOptions { EndPoints = { { DemoSettings.CustomerRedisCache.Url, DemoSettings.CustomerRedisCache.Port } }, Password = DemoSettings.CustomerRedisCache.Password }); var server = connection.GetServer(host: DemoSettings.CustomerRedisCache.Url, port: DemoSettings.CustomerRedisCache.Port); var cadena = "cust:" + data.SearchString.Replace(' ', ':')+"*"; var valores = server.Keys(pattern: cadena);
thank you for your responses
source share