Skip to content
Advertisement

Tag: node.js

Merge Null Values in Merge Command

i must merge multible database tables in a node js windows service. so i decided to write a method that creates a sql string for this. here is my method: this method and the created sql string works nice, expect in one case. if the value in the source table column is NULL the target will not be updated. here

Datetime changing on JSON response

I am selecting start and end date of a project from project_stage named table. Here is the table elements Here datatype is DATETIME Here is the code Result on JSON response Here date time is changing its not the actual datetime which is in the table,why the date is changing on result.Here is the expected output Expected Result MYSQL DATATYPE

Get all tables data with Node.js and SQLite

Having these tables into a db: Athlete with fields: athlete_id, name, surname, date_of_birth, height, weight, bio, photo_id AthletePhoto with fields: photo_id, photo, mime_type AthleteResult with fields: athlete_id, gold, silver, bronze Game with fields: game_id, city, year The db model: The code so far can only send data for one of the tables: so it uses that query: SELECT athlete_id, name,

Advertisement