Skip to main content

about 4 years ago Syntax Podcast

Supper Club × Adam Cowley and Neo4j Database

Adam Cowley

Adam Cowley Guest

Wes Bos

Wes Bos Host

Scott Tolinski

Scott Tolinski Host

Topic 0 00:00

Transcript

Guest 2

rebuilding the the platform to make them sort of more hands on, the,

Guest 2

online self paced learning platform.

Guest 1

With me as always is mister Scott Talinski. How are you doing today, Scott? Hey. I'm doing good. Ready to go. Ready to learn about some of the database stuff. Yeah. Cool. Well, Adam, thank you so much for coming on. Really appreciate it. Yeah. No problem. Excited to be here. Thanks for having me.

Announcer

This is

Guest 2

So I'm a developer advocate and I look after the

Guest 1

you are

Guest 2

So over the past year or so, I've been been,

Guest 1

what these things are, and and we'll we'll dive into it. So, do you wanna give us a quick rundown of who you are, where you're from, and, and who you work for? Yeah. Sure. Yeah. So my name is Adam. I'm a member of the DevRel team at at Neo4j.

Guest 1

I have been in the web development database space for for many, many years. And Every I don't know. Every couple of weeks, someone says, hey, what about Neo four j? And then, yeah, the opposite weeks, people say, what is the graph?

Announcer

Hoo. I'm starving.

Announcer

I sure hope you're hungry.

Guest 2

GraphAcademy

Guest 1

So we thought people kept tagging you and said, hey. You gotta have them on to sort of explain

Guest 1

I think I forget how we got connected, but basically,

Guest 1

light step incident response, the all in one incident response platform for DevOps and SREs.

Guest 2

Before Neo4j,

Guest 1

Supper Club is where we bring on industry experts and talk to them about whatever it is they are working on. We are sponsored by Gats Be the fastest front end for the headless web and query in select things that are on sale, but more than $40 and and what seems to be a little bit of code because, like so I'm coming from a MongoDB background,

Announcer

so buckle up and grab that old handle because this ride is going to get wild.

Guest 1

So

Announcer

the Syntax Supper Club.

Guest 1

Hey, everybody. Welcome to the Syntax Supper Club. We've got Adam Cowley. Is that how I say it, Adam? Yeah. That's right. Yeah. Awesome. We got Adam Cowley from Neo four j on here to finally answer the question, what Is the graph and what does it mean?

Announcer

Wash those hands, pull up a chair, and secure that feed bag, because it's time to listen to Scott Tolinski and Wes Bos attempt to use human language to converse with and pick the brains of other developers. I thought there was gonna be food,

Topic 1 15:39

Learning Cypher querying is a paradigm shift but intuitive

Guest 1

Yep. I've been there. Yeah. Yeah. Oh, that's great. I I also think that it's really interesting to look at different querying languages because I had the same Man,

Guest 1

Minus this one course. I can get that data if I want to, but it's like

Guest 1

Such a complicated

Guest 1

This is a lot more

Guest 1

Sanity has this they well, they've they've open sourced it. They have a standard called GR0q, g r o q,

Guest 1

from regular ass queries

Guest 2

acted in movie, in genre, the the rows inside a table would become nodes in in a database,

Guest 2

This is exactly the the same way that that you query the data. So so for me, this is a thing that,

Guest 2

a graph diagram which is drawn on on a piece of paper, so you've got circles which are So 50,000 nodes, 175,000

Guest 1

eaten a cinnamon bun.

Guest 2

and a greater than or less than to to represent the the line that goes between the the the 2 circles.

Guest 1

like, courses and stuff like that. But then, like, You start thinking about, like, this really, really complicated. Like, show me people who visited Lisbon and touched upon an airport code in the last,

Guest 1

and it's a different way to query data. And at first, I was like, Well, like, we have GraphQL. Like, what are you doing making another query language? And then and the answer to that is, well, not really.

Guest 2

And then we basically draw out the pattern of, you know, person, So so, typically,

