开发者

Difference between SQL and LDAP

开发者 https://www.devze.com 2023-02-12 06:56 出处:网络
I have used both SQL and LDAP, but in a recent conversation with one of my peers I came to realize that there may be more to it. And that it could be beneficial to consider LDAP over SQL at times.

I have used both SQL and LDAP, but in a recent conversation with one of my peers I came to realize that there may be more to it. And that it could be beneficial to consider LDAP over SQL at times.

So my challenge/request/question: Can you explain to me the advantages开发者_如何学C (and disadvantages) of LDAP over SQL "in the elevator". That is, a short 2-3 minutes presentation.


LDAP is a protocol for accessing directories, SQL is a query language for databases.

Both systems store data, but the big difference is: directories (like Active Directory) are tuned towards a lot more reads than writes, e.g. reading information should be very easy, trivial indeed (and offer great performance), while updating can be a bit of a pain. Also: directories are often distributed, e.g. spread across multiple servers/locations, and offer mechanisms to easily replicate read-only data across locations.

SQL databases on the other hand are geared towards a more balanced load of read and write, and thus, writes must also be as easy as possible.

So this boils down to:

  • if you have data (like user accounts, permissions) that are mostly read (but not very often updated), then a directory sounds like a great solution

  • if you need to frequently insert new data and update existing data, then a database is much more suited to your needs. Don't try to create an order entry system inside a directory - it's a poor match.....

Those distinctions aren't "absolute" or clear - it's often a judgment call whether to put something into your database, or whether it belongs into a directory.


The Lightweight Directory Access Protocol (LDAP) is an application protocol for reading and editing directories over an IP network. More [here].

A good read on LDAP and its difference from Database is available [here]

Also,check out the following links :

  • LDAP vs Relational Database (a)
  • LDAP vs RDBMS


There is a nice comparison available - but unfortunately its' in German only (and quite old, but that shouldn't matter as neither the basic notion behind SQL nor behind LDAP has changed since 2002): http://kris.koehntopp.de/artikel/dir-vs-rel/sld001.htm

0

精彩评论

暂无评论...
验证码 换一张
取 消