# Node js program using if else if statement
var a = 'route 1';
if (a === 'route 1'){
console.log ('Route is 1');
}else if ( a === 'route 2') {
console.log ('Route is 2');
}else {
console.log ( 'No Route');
}
# Node js program using if else if statement
var a = 'route 1';
if (a === 'route 1'){
console.log ('Route is 1');
}else if ( a === 'route 2') {
console.log ('Route is 2');
}else {
console.log ( 'No Route');
}
var mysql = require('mysql');
var con = mysql.createConnection({ host: "localhost", user: "admin", password: "admin" });
con.connect(function(err) {
if (err)
throw err;
console.log("Connected!");
con.query("CREATE DATABASE cprogramcodes", function (err, result) {
if (err)
throw err;
console.log("Database created");
});
});
DECLARE a number; b number; c number;
PROCEDURE findMinimum(x IN number, y IN number, z OUT number) IS
BEGIN
IF x < y
THEN z:= x;
ELSE
z:= y;
END IF;
END;
BEGIN
a:= 12;
b:= 13;
findMinimum(a, b, c);
dbms_output.put_line(' Minimum of (12, 13) : ' || c);
END;
/
EXECUTE beginner;