Guest 1

It's unreal that you can express

Guest 2

square brackets,

Guest 2

easy simple to do, and and and,

Guest 2

to draw a circle around,

Guest 2

So it's it's another paradigm shift, but I think once people get it, it it starts to to make sense. So I think from from the the the data storage order to to how you query it. So so so we we talk about this, whiteboard friendly data model where the, the the data that you, And I've been basically building websites for about 20 years, which is

Guest 2

is Is that when you query using Cypher, you basically draw those patterns out using ASCII art. So say we've got those those circles on a, on a piece of paper, So we use parenthesis, In in school and college, you use Netscape as well at the same time. Oh,

Guest 2

a node and then we have some some some information inside there. We use dashes,

Guest 1

Which are very Yeah. Because and then aggregations are such a pain to write, and I'm just, like, always googling things and And whatnot. And I'm glad that I have the option. So if I wanna run, like, how much money did I make per year in the last 5 years

Guest 2

Well, that's right. The the the data model or the diagram you draw on a whiteboard is exactly the same all the way down to the the database storage layer. So Neo4j stores data in in such a way that makes traversing graphs, with with the name of the table being, applied as a label.

Guest 1

It's so true. Like, you sometimes you think about, like, just a simple you got a person, and the person has,

Guest 1

thing when I hit,

Topic 2 23:46

Data can be synced between MongoDB and Neo4j

Guest 2

migrate data with.

Guest 2

Neo4j. And that means that you get to obscure the the credentials and, you know, you you keep,

Guest 2

inside Neo4j,

Guest 2

and then that gets distributed and and consumed into, sort of 8 8, 9 years ago when I, started looking at different types of databases, this was the thing that that really drew me to to Neo4j

Guest 1

Okay. Okay.

Guest 2

That data gets pushed up to Kafka queue, Neo4j itself is the underlying technology, then they can be consumed by, any sort of application.

Guest 1

Like, like, make, like, a first party

Guest 2

the Neo4j JavaScript driver. So, if if you start to play around with, With Neo4j, the first thing you'll you'll see is the, graph use case. So I'm I'm trying to find the the the name of the the guy that wrote the book at the moment, but there's a,

Guest 2

authentication and and and roles and things like that. And you can store your users and and roles, and they, you would then maybe convert the, Go, and connector, but,

Guest 2

you're front end and, more added latency to get that information back, and things start to to get slow and and start to get messy.

Guest 1

Like if I wanted to say,

Guest 3

Neo four j from other databases, or is it typically new applications written from scratch? Like, is it

Guest 2

Neo4j browser. Yep. So it's kind of like a a workbench or or toolkits. That's where you write Cypher queries, then you get graph visualizations and and tables back. And so that uses the, Neo4j drive Neo4j JavaScript driver to connect directly to Neo4j run a Cypher query, get the info back, and then display that. And that's built in React.

Guest 3

possible to migrate a MySQL or even a MongoDB,

Guest 2

JavaScript applications that could be, like, for example, I could react application and, Cypher is is part of that. So if you think of a,

Guest 1

write an API on the server? Do you even need to write an API? Or is Neo4j, like, Is the cipher the API? Like, do you even need to? Like, what does that look like if I wanted to pull in some data and put it in a div? What does the process to getting there look like? So there there are 2 ways of of doing this, really. So you can either put a an API in between your, bakery products and then databases in an or or a cinnamon buns in an array there. There's no possible way that they could have, like, scaffolded that that out. Is that the kind of stuff that people are using this for? Yeah. Definitely. Like, real time recommendations is a is a huge,

Guest 2

So we got a a set of tools that that do that. Or if you wanna be more safe, about it, you can put the API in between the 2.

Guest 3

database

Guest 2

role can perform this,

Guest 1

In the client? Or is there like, what does that look like? Do people typically

Guest 2

dis distribute date route to to to different sources and,

Guest 2

