Microsoft SQL Server vs Redis

Need advice about which tool to choose?Ask the StackShare community!

Microsoft SQL Server

19.4K
15K
+ 1
540
Redis

58.1K
44.7K
+ 1
3.9K
Add tool

Microsoft SQL Server vs Redis: What are the differences?

Introduction

Microsoft SQL Server and Redis are both powerful database management systems, but they have key differences that set them apart. Here are six specific differences between Microsoft SQL Server and Redis:

  1. Data Structure: The primary difference between Microsoft SQL Server and Redis is their data storage model. SQL Server follows a relational database model, where data is organized into tables with rows and columns, and relationships between the tables are defined using foreign keys. In contrast, Redis is a key-value store that stores data in a simple key-value format, allowing quick and easy storage and retrieval.

  2. Read-Write Speed: Redis is known for its high-performance and fast read-write operations. It is an in-memory database, meaning that data is stored in RAM, which allows for low-latency reads and writes. On the other hand, SQL Server, being a disk-based database, may have slower read and write speeds due to the physical disk I/O operations involved.

  3. Scalability: Redis is highly scalable and can handle large amounts of data and high-throughput workloads with ease. It supports distributed data storage and can be clustered to achieve horizontal scaling. SQL Server, while also capable of scaling through clustering and partitioning, may require additional configuration and optimization to handle large-scale workloads.

  4. Data Persistence: SQL Server ensures data durability by persisting data to disk through transaction logs and write-ahead logs. This makes it suitable for applications where data integrity and recovery are critical. Redis, being an in-memory database, relies on periodic or continuous data persistence mechanisms such as snapshots or append-only logs. While these mechanisms can provide data persistence, they may not offer the same level of durability as SQL Server.

  5. Data Querying and Manipulation: SQL Server is renowned for its powerful querying capabilities using the SQL (Structured Query Language). It supports complex JOIN operations, subqueries, and advanced analytical functions. Redis, on the other hand, provides a limited set of operations for data retrieval and manipulation. While it supports basic querying with commands like GET, SET, and DEL, it does not offer the same level of advanced querying capabilities as SQL Server.

  6. Data Model Flexibility: SQL Server provides a flexible data model, allowing the definition of complex relationships, constraints, and data types. It supports ACID (Atomicity, Consistency, Isolation, Durability) properties, ensuring data integrity. Redis, being a NoSQL database, has a flexible schemaless data model. It allows storing semi-structured data like JSON and provides built-in data types. However, it lacks some of the traditional relational database features like referential integrity and complex transactional capabilities.

In Summary, Microsoft SQL Server and Redis differ in their data storage model, read-write speed, scalability, data persistence mechanisms, querying capabilities, and data model flexibility.

Advice on Microsoft SQL Server and Redis

I am a Microsoft SQL Server programmer who is a bit out of practice. I have been asked to assist on a new project. The overall purpose is to organize a large number of recordings so that they can be searched. I have an enormous music library but my songs are several hours long. I need to include things like time, date and location of the recording. I don't have a problem with the general database design. I have two primary questions:

  1. I need to use either MySQL or PostgreSQL on a Linux based OS. Which would be better for this application?
  2. I have not dealt with a sound based data type before. How do I store that and put it in a table? Thank you.
See more
Replies (6)

Hi Erin,

Honestly both databases will do the job just fine. I personally prefer Postgres.

Much more important is how you store the audio. While you could technically use a blob type column, it's really not ideal to be storing audio files which are "several hours long" in a database row. Instead consider storing the audio files in an object store (hosted options include backblaze b2 or aws s3) and persisting the key (which references that object) in your database column.

See more
Aaron Westley
Recommends
on
PostgreSQLPostgreSQL

Hi Erin, Chances are you would want to store the files in a blob type. Both MySQL and Postgres support this. Can you explain a little more about your need to store the files in the database? I may be more effective to store the files on a file system or something like S3. To answer your qustion based on what you are descibing I would slighly lean towards PostgreSQL since it tends to be a little better on the data warehousing side.

