1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
olasank [31]
2 years ago
15

Use ONE SQL statement to show the total number of actual hours for each customer. In the output, show customer id and the total

number of actual hours for each customer.
Computers and Technology
1 answer:
valkas [14]2 years ago
7 0

Explanation:

SELECT  

   distributor_id,  

   COUNT(*) AS TOTAL,  

   COUNT(IF(level='exec',1,null)),

   COUNT(IF(level='personal',1,null))

FROM sometable;

You might be interested in
Create a Double complementary or tetradic colors (are a set of two complementary pairs of colors that form a rectangle on the co
hjlf

Answer:

(Remember, two colors are complementary if they are opposite each other ... colors are connected on the color wheel they form a rectangle.

Explanation:

best one i could find if worng am verys very sorry.

4 0
2 years ago
Read 2 more answers
Write a C program to prform simple C aritlimetic calculations. The user is to enter a simple expression(integer operaior integer
larisa86 [58]

Answer:

Here is the C program:

#include <stdio.h>  //to use input output functions

//functions prototype

unsigned int mod(unsigned int a, unsigned int b);  

unsigned int mul(unsigned int a, unsigned int b);  

unsigned int sub( unsigned int a,unsigned int b);

float divide(unsigned int a,unsigned int b);  

unsigned int add( unsigned int a,unsigned int b);  

int main()  {  //start of main method

unsigned int a, b;   //declare variables to store the operands

char d;  //declare variable to store the operator

printf("Enter an operator:  ");   //prompts user to enter an operator

scanf("%c",&d);  //reads the operator from use

getchar();  //gets a character

while (d!='q')   { //keeps iterating until user enters q to quit

printf("Enter 1st operand: ");   //prompts user to enter first operand

scanf("%d",&a);   //reads first operand from user

getchar();  //reads character

printf("Enter 2nd operand: ");   //prompts user to enter second operand

scanf("%d",&b);   //reads second operand from user

getchar();  

if (d=='%')  {   //if the character of operator is a mod

printf("%d",a);  //prints operand 1

putchar(d);  //displays operator

printf("%d",b);  //displays operand 2

printf(" = ");  //displays =

mod(a,b);  }  //displays computed modulo of two input operands

if (d=='*')   //if the input character is for multiplication operator

{printf("%d",a);  //prints operand 1

putchar(d);  //displays operator

printf("%d",b);  //displays operand 2

printf(" = ");  //displays =

mul(a,b); }  //displays computed multiplication

if (d=='+')  {  //if the input character is for addition operator

printf("%d",a);  //prints operand 1

putchar(d);  //displays operator

printf("%d",b);  //displays operand 2

printf(" = "); // displays =

add(a,b);  }   //displays computed addition

if (d=='/')  {  //if the input character is for division operator

printf("%d",a); // prints operand 1

putchar(d);  //displays operator

printf("%d",b);  //displays operand 2

printf(" = ");  //displays =

divide(a,b);  }   //displays computed division

if (d=='-')  {  //if the input character is for subtraction operator

printf("%d",a);  //prints operand 1

putchar(d);  //displays operator

printf("%d",b); // displays operand 2

printf(" = ");  //displays =

sub(a,b);  }  //displays computed subtraction

printf("Enter an operator: ");   //asks again to enter an operator

scanf("%c",&d);  //reads operator from user

getchar();  }  }   //gets character

unsigned int mod( unsigned int a, unsigned int b){  //function to compute modulo of two integers with no sign

     int c = a%b;  //computes mod

    printf("%d",c);  }  //displays mod result

unsigned int add(unsigned int a, unsigned int b){     // function to compute addition of two integers

    int c = a+b; //computes addition

    printf("%d\n",c);  } //displays result of addition

unsigned int mul(unsigned int a, unsigned int b){       //function to compute multiplication of two integers

    int c = a*b;  //multiplies two integers

   printf("%d\n",c); }  //displays result of multiplication

float divide(unsigned int a, unsigned int b){   //function to compute division of two integers

    float c = a/b;  //divides two integers and stores result in floating point variable c

    printf("%f\n",c);  } //displays result of division

unsigned int sub(unsigned int a, unsigned int b){       //function to compute subtraction of two integers

    int c = a-b;  //subtracts two integers

    printf("%d\n",c);  }  //displays result of subtraction

Explanation:

The program is well explained in the comments mentioned with each line of the program. The program uses while loop that keeps asking user to select an operator and two operands to perform arithmetic calculations. The if conditions are used to check what arithmetic calculation is to be performed based on user choice of operand and calls the relevant function to perform calculation. There are five functions that perform addition, modulo, subtraction, division and multiplication and display the result of computation. The screenshot of output is attached.

4 0
3 years ago
A voltage measurement error is caused by the integration time window of a digital volt-meter. This is a _____________error.
gladu [14]

Answer: Systematic error

Explanation:

  The systematic error is the type of error which is basically caused due to the integration time of the digital volt meter in the voltage error measurement.

It is one of the type of error that occur during the measurement of the voltage due to mismatch start channel. It basically result into the difference between the fall and rise in channel and the difference in the propagation delay.

The systematic error is basically introduce by interconnect different types of cable and setting the triggering level in the system. This type of error are constant in the given measurement configuration process.

4 0
3 years ago
Explain the risks to privacy from collecting and storing personal data on computer systems and the programmer’s role to safeguar
Deffense [45]

Answer:

The risks is If your computer is stolen, someone  could get the data and If your laptop messes up you will you lose all the data.

Explanation:

7 0
2 years ago
A B-tree can be ____ in three ways: inorder, preorder, and postorder.
Harman [31]

Answer:

traversed

Explanation:

B-tree is a self balancing tree and it is a data structure which allows insertion, deletion operations.

inorder, preorder and post order, they all are traversing algorithms in the tree data structure.

inorder: first print left, then root and then right.

preorder: first print root, then left and then right.

postorder: first print left, then right and then root.

Therefore, the answer is traversed.

4 0
3 years ago
Other questions:
  • The max-age attribute of a cookie is specified in
    13·1 answer
  • Which printout will result from the snippet of code?
    9·1 answer
  • X = 0
    15·1 answer
  • Define
    15·1 answer
  • Why did latex replace wax?
    7·1 answer
  • Omega Software Inc. is currently running a training program for employees to upgrade their software skills so that they are able
    10·1 answer
  • Sam has created a fashion website. There are many subscribers to his website. He has added new blogs, pictures, and articles abo
    13·1 answer
  • Most airlines use very modern hardware and software.<br><br><br> True<br><br> False
    9·1 answer
  • Write an application that displays the strings in the provided array alphabetically in ascending order.
    9·1 answer
  • To have a reason or purpose to do something
    8·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!