extension or plug in or whatever you call it and add that to your directly to your database, which is written in Java? Yep. That's right. Yeah. So the the the j in if j stands for for Java. So I I I joke when so when when I joined the the company 5 years or so ago, official drivers, so that's, Java, JavaScript, Neo4j safe. You don't expose any password or anything like that. Or you can connect directly from a,

Guest 1

users can only access purchases that are their own. Is that something that is part of Neo four j, or is that something part of just custom implementation code that you would have to write? So that'd be, custom implementation for that. So there there are some features in in, like, community built libraries and and things like the the Neo4j GraphQL Library where,

Guest 2

Yeah. I I don't know if I I don't know the the tactful way of answering this question, to be honest. So, yeah, it's it's, like, anything is, anything is possible. Right? Like, if you're deciding, you know what? No graph at all. I see you're you're wearing a JavaScript shirt, right? Yeah. That's right. You're a web developer.

Guest 2

So, I mean, if like, for me, I would put that in the location layer, but it is possible to write. If if if you know if you know Java, then it's it's possible to write, kind of triggers to,

Guest 2

it supports things like

Guest 1

does Neo4j So it's kind of cool to see into Aggregations.

Guest 1

What about, like, events or webhooks? Is is that something as well? Often in a database, you would want to say, like, When somebody purchases something,

Guest 1

And, like, Hasura takes a Postgres database, Okay. And what about like, I'm just thinking about one of our sponsors, which is Hasura.

Guest 2

Anthony for Jay, there's also, I think, a a community

Guest 1

things of events. Is that again, is that is that part of the database? Does the database Fire events that you could listen to, or is that again more implementation code? over the year. Like like, fire off these these,

Guest 1

and then they put a whole in order to identify

Guest 1

where people can only access, The data ahead of time when you create it? I I'm assuming you do. Like like, when you want to create, like, a person,

Guest 1

add authentication

Guest 1

cover any of the, like, services as well? Or is it strictly just a database?

Guest 1

set of code in front of a Postgres database that Allows you to like, their whole service is,

Guest 1

they give you a GraphQL API. They do authentication. They do events. They do webhooks. They do Pretty much everything. And you can just connect straight to your geographical database. Is there,

Guest 3

to a Neo four j graph database. Is that something that people are doing, or Or is it just totally too tough? Yes. So, there there are, inbuilt tools that you can,

Guest 2

their core webhooks and things like that. Oh, okay. So you could, So you you can log on to Neo4j Aura, and you can create a, a free instance.

Topic 3 02:33

Adam Cowley has worked with Neo4j for 5 years

Guest 1

Scott and I have that had that

Guest 2

Scary.

Guest 1

realization as well. We're like, man, like, we're we're getting into this, you know, like, we're starting to We're starting to hear people that have, like, not ever done I e ten and sometimes even I e 11. And just like, wow. Like,

Guest 2

Here we are. Like, what was the 1st browser you used? So I guess it was must have been Internet Explorer. But, I'd I so I I I tried to be a little bit different in,

Topic 4 10:32

Graph databases are good for real-time recommendations

Guest 3

You can get the full context on your service health, active alerts, and who's on call. LightStep incident response immediately pinpoint issues

Guest 3

You pay for the services you actually use, not the number of the people on your team, which is important because you can scale your incident response team without adding to your bill. You get intelligent

Guest 2

The, Connected together by arrows and maybe draw some some boxes around the, the relationships to make relationship types.

Guest 3

So check it out. Are you in need of incident response? Check out lightstep.comforward/syntax.

Guest 3

network of of humans. I I Listen to something where it's talking about how, like,

Guest 2

you have friends who also like cinnamon buns, then, you know, there there's a a connection there.

Guest 3

receive a free light step incident response t shirt after firing an alert or incident.

Guest 3

and groups alerts with machine learning, reducing your time to respond. And this means less noise and more personalization for precise notifications where you can take control way to query the graph.

Guest 2

So if if you're, a let's say, a smoker, for example, or or or you like cinnamon buns,

