stud
bud
Sign up
Log in
Home
Library
Explore
SAT
More
DigitalCrafts Quiz #2 Review Flashcards | StudBud
Explore
/
DigitalCrafts Quiz #2 Review
DigitalCrafts Quiz #2 Review
13 terms
·
StudBud Administration
·
13 plays
A review of #programming concepts including #SQL, #npm, #Nodejs, #websocket
Flashcards
13 cards
F
Practice quiz
P
Host live
L
Questions
13
Answers
1
Which hash function is suitable for storing passwords?
ROT13
Base-64
MD5
PBKDF2
2
What command loads the NPM module named "express" into your app?
var express = require('express')
import express
var express = use('express')
import 'express'
3
What does SQL stand for?
Simple Query Language
Strong Question Language
Structured Query Language
Structured Question Language
4
With SQL, how can you return the number of records in the "Persons" table?
SELECT LEN(*) FROM Persons
SELECT COLUMNS(*) FROM Persons
SELECT NO(*) FROM Persons
SELECT COUNT(*) FROM Persons
5
Which SQL statement is used to extract data from a database?
SELECT
GET
EXTRACT
OPEN
6
What type of function is used to encrypt a password?
Hash Function
SSL Function
Salt Function
HTTPS Function
7
Select records from a table "Persons" where the value of column "FirstName" is "Peter"
SELECT * FROM Persons WHERE FirstName='Peter'
SELECT [all] FROM Persons WHERE FirstName LIKE 'Peter'
SELECT [all] FROM Persons WHERE FirstName='Peter'
SELECT * FROM Persons WHERE FirstName<>'Peter'
8
Which express statement will get the value of the form input named "username" through POST?
let username = response.body.username
let username = request.params.username
let username = request.body.username
let username = request.query.username
9
How do we safeguard against SQL injection?
db.any(`SELECT ${name}`)
db.any('select $1 $2', [param1, param2])
db.any("SELECT ${name}", {name: 'eric'})
use Mongo
10
Which SQL statement is used to return only different values?
SELECT DISTINCT
SELECT UNIQUE
SELECT
SELECT DIFFERENT
11
What command installs an NPM module named 'express'?
npm install express
npm init express
npm get express
apt-get express
12
Which express statement will get a query parameter named "searchTerm"?
let param = request.body.searchTerm
let param = request.searchTerm
let param = request.query.searchTerm
let param = request.params.searchTerm
13
With SQL, how do you select a column named "FirstName" from a table named "Persons"?
EXTRACT FirstName FROM Persons
SELECT Persons.FirstName
SELECT FirstName FROM Persons
SELECT Persons FROM FirstName