From the course: Database Clinic: MongoDB

Unlock the full course today

Join today to access over 22,400 courses taught by industry experts or purchase this course individually.

Search a database

Search a database - MongoDB Tutorial

From the course: Database Clinic: MongoDB

Start my 1-month free trial

Search a database

- Our next challenge involves a needle in a haystack. Search is arguably the most important function of any database. Combing a vast haystack of data for a specific needle of information is one of the most common computing tasks. Google alone processes over 40,000 searches every second. That's almost a million searches since I started talking. If you're only combing a 30-line spreadsheet, search can be pretty easy. In fact, it might be just as easy to browse around as it is to use the find dialogue. Unfortunately, many databases are large, containing terabytes or petabytes of information. It wouldn't be practical to page through the data looking for a specific value. Likewise, searches can be complex. It's one thing to look for a known number, but it's more difficult to look for something like say the highest salary of dog walkers in states with rainfall higher than the national average. That kind of complex search requires a database with a sophisticated query language. Structured…

Contents