Guest 3

on declaring incidents automatically notifying the right teams. And you can get unified incident response by seamlessly orchestrating alerts and incident triage with on call scheduling across Slack, Teams, Zoom, desktop, and mobile. So what you'll want to do is head on over to lightstep.comforward/

Guest 3

Let's Bring it back. I have a I I see on your website a lot about Aura DB.

Guest 2

So I think the the the study said that,

Guest 3

Instagram or Meta kind of knows more about you than many of your

Guest 3

a person by their network and and their connections. Yeah. And That that holds true even, like, I mean, in social media, in your follows kind of become your new

Guest 3

syntax, and you'll get a free 30 day trial. Listeners of Syntax will also

Guest 2

out there that says that you can, know more about a person by the connections they have and their their their friendship groups than

Guest 3

on call scheduling and escalations.

Guest 2

You could predict whether somebody else was a smoker based on, whether the that their immediate network were were also smokers.

Guest 3

LightStep instant response is built on the ServiceNow platform, which is used by over 6,000

Guest 2

then what they can say about themselves.

Guest 3

companies.

Guest 3

for DevOps and SREs.

Guest 2

So you you can tell a lot about a, in, like, 2006.

Topic 5 05:05

Graph databases use nodes and relationships instead of tables and rows

Guest 2

but, really, it's it's nothing to to be scared of.

Guest 1

let's let's take my course platform for an example, because that's kind of what I'm I'm familiar with. So we've got,

Guest 2

the table name I'm not sure what state that's in at the moment. Wow. Are do you see people migrating to choose to to scale up and, basically, swipe a credit card, and off you go. Cool. So and and since most of our You you know that they've got these, like, animated charts where it shows, like, the percentage of of,

Guest 2

would become relationships. Oh, okay.

Guest 2

into a graph database, so typically, handler. And so it's basically writing a a piece of Java that when a transaction Commit to then push the data out, or vice versa. You can have have have the data pulling into,

Guest 1

I'm just looking at, like, a visual example of here. Those are just like

Guest 1

and then and then we have progress can be related to that. So with a graph database,

Guest 3

in in Neo4j. Okay. So you have

Guest 1

And then you can put a lay you can throw a label on those,

Guest 2

1 or more labels. So we could say if if you had a a table of of people, you'd have sorry.

Guest 2

And then the the foreign keys, or over 10 years as a a freelance web developer and run my own web development company.

Guest 3

edges and vertices, and and what does what does that I'll mean in terms of, like, let's say we're we're working with, like you're talking to somebody whose only experience is MySQL

Guest 2

we use nodes to represent, like, Things in in the database while we use, like, relationships to to MongoDB. So you can do that with a a a transaction, which is free in in perpetuity,

Guest 1

at which

Guest 2

when so when we translate that over into,

Guest 1

documents or what do you call it? A node thrown into the ether.

Guest 1

a purchase can relate to a course. Then each course can have videos,

Guest 1

like purchases. When somebody bought something, we've got users. A user can have purchases.

Guest 1

So, like, you've got, powerful in that if you want to

Guest 2

to be the, to to be a label. So nose can be identified by,

Guest 3

Or even, like, a a NoSQL.

Guest 2

NivoCharts or something like that. I'm I'm not talking about these things.

Guest 2

in in those tables would,

Guest 2

Yeah. So the the the right of the table would typically become nodes, You can hit a, for example, like an anchor node, and then you you traverse out through the graph to to find,

Guest 2

database point of view where, you know, we've got tables, columns, and rows, On the surface of it, that that sounds great.

Guest 2

and then we've got, you know, foreign keys and things like that in a in a relational database,

Guest 2

So when I talk about graphs, I I don't mean like Highcharts, ChartJS,

Topic 6 14:22

There are official drivers for Java, JavaScript, Python, Go and .NET

Guest 1

Much more terse

Guest 1

because you don't have to do the joins. Right? Like, that's the whole pain in the butt part of of running MySQL is that If you are selecting data

