answersLogoWhite

0

📱

Database Programming

Databases are collections of tables that maintain and display information, often collaboratively; this information can be used for interaction with an application or gaining general knowledge. Questions about database engines and modifying or using them belong in this category.

8,803 Questions

What is the difference between a Primary Key and a Secondary Key?

A Primary Key is a unique identifier for each record in a database table and is used to enforce entity integrity. A Secondary Key is a non-unique index that is used for querying and organizing data efficiently but does not have the constraint of uniqueness.

Which places use a database?

Places like banks, universities, hospitals, e-commerce websites, and social media platforms typically use databases to store and manage large amounts of data efficiently. This allows them to retrieve and update information quickly and securely.

Advantages of hierarchical paging?

Hierarchical paging can offer more efficient memory management by organizing the page table in a hierarchical structure, reducing the memory overhead compared to a single-level page table. It allows for better utilization of memory resources by only mapping the necessary page table entries in the page table, which helps in reducing the total number of page table entries needed. Additionally, hierarchical paging can improve the speed of address translation by enabling faster access to the necessary page table entries.

What are the qualities of a good information system?

A good information system should be reliable, accurate, secure, user-friendly, and timely. It should also be able to efficiently collect, store, process, and distribute information to support the organization's goals and decision-making processes.

Define what is a database?

A database is a structured collection of data that is organized for easy access, retrieval, and management. It stores information in tables, which can be interconnected to efficiently store and access data. Databases are used to manage and manipulate large volumes of data in various applications.

What are the advantages and disadvantages of SQL?

ADV

1. View the data without storing the data into the object.

2. Restrict the view of a table i.e. Can hide some of columns in the tables.

3. Join two or more tables and show it as one object to user.

4. Restrict the access of a table so that nobody can insert the rows into the table.

DISADV

1. Can not use DML operations on this.

2. When table is dropped view becomes inactive.. It depends on the table objects.

3. It is an object so it occupies space

What is query processor in distributed dbms?

The query processor in a distributed DBMS is responsible for receiving and analyzing queries from users or applications, determining how to execute the query across multiple distributed nodes, and coordinating the execution of the query to retrieve the desired data efficiently. It optimizes query performance by considering factors such as data distribution, network latency, and data transfer costs across distributed nodes.

What information is put on a database?

A database typically stores structured data such as customer information, product details, financial records, and inventory levels. It can also store unstructured data like images, text documents, and multimedia files. The specific information stored on a database will vary based on the organization's needs.

Concept of data independence?

Data independence is a form of database management that keeps data separated from all programs that make use of the data. As a cornerstone for the idea of a DBMS or database management system, data independence ensures that the data cannot be redefined or reorganized by any of the programs that make use of the data. In this manner, the dataremains accessible, but is also stable and cannot be corrupted by the applications using it.

How do you link two tables that are in the same database?

You can link them using Keys. You have different kinds of keys like Foreign key, super key etc.

Foreign key - a foreign key (FK) is a field or group of fields in a database record that points to a key field or group of fields forming a key of another database record in some (usually different) table. Usually a foreign key in one table refers to the primary key (PK) of another table. This way references can be made to link information together and it is an essential part of database normalization

Superkey - A superkey is defined in the relational model as a set of attributes of a relation variable (relvar) for which it holds that in all relations assigned to that variable there are no two distinct tuples (rows) that have the same values for the attributes in this set. Equivalently a superkey can also be defined as a set of attributes of a relvar upon which all attributes of the relvar are functionally dependent.

How do database Record and Field relate to each other?

A database record can be considered as one row of data from a table whereas each piece of information in it is a field.

Let me explain with an example

consider the below table.

Emp name Emp num Age City

AAA 101 28 Charlotte

BBB 102 35 Newyork

In the above table one row of information about the employee AAA is a record and the fields are employee name, number, age and city.

What is the difference between union and intersect operations in SQL?

* The UNION operator combines the output of two query expressions into a single result set. Query expressions are executed independently, and their output is combined into a single result table. * The EXCEPT operator evaluates the output of two query expressions and returns the difference between the results. The result set contains all rows returned from the first query expression except those rows that are also returned from the second query expression. * The INTERSECT operator evaluates the output of two query expressions and returns only the rows common to each.

