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
Paraphin [41]
3 years ago
14

Create a trigger that prevents anychange(insert, update, or delete)to the grade attribute of the takesrelation that would change

the total credits of the corresponding student by more than 10 credits. For example, if thecurrent total credits of Sanchez are38, then any change that makes histotal credits greater than 48 or less than 28 would be prevented.b)(10points)Test thetrigger with three distinct events: one insert, one update, and one delete
Computers and Technology
1 answer:
Alchen [17]3 years ago
5 0

Answer:

The trigger code is given below

create trigger F1_Del

after delete on Friend

for each row

when exists (select * from Friend

where ID1 = Old.ID2 and ID2 = Old.ID1)

begin

delete from Friend

where (ID1 = Old.ID2 and ID2 = Old.ID1);

end

create trigger F1_Insert

after insert on Friend

for each row

when not exists (select * from Friend

where ID1 = New.ID2 and ID2 = New.ID1)

begin

insert into Friend values (New.ID2, New.ID1);

end

You might be interested in
This project involves writing a program that encodes and decodes messages. The program should prompt the user to select whether
Lilit [14]

Answer:

See explaination

Explanation:

import java.util.Scanner;

public class EncodeDecodeMessage {

public static String encode(String str) {

String result = "";

char ch;

for(int i = 0; i < str.length(); ++i) {

ch = str.charAt(i);

if(Character.isLowerCase(ch)) {

result += (char)('a' + (25-ch+'a'));

} else if(Character.isUpperCase(ch)) {

result += (char)('A' + (25-ch+'A'));

} else {

result += ch;

}

}

return result;

}

public static String decode(String str) {

return encode(str); // since the scheme is same, we can use encode for decode

}

public static void main(String[] args) {

Scanner in = new Scanner(System.in);

System.out.print("1. Encode, 2. Decode. Enter your choice: ");

int choice = in.nextInt();

in.nextLine();

if(choice == 1) {

System.out.print("Enter sentence to encode: ");

String line = in.nextLine();

System.out.println("Encoded string is: " + encode(line));

} else if(choice == 2) {

System.out.print("Enter sentence to decode: ");

String line = in.nextLine();

System.out.println("Decoded string is: " + decode(line));

}

}

}

8 0
3 years ago
Kerry wants to save her file but give it a new name. Kerry should use the ____ command
nexus9112 [7]

Kerry should use the "save as" command.

7 0
3 years ago
How does hardware differ from software
joja [24]

Answer:

hardware is a physical installation while software is onling and not a physical thing u can touch u know?

4 0
3 years ago
The _____ is the button that you push to take a photograph. i think its B Help PLZ
Sati [7]

Answer:

C

Explanation:

see the image on this web site as example: https://www.digitaltrends.com/photography/what-does-this-do-an-explanation-of-dslr-buttons/

4 0
3 years ago
A _____ model is one that is automatically adjusted based on changing relationships among variables.
BabaBlast [244]

Answer: dynamically modified model

Explanation:

7 0
2 years ago
Other questions:
  • I have Mac(the last version installed) and I use Wine (application for using windows files, programmes on mac) but I have some p
    6·1 answer
  • Operating systems are designed to work with specific hardware. Which operating system works with Apple computers?
    8·2 answers
  • Case project 5-1 Network Integration ​
    5·1 answer
  • I have two questions: 1: how do you credit only 5 points on brainl? (mine is only letting me give 10) and 2. How do I get a bria
    6·2 answers
  • Answer the following questions:
    7·1 answer
  • If you write a toString method to display the contents of an object, object1, for a class, Class1, then the following two statem
    7·1 answer
  • What technology would it take to make a balloon that doesn't pop?
    6·1 answer
  • Write a C function which takes three parameters which are the cost for an item in a grocery store, the quantity to buy, and the
    12·2 answers
  • What could be done to make sure that people follow copy right laws?
    13·2 answers
  • True or False? Popular sites are always mean accurate
    12·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!