Guest 2

against database. So Cypher is a, a pattern matching You got latency over the wire as you communicate with that 1st database.

Guest 1

and that can be a really big pain in the butt. So it seems like,

Guest 2

And then we have, community drivers there as well for for things like, PHP, Ruby,

Guest 1

So it seems that you learn this new

Guest 1

much like if you are running in MySQL, you'd learn SQL to select it.

Guest 1

Do you find that to be a little bit of a hurdle for people having to learn this cipher first? maybe 10 years ago, we had Opera switch over to using Chrome. And,

Guest 1

language,

Guest 3

.net? a oh, okay. Here we go. You know? I feel the same way about aggregations west. So it's like Whenever I have to I I I go into Google. I type in MongoDB aggregations. I my first thought is, here we go. Yeah. There we go again. Great. I'm so excited.

Guest 3

Yeah. Yep.

Guest 1

that crosses multiple tables, you have to join those first, I'm very both very excited about it, but both very a little bit cautious about it because, like, Like, could you write Neo4j queries

Guest 1

Oh, this is cool. So the so that that was my next question is, like, how do you actually get data out of it?

Guest 2

r.

Guest 2

language which allows you to Find patterns in your data and then return that, the those results back through the driver, I spent 10 years as a, And then you run what are called Cypher queries,

Guest 1

It seems like the Cypher language is

Guest 1

Neo4j cipher is much easier.

Topic 7 22:58

Neo4j GraphQL library translates GraphQL to Cypher queries

Guest 3

super neat here.

Guest 3

Looks looks

Guest 2

secondary database. I I've seen people use things, you know, like, you you maybe write write the data to to MongoDB.

Guest 3

I also saw something about, like, syncing with MongoDB.

Guest 3

Is that Is that a a thing? Like, I know you mentioned it just now with, like, latency. Is that the same thing as,

Guest 3

what I'm seeing with, like, being able to sync a,

Topic 8 02:57

Adam Cowley used Netscape browser in school to be different

Guest 1

interesting.

Guest 1

We've had some, like, major browser changeovers and whenever we get complicated in MongoDB, you have to switch 3 years, but hasn't Where,

Guest 1

and now I have to test Like, what, 3 or 4 browsers on the iPhone? You've got courses,

Guest 1

Who else? Well, Chrome even existing. Yeah. Chrome, yeah, Chrome forked web kit into Blink. That was a big one for us as well. And Yeah. It's kinda interesting. I wonder what the next big step is,

Guest 2

But I I've got huge back for the the the people that are in, like, 2005, 2006, so we use Netscape. Yeah. They're still going hard on it. Yeah. It's it's funny to see.

Guest 2

all the way down to nothing. It just disappeared

Guest 1

The developer in me is like, absolutely. Like, we need more browsers. I want to be able to, like, when a when a feature comes out, I want to use it immediately on Chrome on the Ios and not have to wait 6 years for safari to have us implement it. And then the other part of me is like, oh, well,

Guest 3

But yeah. You know, Wes, like, me using the Chrome on Android, Chrome on Android always was Pretty dang solid. So if we can get the, like, Android Chrome on Ios,

Guest 2

Good question. Graph databases are a bit of a, a paradigm shift, I guess, to people coming from backgrounds using other databases,

Guest 1

that's impressive. Of course.

Guest 2

of things and and how they change over time? So I was watching 1 the other day, and I was captivated by it. It was just, straight into, into Neo4j using the,

Guest 1

in that with a browser game. I I guess they're now allowing a third party browsers on the On the iPhone, which is gonna be literally all those things are just

Guest 2

like, browser usage service,

Guest 2

over the last sort of 30 or so many years. And I I just remember watching, like, Netscape Go go from, like, 35%

Topic 9 09:04

Schema is optional but key entities need to be defined upfront

Guest 1

on the way to the store, bam, I'm getting an ad for a cinnamon bun. I'm like, there's somewhere in a database

Guest 1

Okay. So, like, the names of the notes are are required ahead of time, but you can put any data you want inside of those. So do people use that for like, sometimes I find myself doing, like, data scraping or I see this as big in data science as well,

Guest 2

you you need to to to know the the model itself upfront, the the key entities, but the actual details of of those can can change on the fly. So when we look at Neo4j, it's a, and put, like, a a tighter training sorry. A a integration there with, with other Neo4j projects.

Guest 1

Where they have a table called recently smelled,

Guest 1

Whereas, like, maybe, another person will have a car and the type of car that they have. And it's not Possible to to go way ahead of time for that. And and I even think about, like, the advertising industry. Like, the advertising industry stores literally every single type of data. Like, if I so much smell a cinnamon bun on my way to

Guest 1

you've got a lot of just random data, pieces of metadata about a person. What like like, you have a person And they 1 person has a dog and the dog's name. You wanna throw that in there.

Guest 2

schema free database or a schema optional database, meaning that you can apply a schema to it, but it's not necessarily,

Guest 2

required.

Topic 10 19:00

GraphQL and Neo4j work well together with custom GraphQL library

Guest 3

Yeah. So it seems like you could use GraphQL QL if you want to. You don't have to use GraphQL if you don't want to,

Guest 2

wherever wherever that may be. That can be from from 1 database. That can be From many databases.

Guest 3

directives. You can use, like, a relationship directive and and,

Guest 2

Whereas if you saw everything in a, in a graph database, then

Guest 3

give, like, a Cypher directive that I'm seeing here are pretty neat. But to to be clear, you don't need graphql

Guest 2

So what what the the GraphQL library does, the Neo4j GraphQL library does is it translates the, the GraphQL query into a Cypher query and then then runs that against your database.

Guest 2

So I I'm a little bit on on the fence. So, again, like I said, like, I've been doing this for, like, 20 years. So there's part of me that's worried that I'm,

Guest 2

What happens is you then sort to you you start to query 1 database and then maybe you get, like, a set of IDs back.

Guest 3

to In a graph database compared to I don't know, man. That'd be pretty pretty sweet for me. So okay. So Neo four j is a a graph database. Right? Is that what you describe it as? Yeah. That's correct. Okay. So what is A graph database.

Guest 2

MongoDB for you return as as part of the the user information a set of roles. So that could just be an array of strings, and then you, in the The GraphQL library, you can set a directive to say that only users of a certain,

Guest 1

And or people that have seen it, you know.

Guest 3

You have a GraphQL library.

Guest 2

They do. And I mean so, I'm talking about graph structures, so edges and vertices Or notes and relationships as as we refer to them in into,

Guest 3

So

Guest 2

everything is is all there. It's in one place.

Guest 2

You then get that information back, and then you go into the 2nd database with the, you know, people who bought this also bought this type queries.

Guest 2

Then maybe you can, traverse off the v o n the the nodes that you're on into Into a new subgraph, and then you can you can query that as well.

Guest 2

Take this with a pinch of salt because I'm I'm paid to to say this, but, it it makes complete sense to to use, But yeah. So so, essentially, like, regardless of the the the driver you use, so you connect to to Neo4j over, a TCP protocol called Bolt, to to find the the information that you're looking for. Cool. So okay. So GraphQL, I said I said going on going on a rabbit hole. Yeah. No. Keep going. I'm interested.

Guest 3

GraphQL.

Guest 1

languages that are are going past that, and and and that it's necessary to create a new,

Guest 3

but it all all is good with Neo four j, but GraphQL could be a fit. It's a a direct,

Guest 3

j d graph database you can just use Your own node libraries or or whatever drivers. You can use Cypher directly?

Guest 3

one of the big

Guest 2

the the the main data store and then using Neo4j as as a graph data store on the sides to do the The the traversals and the, relationships, to to basically, either to to connect them together or to represent kind of the the verbs of the of the use case. So if we look at it from a relational

