• Home
  • Blog
  • Campbellsville University Computer Science Database Programming Discussion

Campbellsville University Computer Science Database Programming Discussion

0 comments

Discussion 1 (Chapter 10): 

  1. List the three main approaches to database programming. 
  2. What are the advantages and disadvantages of each approach?
  3. Student 1:
  4. Embedded SQL Approach: The key advantage of this approach is that the query text is included in the application source code, so it can be checked for syntax issues and validated against the database schema during the compilation process. The main drawbacks are the lack of flexibility in modifying the query at runtime and the fact that all modifications to queries must be recompiled. Furthermore, because the queries are known ahead of time, selecting program variables to retain the query results is a simple operation, making application programming easier overall. The function call approach, on the other hand, will be better suitable for complicated applications where queries must be produced at runtime.Library of function call: This method offers greater flexibility because queries can be produced at runtime if necessary. However, because program variables that match the columns in the query result may not be known in advance, this leads to more difficult programming. There is no way to check queries at compile time because they are given as statement strings within function calls. All syntax and query validation must be performed at runtime, and the programmer must check for and account for any additional runtime mistakes in the program code.Database programming language approach: Because the programming language data types are the same as the database data types, this solution avoids the impedance mismatch problem. However, rather than using a language they are already familiar with, programmers must learn a new programming language. Furthermore, certain database programming languages are vendor-specific, whereas general-purpose programming languages may interact with systems from a variety of manufacturers with ease.
  5. Student 2:
  6. Database programming is the design and maintenance of a database for an application, whereas a database is an organized collection of information stored in a computer. Database program allows the creation of files, data entry, queries, updates, and reporting functions. There are three ways in which a database can be programed: incorporating general commands in a general-purpose programming language, creating an entirely new language and using a library of database functions. (Elmasri & Navathe, 2020). These methods have proven advantageous over the years; however, they are faced with some demerits as discussed. An embedded system has a better steady and higher speed (Griffins, 2020). It is faster to run an application using the embedded system; moreover, the running speed is steady, making it more efficient for the user. Also, an embedded system is less costly per bit of resultant, hence saving users’ money. However, for this system, it is harder to move information from one framework to another. Thus, it has caused a lot of inconveniences for users who want to move the information.The advantage of using a library of database functions is that: the functions are optimized for performance. Developers have ended up making the most efficient codes for functioning optimally to make the functions better. The library database functions are portable. They run similarly on any computer. However, higher conversion costs may be incurred since many functions are involved. Moreover, the library staff needs to adjust too many changes in a short period, thus making the process tedious.Designing a brand-new language is less costly since no expenses are incurred to translate the language since machine language is the only language that a computer understands (Davis, 2021). In addition, the language is easy to learn and understand. Contrary to its merits, there is partial control when using a new language since the database is not given full control due to hidden business rules. Moreover, some versions are costly; thus, some users cannot access them.ReferencesDavis, B. (2021, May 8). Home. MVOrganizing. Retrieved November 14, 2021, from https://www.mvorganizing.org/what-are-the-advantages-of-programming-language/. Elmasri, R., & Navathe, S. (2020). Fundamentals of Database Systems. Pearson Griffins. (2020, December 28). Advantages and disadvantages of embedded system. GeeksforGeeks. Retrieved November 14, 2021, from https://www.geeksforgeeks.org/advantages-and-disadvantages-of-embedded-system/. 

About the Author

Follow me


{"email":"Email address invalid","url":"Website address invalid","required":"Required field missing"}