Need Documentation on the specific API also suggest data base editors

Hi all,
These lectures take an assumption that the api being used, in this case nodejs / javascript, is somehow “known” by the us the students… For anyone listening, the api is not magically known. How to interact with mongodb via not just the engine and javascrip implementation but also the applied technological language used is necessary. How else would one know?

With that said, I hope people on this thread and mongo staff can illustrate to us how to exactly use the api… Is there complete documenation for example? What is version is the api on compared to the impletation of mongo i.e. is the api on version 2.1 for mongo 3.6 or otherwise?

Lastly, can you guys suggest something other than compass for sql like db code editing.

I have been use DBKODA and like it very much. any other free editors out there?

I look for forward to everyones replies.

A course named … for JavaScript Developers is allowed to assume you know JavaScript.

Hi,

You sort of brought this up already on a different thread and much like as has become apparent on that thread it’s not really clear what exactly you are expecting here. For instance, you keep saying API but you are not providing any context of what you mean by that.

Do you want to know the NodeJS API methods and documentation? Then that is available online:

MongoDB Node.JS Driver

You want to know the version? Then that was available in the package.json:

 "mongodb": "^3.1.6"

You want “version compatibility”? Then there’s a listing for that as well:

Node.js Driver Compatibility

If you want documentation on general MongoDB operations, then there are a number of sources being either:

Query and Projection Operators
Update Operators
Aggregation Pipeline Stages
Aggregation Pipeline Operators

These ALL generally apply to ANY implementation language as at their core they represent the BSON instructions which are actually sent to the server in requests. The core documentation is also essentially based as JavaScript in general presentation as this is the language implemented by the mongo shell as bundled with the database distribution.

Even on broader examples showing “shell methods” for implementation is therefore essentially the same as the NodeJS JavaScript driver implementation, with the exception of a few “minor” differences ( which can be compared by looking at the method implementation on the NodeJS Driver) and of course the “async” nature of NodeJS in general, which this course material covers a minor introduction to in itself.

All of that said, the listed prerequisites are indeed slimmer than they should be:

Prerequisites:
We highly recommend taking M001 prior to taking this course. A basic understanding of MongoDB’s document model will help you get the most out of this course.

Therefore I would advise that in order for you to comfortably follow along with this course then you at least have:

  • A competent understanding of MongoDB CRUD operations, at the very least obtained from a full understanding of MongoDB CRUD Operations and ALL sub-sections of the related core documentation. Successful completion of M001 would be advised.

  • General JavaScript competency, in particular understanding “Object Structures” and accessing of “object properties”. MDN has a good tutorial introduction with JavaScript object basics and other related sections. There are also plenty of other resources to “Learn JavaScript” from as this is NOT a course designed to do that.

  • Prior working knowledge of working with NodeJS applications in general. Mostly since this is NOT a course in “Getting started with NodeJS” and having that exposure as a starting point should be a basic minimum.


For the most part though, the majority of lesson material quite fairly introduces you to topics and provides example usage for you to follow in many cases. Mostly each exercise will even point you to the relevant reference documentation as required for that particular section and the problems to be solved based on information that can be obtained from that reference source.

In the rare ( and I actually count one ) instance where a question might require you to “look up” something where it does not directly point you to the exact reference source, you should find that some people have already been *helpful" and provided a “link” to the relevant documentation source in this very forum, when you take the time to read the threads.

Of course, there is always the “internet” as a friend since you will find most questions you can come up with have generally been asked by someone else before. Even if not specifically in this discussion forum:

i.e “mongodb nodejs projection” as the literal search input to Google gives me a very accurate answer as to “what to do” within just a few links from the top of the page.

Finally, even if you are finding it hard to comprehend or keep up then the course material is still always “of value” since as you acquire greater knowledge then you should be able to refer back to the material and then understand it better at a later date.

And the answers are given too you, but quite naturally only after the assessment for each topic is complete.

Finally, not really clear what you mean by “Database editors”. I presume you want something like “code completion” on operations like aggregation pipeline stages such as $lookup etc. I really don’t know of any things that do this outside of some rudimentary function in compass.

Personally, I never use them and have been doing this for a while now so I’m probably not the “new user” example. But I generally find the operator references ( first set of links given ) to be of greater use. And frankly I just “edit” in my current “general editor” of choice ( currently VSCode for what that’s worth :wink: ) and simply “Copy+Paste” the “text” into an open mongo shell. Since (for me at least) that just works.


FYI, the majority of links presented in this page where simply obtained by me typing what was effectively the “page” or “section” titles ( or close variant of ) directly into a search engine and calling up that page. This is a really simple thing to do, and it yields results which should always be your very first step in obtaining information about anything.

Research first, then ask peers questions about “your research”. You will find people a lot more receptive to helping you when you can demonstrate effort and give them a base to understand what exactly you are asking.

1 Like

I don 't understand your confusion? Do you understand 100% what i am asking? you keep referring to knowing javascript. I am not asking about javascript.

In all fairness the comment made by @steevej-1495 ( though unnecessary ) is likely more born of frustration in that this is not the first time you voiced this complaint and that you don’t exactly explain what you mean and what you are expecting as an outcome.

Which is why I just wrote that “novel” above.

1 Like

i have provided context to what an api is several times. I will use projection via find as an example… I can write it. .find().project() or I can write it .find(xxxxx, {projection: }) the first method is based on the node drive or i.e api.

I continue to not understand why this isn’t in documentation…

Then please sit down and take half an hour or so and read. Since I did explain to you that exact point that “other people” pointed you and others to the documentation related to project() even if the course material made no mention in either “link” or “video” content.

What I suggested at length is that you “calmly” take the time to assess the information and various links to sources you would need as reference to complete the course instead of voicing your frustrations again.

I’m thinking that you are confused with the driver for a programming language and the native syntax to use mongodb with the mongo shell. They are similar but they have their own way to write queries.

no i know exactly what i am asking. I am asking for the driver information i.e. api or documentation on how to fully use the driver. lol is it me? (facepalm)

@neillunn i think it fair that and I had this exact issue with the .net course… Just provide the documentation and or where to find it. I am not saying you didn’t show me and if you did in your novel post - thank you - what I am saying is scrounging around for the information is annoying and unnecessary.

It’s not the end of the world… We are not building rockets or heading off to a mar colony but in honesty it is annoying not to just provide the drive documentation.

Well for the extremely lazy it’s the very first link. The one titled:

Sorry that was so difficult

lol THANK YOU. It’s literally called

3.1 Driver Reference API

Why am I lazy for not knowing this? Where and how did you find it.

Again, thanks.

last question. 3.1 is compatible with what version of mongodb? i.e. is it compatible with 4.0? i’d assume so but just wondering if there are any limitations.

Ok, I understood what you think, but belive me, In the mongodb site is all the information to work with it, you have to find how to understand the chapters, first they show you what they include, what can you do, how, etc, then in the reference area, you can find all the sintax to implement your queries with any driver of languange of programming. Check https://docs.mongodb.com/manual/reference/ at the left you can access all the methods that mongo provide it. I hope that this clarifies some of your questions. :robot: hummmm… check in google “MongoDB Node.JS Drive” and as @neillunn said, that’s all you were asking

well believe it or not this post was tremendously helpful and I hope it helps others.