Back to the Henriks Apps frontpage.

Heroku and Mongo DB.

One of my customers uses a Heroku server as backend. The server uses a Mongo DB database. Software for the backend is written in Node Javascript or Node-JS.

SQL is used a lot for databases, but there are databases that do not use SQL. MongoDB is one of that class of databases that do not follow SQL.

As everyone knows it is easy to retrieve data from an SQL database. It is as simple as issuing an SQL command, say

SELECT * FROM customers

This command will give you all the data from the table "customers".

On our Heroku server it was not possible to pull data out of the Mongo database. A web interface did allow you to see 10 records from a table, but it was not really useful.

I therefore wrote some Javascript software to fetch the desired data. I formatted the data as a long string in comma-separated format. In Javascript a string may be up to about 1 GB long.

I used the Nodemailer facility to send an email with this string.

The email goes to the person in the company of my customer who is responsible for customer service and marketing.

The string appears as an attached file, so you can take it into a spreadsheet with a click of a mouse. Voila, you have a lot of data for customer service and marketing.

Things Henrik works with, and ancient stuff he worked with in previous lifetimes

Henrik has worked with a variety of backend systems using languages such as Javascript Node, C, PHP, Perl, and even ancient languages such as COBOL and Fortran.

He has worked with backend platforms such as Linux and Heroku and used MySQL and MongoDB databases. He has also implemented specialized filebased databases when this was required or was the best solution.

He has been responsible for life critical medical data and for financial transactions to a value of 35 billion dkk.

He has implemented an Apple Notification Server platform that sends encrypted notifications to Apple devices using curl with HTTP2 on a linux platform.

Henrik is a mobile app developer covering both iOS and Android.

He has done web design and programming in HTML and CSS for about 20 years. He has used Perl and PHP for server-side scripts.