See more
Christopher Wray
Web Developer at Soltech LLC · | 3 upvotes · 429.3K views
Recommends
on
DirectusDirectus
at

Hey Erin! I would recommend checking out Directus before you start work on building your own app for them. I just stumbled upon it, and so far extremely happy with the functionalities. If your client is just looking for a simple web app for their own data, then Directus may be a great option. It offers "database mirroring", so that you can connect it to any database and set up functionality around it!

See more
Julien DeFrance
Principal Software Engineer at Tophatter · | 3 upvotes · 428.9K views
Recommends
on
Amazon AuroraAmazon Aurora

Hi Erin! First of all, you'd probably want to go with a managed service. Don't spin up your own MySQL installation on your own Linux box. If you are on AWS, thet have different offerings for database services. Standard RDS vs. Aurora. Aurora would be my preferred choice given the benefits it offers, storage optimizations it comes with... etc. Such managed services easily allow you to apply new security patches and upgrades, set up backups, replication... etc. Doing this on your own would either be risky, inefficient, or you might just give up. As far as which database to chose, you'll have the choice between Postgresql, MySQL, Maria DB, SQL Server... etc. I personally would recommend MySQL (latest version available), as the official tooling for it (MySQL Workbench) is great, stable, and moreover free. Other database services exist, I'd recommend you also explore Dynamo DB.

Regardless, you'd certainly only keep high-level records, meta data in Database, and the actual files, most-likely in S3, so that you can keep all options open in terms of what you'll do with them.

See more
Recommends
on
PostgreSQLPostgreSQL

Hi Erin,

  • Coming from "Big" DB engines, such as Oracle or MSSQL, go for PostgreSQL. You'll get all the features you need with PostgreSQL.
  • Your case seems to point to a "NoSQL" or Document Database use case. Since you get covered on this with PostgreSQL which achieves excellent performances on JSON based objects, this is a second reason to choose PostgreSQL. MongoDB might be an excellent option as well if you need "sharding" and excellent map-reduce mechanisms for very massive data sets. You really should investigate the NoSQL option for your use case.
  • Starting with AWS Aurora is an excellent advise. since "vendor lock-in" is limited, but I did not check for JSON based object / NoSQL features.
  • If you stick to Linux server, the PostgreSQL or MySQL provided with your distribution are straightforward to install (i.e. apt install postgresql). For PostgreSQL, make sure you're comfortable with the pg_hba.conf, especially for IP restrictions & accesses.

Regards,

See more
Klaus Nji
Staff Software Engineer at SailPoint Technologies · | 1 upvotes · 429K views
Recommends
on
PostgreSQLPostgreSQL

I recommend Postgres as well. Superior performance overall and a more robust architecture.

See more
Get Advice from developers at your company using StackShare Enterprise. Sign up for StackShare Enterprise.
Learn More
Pros of Microsoft SQL Server
Pros of Redis
  • 139
    Reliable and easy to use
  • 102
    High performance
  • 95
    Great with .net
  • 65
    Works well with .net
  • 56
    Easy to maintain
  • 21
    Azure support
  • 17
    Full Index Support
  • 17
    Always on
  • 10
    Enterprise manager is fantastic
  • 9
    In-Memory OLTP Engine
  • 2
    Easy to setup and configure
  • 2
    Security is forefront
  • 1
    Faster Than Oracle
  • 1
    Decent management tools
  • 1
    Great documentation
  • 1
    Docker Delivery
  • 1
    Columnstore indexes
  • 886
    Performance
  • 542
    Super fast
  • 513
    Ease of use
  • 444
    In-memory cache
  • 324
    Advanced key-value cache
  • 194
    Open source
  • 182
    Easy to deploy
  • 164
    Stable
  • 155
    Free
  • 121
    Fast
  • 42
    High-Performance
  • 40
    High Availability
  • 35
    Data Structures
  • 32
    Very Scalable
  • 24
    Replication
  • 22
    Great community
  • 22
    Pub/Sub
  • 19
    "NoSQL" key-value data store
  • 16
    Hashes
  • 13
    Sets
  • 11
    Sorted Sets
  • 10
    NoSQL
  • 10
    Lists
  • 9
    Async replication
  • 9
    BSD licensed
  • 8
    Bitmaps
  • 8
    Integrates super easy with Sidekiq for Rails background
  • 7
    Keys with a limited time-to-live
  • 7
    Open Source
  • 6
    Lua scripting
  • 6
    Strings
  • 5
    Awesomeness for Free
  • 5
    Hyperloglogs
  • 4
    Transactions
  • 4
    Outstanding performance
  • 4
    Runs server side LUA
  • 4
    LRU eviction of keys
  • 4
    Feature Rich
  • 4
    Written in ANSI C
  • 4
    Networked
  • 3
    Data structure server
  • 3
    Performance & ease of use
  • 2
    Dont save data if no subscribers are found
  • 2
    Automatic failover
  • 2
    Easy to use
  • 2
    Temporarily kept on disk
  • 2
    Scalable
  • 2
    Existing Laravel Integration
  • 2
    Channels concept
  • 2
    Object [key/value] size each 500 MB
  • 2
    Simple

