moment sql date format code example Example: moment format sql date moment(new Date()). format("YYYY-MM-DD HH:mm:ss");