TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
durgaprasad rapolu
NA
57
9k
How to display the Mysql value out of the function in nodejs
Apr 18 2019 3:05 AM
I want to return a mysql value,and that value is stored in varible of out of the query
This is My code :
if (intent.intent==='Sales-1'){
var rsp = con.query("SELECT Mobiles from Salestb", function (err,result, fields) {
if (err) throw err;
Object.keys(result).forEach(function(key) {
var row = result[key];
console.log(row.Mobiles);
});
});
response.output.text = "This is the modified Output :"+ rsp;
}
But my output is [object Object]
Actually I want to output like this : This is the modified Output : 123456(some vale)
Reply
Answers (
2
)
Get the data from cloudant database
How to return the value out side of the query function nodjs