I have recently installed MySQL on my Ubuntu 16.04. And I have successfully been able to use commands in the command prompt to create tables, and do commands like
select * from articles
However, the issue appears when I run code from a .js file from node.js. The command line just freezes afterwards. In the picture below, the terminal on the right is the one calling the select.js file with node, while the one on the left is manually calling select * from articles:
Interestingly enough, when I use the insert.js file, the same thing happens in the terminal on the right BUT the line is inserted (which I can verify manually with the terminal on the left).
QUESTION:
Why might the terminal on the right not finish executing and in the case of the select * from articles not display the content inside the articles table?

resultin your console log instead ofquery.sqlresultand it does indeed output the resulting objects. Is the fact that theroot@goku-cp:home/goku/Desktop#isn't automatically repearing a problem? and if it isn't, how might I make it automatically come back