Sign up to add or upvote prosMake informed product decisions

Cons of Microsoft SQL Server
Cons of Redis
  • 4
    Expensive Licensing
  • 2
    Microsoft
  • 15
    Cannot query objects directly
  • 3
    No secondary indexes for non-numeric data types
  • 1
    No WAL

Sign up to add or upvote consMake informed product decisions

What is Microsoft SQL Server?

Microsoft® SQL Server is a database management and analysis system for e-commerce, line-of-business, and data warehousing solutions.

What is Redis?

Redis is an open source (BSD licensed), in-memory data structure store, used as a database, cache, and message broker. Redis provides data structures such as strings, hashes, lists, sets, sorted sets with range queries, bitmaps, hyperloglogs, geospatial indexes, and streams.

Need advice about which tool to choose?Ask the StackShare community!

Jobs that mention Microsoft SQL Server and Redis as a desired skillset
LaunchDarkly
Oakland, California, United States
What companies use Microsoft SQL Server?
What companies use Redis?
See which teams inside your own company are using Microsoft SQL Server or Redis.
Sign up for StackShare EnterpriseLearn More

Sign up to get full access to all the companiesMake informed product decisions

What tools integrate with Microsoft SQL Server?
What tools integrate with Redis?

Sign up to get full access to all the tool integrationsMake informed product decisions

Blog Posts

Nov 20 2019 at 3:38AM

OneSignal

PostgreSQLRedisRuby+8
9
4639
Jun 6 2019 at 5:11PM

AppSignal

RedisRubyKafka+9
15
1639
GitHubDockerReact+17
40
36257
What are some alternatives to Microsoft SQL Server and Redis?
Oracle
Oracle Database is an RDBMS. An RDBMS that implements object-oriented features such as user-defined types, inheritance, and polymorphism is called an object-relational database management system (ORDBMS). Oracle Database has extended the relational model to an object-relational model, making it possible to store complex business models in a relational database.
PostgreSQL
PostgreSQL is an advanced object-relational database management system that supports an extended subset of the SQL standard, including transactions, foreign keys, subqueries, triggers, user-defined types and functions.
Apache Aurora
Apache Aurora is a service scheduler that runs on top of Mesos, enabling you to run long-running services that take advantage of Mesos' scalability, fault-tolerance, and resource isolation.
Microsoft Access
It is an easy-to-use tool for creating business applications, from templates or from scratch. With its rich and intuitive design tools, it can help you create appealing and highly functional applications in a minimal amount of time.
MariaDB
Started by core members of the original MySQL team, MariaDB actively works with outside developers to deliver the most featureful, stable, and sanely licensed open SQL server in the industry. MariaDB is designed as a drop-in replacement of MySQL(R) with more features, new storage engines, fewer bugs, and better performance.
See all alternatives