What are the streghths and weakness of the media dependency theory?

Strengths: The theory helps understand the influence of media on individuals and society, highlighting the power dynamics at play. It emphasizes the importance of media in shaping opinions and behaviors.

Weaknesses: The theory oversimplifies complex relationships between media and audiences, neglecting individual agency and other factors that influence media consumption. It can be criticized for being deterministic and not accounting for varying levels of media influence.

Difference between mis and data processing?

MIS (Management Information Systems) refers to the use of information systems to aid in managerial decision-making. It involves the collection, processing, and analysis of data to generate meaningful information for management.

Data processing, on the other hand, is a broader term that refers to the manipulation and transformation of data to produce useful information. It includes activities such as data entry, validation, sorting, summarizing, and generating reports. MIS is a specific application of data processing within a managerial context.

A criteria that searches for fields that are not empty is called?

A criteria that searches for fields that are not empty is called a "not null" criteria. This criteria is used to filter out records where a specific field does not have a null or empty value.

What is the difference between oodbms and ordbms?

Object-oriented database management systems (OODBMS) store data in a way that aligns with object-oriented programming concepts, allowing for complex data structures and relationships to be easily represented. On the other hand, object-relational database management systems (ORDBMS) combine relational database capabilities with object-oriented features, enabling users to work with both traditional relational data and more complex data types. ORDBMS often use SQL as the query language, whereas OODBMS may use object query languages.

What are the advantages of system theory?

System theory provides a holistic perspective, allowing for the examination of complex interactions among components within a system. It helps in understanding the interdependencies and relationships within systems, facilitating effective problem-solving and decision-making. Additionally, system theory emphasizes feedback mechanisms, enabling systems to adapt and evolve in dynamic environments.

What can you do with SQL?

SQL is used to communicate with and manage databases. You can use it to retrieve, insert, update, and delete data from databases. It is also used for creating tables, views, functions, and stored procedures.

What are the different modules in data warehousing?

1. Data Marts design(Modelling) -- contains dimension and fact tables

2. ETL (extract transform load) -- how to load data from multiple db to datamart with transformation logic. e.g. using Informatica, Microsoft SSIS, Data Stage

3. Business Intelligence - Reporting e.g. BO,Cognos etc

What does a database contain?

A database contains structured data organized in tables to store and manage information efficiently. It typically includes fields for different data types, rows for individual records, and relationships between tables to establish data integrity. The data can be retrieved, manipulated, and queried using database management systems.

Why is it important to maintain data integrity?

Maintaining data integrity is important to ensure that data is accurate, consistent, and reliable. It helps in making informed decisions, building trust with stakeholders, and complying with regulations. Without data integrity, there is a risk of making errors, misleading analysis, and damaging the reputation of the organization.

What the differences between primary key and foreign key?

A primary key is a special case of unique keys which doesnt accept duplicates. The difference between unique keys is that "NOT NULL" constraint is not automatically enforced, while for primary keys it is mandatory

Unique keys and primary keys can be referenced by foreign keys

What is sql loader?

SQL LOADER is an Oracle utility used to load data into table given a datafile which has the records that need to be loaded. SQL*Loader takes data file, as well as a control file, to insert data into the table. When a Control file is executed, it can create Three (3) files called a log file, bad file or reject file, discard file. * Log file tells you the state of the tables and indexes and the number of logical records already read from the input datafile. This information can be used to resume the load where it left off. * Bad file or reject file gives you the records that were rejected because of formatting errors or because they caused Oracle errors. * Discard filespecifies the records that do not meet any of the loading criteria like when any of the WHEN clauses specified in the control file. These records differ from rejected records.

What are the advantages of SQL?

SQL allows for easy access and retrieval of large amounts of data, provides a standardized language for interacting with databases, and offers powerful tools for data manipulation and analysis. Additionally, SQL supports data integrity and security features to ensure reliable and secure data management.

Discuss the main categories of data models?

Conceptual(high-level, semantic ) data models:

Provide concepts that are close to the way many user perceive data.

Physical(low -level, internal) data models:

Provide concepts that describe details of how data is stored in the computer.

Implementation(representational) data models:

Provide concepts that fall between the above two, used by many commercial DBMS Implementation.