In a real-world environment, changing granularity requirements might dictate changes in primary key selection, and those changes might ultimately require the use of surrogate keys.
Explanation:
A surrogate key is a unique identity as an object or entity. It is used as an object in the database and as an entity in the modern world. Surrogate key is not a natural key hence it cannot be derived from application data.
Advantages of using surrogate key:
- They are unique
- They have uniform rules
- It allows unlimited values
- It stands the test of time
Answer:
False
Explanation:
If one of the data values being entered into a table by the INSERT command violates an existing constraint, the database raises an error and none of the records aimed in the insert command is added.
Thus, in insert command syntax and column specifications has to be met in order to add any values being entered.
Answer:
Following are the definition of function
double averager (const double &x) // function definition
{
static double z = 0.0; // variable declaration
static size_t c = 0;
c=c+1; // increment of c by 1
z =z+ x; // adding value
return z /c ; // return average
}
Explanation:
Following are the description of statement
- Create a function averager of double type that holds a parameter "x" of the double type .
- In this function we declared a variable "z" of a static double type that value is initialized by 0.
- The static variable is used to retain value.
- Declared a variable "c" of size_t type that holds a value 0 .
- After that increment the value of c by 1 .
- adding the value of "z" variable to the "x" and storing the result into the z variable.
- Finally return the average value
Answer:
The answer is "Option E".
Explanation:
It is also known as the brand stretching, it is a marketing technique where a business selling a brand with a well-designed logo using that same brand name inside another market segment. They find the new item a turn-off, and wrong choices can be described as follows:
- In option A, It is wrong because it is an existing business model.
- In option B, It is wrong because it is a brand name.
- In option C, It is a device that, works on multiple tables, that's why it is incorrect
- In option D, It is also known as the model, that provides rules to stabilized the firms, that's why it is incorrect
Answer:
#include <iostream>
using namespace std;
int main()
{
cout<< rand() % 50 + 100 <<endl;
cout<<rand() % 50 + 100 <<endl;
return 0;
}
Explanation:
The rand() gives you a random number. If you use rand() % 50, it will give you a random number between 0 and 49. Since we are required to have the numbers between 100 and 149, add 100 to this expression. This way, you will have a random number between 100 and 149. Type this expression two times and use "endl" to end with a new line.