Guest 3

It seems like, Neil, it seems like graph databases in GraphQL

Guest 2

too old to to get new things now, but there's something about GraphQL which I'm a little bit skeptical about on the surface, it looks like a a really neat thing to do. So, like, you you can create this contract with the the front end, and then the the the front end has got the these definitions The pull through to to the back end and then you create your your your resolvers to pull data from,

Guest 3

are separate but related ideas. Do they Play well together. Is there, like, a a special pairing there? Do they work well together? How are they related?

Guest 3

You can query your data. And it's actually really neat some of the stuff here with these,

Guest 2

Neo4j and GraphQL together, so we've got our own GraphQL library for that.

Guest 2

I worked on on a few projects where we've used, for example, you know,

Guest 3

confusion points, I think, for for some people is you hear Graph, you hear GraphQL, and you say, How are they re how are they related? I know, you know, our API is a GraphQL API. I know, Wes, you've worked quite a bit with GraphQL.

Guest 3

to connect to a neo4 Like, what's what is truly the difference there? What what is the the difference in how it How it access how you access data, how you store data.

Guest 2

Do more read by operations. You you can get really creative with, with with what you do. Yeah. So okay. I'm glad West mentioned

Topic 11 13:18

Neo4j is the underlying technology, AuraDB is the database service

Guest 3

So, like, there'll be things like saying, get started for free with Aura DB. Can you Explain the difference really quick between Aura DB and Neo four j itself. Is is Aura DB a part of Neo four j? Is it how how is it relayed there? So,

Guest 2

driver and everything for this. Correct? Yep. Yeah. Correct. So there there are five,

Guest 2

whereas Neo4j Aura is the,

Guest 2

or so databases is a service.

Guest 3

this is something that is is not just For data science and and people doing applications, I mean, you have a full on Node. Js, Many of your close friends do because of it it has that that those connections and everything about what you're following, what you're liking, whatever. It's built out this total picture of Who you are as a person, and that's how the advertising is so targeted. This episode is sponsored today by LightStep incident response. The all in one incident response

Guest 2

Okay.

Guest 2

Python, mutation.

Guest 2

or you can,

Guest 3

our listeners are web developers, right,

Topic 12 07:41

Nodes are like documents that can contain any data

Guest 1

And do you do you need to know about

Guest 1

ahead of Time do you say a person will have a name and an age and an email address and maybe a password, and they'll have their all the different types. Is that part of creating the database still similar? Or is it like I remember years ago when the NoSQL came out, people were just literally making anything that they wanted and relating it to each other, or is it is it like that? So the,

Guest 2

Or the the the golden rule really is if you're querying a database You've got 3 or more joins,

Guest 3

purchased the course. Okay. Is is there, like, a a specific type of data that works best

Guest 2

a, person and then we go from there.

Guest 2

if the connections between your data is important as the data itself, then you have a graph problem, you should be using a graph database.

Guest 2

has purchased the course. So we've got Mhmm. In in there, we've got 2 nodes, essentially. 1 representing the the person or the customer, and then 1 representing the course. And then we cut a relationship between those to say that this person has, into Neo4j as as as a secondary,

Guest 3

your typical,

Guest 3

relational database or NoSQL database? As the saying goes,

Guest 2

what type of data is inside of it. Is that Yes. So so so if if we take the statement Neo four j Graph with a MongoDB instance. Yeah. So, so you can do it in in 1 of 2 ways. Either you you use Neo4j as your main data store and then you sync the the data out to, platform, which is our free, query language like Cypher in this case. Yeah. The the really nice thing about Cypher as well is it's It's really powerful. You could do a lot. So, I mean, it's it's powerful, but it's it's maybe a little bit dangerous. You can do too too many things with it, but you can really do whatever you want. So you can match pattern in in the graph, and then you could do some update operations.

Guest 2

in in that query, then then you'll need a graph database. Oh, interesting.

Share

Empowering developers for over 286200438939 milliseconds!