Getting Started With SlamData – Part 1
Jan 25, 2017
Damon provides a quick "getting started" video for SlamData.
The following is a transcript of the the video above:
Welcome to the SlamData getting started video. Let’s jump right in.
By default, SlamData runs on port 20223. You can change the port it runs on by modifying the quasar-config.json file. By default, this file is located in the following directories on Windows, Mac and Linux. I have SlamData running on my Mac laptop on the default port. This is the SlamData virtual file system view. We don’t have any data sources mounted yet, which is the first thing we need to do. I’ll click on the mount icon that looks like a disk drive.
Connecting A Data Source
I’m going to be using MongoDB as a data source in this video, but you can use any of our supported data sources, that are listed here in the mount dialogue. You interact with data sources through a virtual file system. The name of the mount can be whatever makes sense to you. I’m mounting this system with the name of medical, because I’ll be using it to store fictitious medical data. You’ll use this name when writing queries later, so name it something you can remember, and makes sense to you. You can see here the data source was successfully mounted, and is represented by a disk drive icon.
Viewing and Exploring Your Data
We refer to this as a mount point, and you can create as many as you need. By clicking on the new mount, SlamData takes me to the mount and shows me what folders I have access to. These folders can be thought of as directories in the SlamData virtual file system. Here is shows me folders I have access to based on the credentials I provided in the mount dialogue. Notice at the top, it shows the location I am at in the SlamData virtual file system.
This path will always show your current location within the SlamData virtual file system. Let’s click on the folder to see what’s in there. You cans see my path is updated at the top. If you have existing data in a folder, it will appear here. This folder has some data already, but I’m going to import new data using the SlamData interface. You can follow along by downloading the patients file, from the SlamData getting started web page.
Sample Data Set
Here’s a sample of what the patients data looks like. It’s a JSON file with many data types, including arrays with nested documents. You can upload both json and csv files into SlamData, and it will convert the data into the native storage format of that mount. I’ll click on the import icon, locate the file, and submit it. You can see that a new entry appeared on our screen. Notice the icon next to it, this represents a SlamData virtual file. SlamData files are usually equivalent to a table, collection or logical grouping of document types, depending on the data source backend.
Working with Workspaces
Now that we’ve imported the example data, I wanna take a look at it so I click on it. SlamData creates a new workspace that allows you to view the file. You’ll be asked to give a name to this new workspace that is being created. Keep in mind that the workspace configuration will be stored on your mount, but the data it references is not stored in the workspace, so there is no duplication of data here. I’m calling this one Patients Simple View, since I just want to browse the data. After clicking explore, the new workspace is created, and we’re taken from the file system view, to the workspace view. When you’re in a workspace, you can easily get back to the file system view, by clicking the zoom out icon on the upper left of the page.
Saving Your Work
All changes made to a workspace are saved automatically, so there’s no need to manually save your work. Here we’re presented with a preview table of the file we clicked on. Remember, the actual data in this preview table is not stored in the workspace we just created, but in the SlamData file this workspace is referencing. Going back to the file system view, we can see the workspace we just created, as well as the original patients file.
Getting Into Workflows
Notice each has a different icon representing what it is. Now at any point you can click on the workspace, and be taken back to the preview table of the data. SlamData’s approach to analytics is to compose a workflow with one or more distinct actions. Think of a workflow as a deck of cards, where each card performs a specific function with the results from the previous card.
In this way you can build a very flexible analytics workflow based on your needs. One or more workflows can be stored inside of a SlamData workspace. As another simple example, let’s create a different workspace that has a cleaner view of the data and limits the results. To do this, we’ll need to create a workspace by clicking on the new workspace icon in the upper right. What we’re presented with here are different cards.
More Cards, More Flexibility, SQL2
Cards that are a darker shade of grey, and have a check mark can be selected at this stage of the workflow. Since this is the first card of a work flow, I’m going to select the query card, which allows us to enter a SQL2 query and execute it. SlamData uses a 100% ANSI compatible SQL dialect, which allows you to query both relational two-dimensional and semi structured multi-dimensional data.
For help with SQL2, visit our documentation site, at docs.slamdata.com, and click on the SQL2 reference guide. Let’s type the following query, keeping in mind the locations of the patients file in the SlamData file system. I want to see all patients in the state of Texas grouped by city, in ascending order.
Pay Attention To Syntax
You can type a query on one line, or use multiple lines. Make sure to use single back ticks to surround the full path name, and full quotation marks to surround strings. Now click the run query button. We don’t see any immediate results, because the query card only performs a single step. It runs a query. We’ll need to add a new card that can show us something. To do that, we’ll click on the right gripper of this card. You can see grippers on the left and right of the card. You can navigate between cards by simply clicking on the grippers, or click and drag on the grippers.
By clicking on the right gripper, we’re advancing to the next card. We’re now presented with the cards that we can stack on top of the query card. The dark grey options have changed, because the previous card was a query card. Let’s select a preview table card, to see the results of the query. Now we can zoom back out to the file system view.
I want to rename that workspace now. We’ve successfully created two workspaces in this video, the first by clicking on a file and previewing the data, and another by querying the data, then displaying it. In other videos, we’ll show you how to create queries referencing nested data, creating charts, embedding charts into your application, and more. And thanks for watching.
SlamData Community Edition
News, Analysis and Blogs
The Hadoop Data Lake has been positioned as the one size fits all answer to a company’s data silo problems. In reality, Hadoop is often NOT the most efficient answer to the problem.read more
SlamData Inc., the leading open source analytics company for modern unstructured data today announced that it has raised a $6.7M Series A funding round, led by Shasta Ventures.read more
SlamData just released its first update of 2017, SlamData 4.1.1. It delivers a number of new UI enhancements, performance improvements, new charts, as well as commercial releases for the Couchbase, MarkLogic and Spark/Hadoop connectors.read more
We’re excited to announce that we’ve been included in the 2017 list!read more
The following is an interview I conducted with Jeff Carr, CEO and Founder of SlamData regarding the trends in enterprise business intelligence.read more
Enterprise Business Intelligence solutions are failing, and the reasons are very obvious. Leading analyst firms including Gartner and G2 have published rankings which show virtually no leadership and scant challengers in the market.read more
Send Us A Message