Write a program within embedded sql to associative relation, Database Management System

Assignment Help:

Write a program within embedded SQL to associative the total trip expenses of the salesman named ‘John' for the relations.

EXEC SQL BEGIN DECLARE SECTION;
long total_expenses;
EXEC SQL END DECLARE SECTION;
EXEC SQL
SELECT SUM(AMOUNT) INTO :total_expenses FROM EXPENSE WHERE TRIPID
IN (SELECT TRIP_ID FROM TRIP
WHERE SSN = (SELECT SSN FROM SALEPERSON WHERE NAME = ‘John'));
printf("\nThe total trip expenses of the salesman John is: %ld", total_expenses);


Related Discussions:- Write a program within embedded sql to associative relation

Optimistic concurrency contents -write-set(t), write-set(T): Each data ite...

write-set(T): Each data items that are written by a transaction T

What is association, What is association? Give an example of association ...

What is association? Give an example of association Association is used for establishing relationships among classes. Association describe links among/between classes. For exa

Division operation, To do the division operation R1 ÷ R2, R2 should be a co...

To do the division operation R1 ÷ R2, R2 should be a correct subset of R1. In the following example R1 have attributes A and B and R2 have only attribute B so R2 is a correct subse

Discuss the term- design optimization, Discuss the term- Design Optimizatio...

Discuss the term- Design Optimization  We have seen various ways of representing the objects.The fundamental design model uses analysis model as the framework for implementati

Disadvantages or unsecure, In Database software have only pure security or ...

In Database software have only pure security or some dis secured by administrator?

Explain the term- signal-to-noise ratio, Explain the term- signal-to-noise ...

Explain the term- signal-to-noise ratio A signal-to-noise ratio of 20 dB means that S/N = 100. As log2101 is around 6.658, the Shannon limit is around 19.975 kbps. The Nyquist

Explain er model, Question 1 Explain ER model Question 2 What are the...

Question 1 Explain ER model Question 2 What are the characteristics of a computer provided information? Question 3 What are facts and guidelines to be considered when se

What does conceptual design work, What does conceptual design work? A c...

What does conceptual design work? A conceptual design involves modelling independent of the DBMS.

Explain the function of object model, Explain the function of Object model ...

Explain the function of Object model Object model describes the classes of objects in system, including their attributes and operations which they support. The analysis object

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd