Most voted "database" questions
A database (its abbreviation is BD, DB, database) is an organized collection of data typically used to model certain situations. Use this tag if you have questions about designing a database. If this is a specific database management system, like Mysql, for example, use this tag instead.
Learn more…3,414 questions
Sort by count of
-
20
votes1
answer1388
viewsWhat is a Nosql bank? How does it work?
I’ve heard a lot about Nosql database. Searching about it I found the following definition: Nosql (sometimes interpreted as Not Only SQL - Not Only SQL) is a generic term for a defined database…
-
20
votes2
answers9904
viewsWhat is the difference between clustered index and nonclustered index?
Studying about found a example, and about clustered says: Primary Keys by default use a grouped Dice (clustered), that is, when conducting a consultation select * from myTable where IDColumn = 1 ,…
-
19
votes3
answers9326
viewsIs it possible to use Sqlite as client-server?
There is any technique or tool to use Sqlite using an architecture Client-Server instead of local access? Of course you would need a client library to communicate with the server. And a server…
-
19
votes3
answers9682
viewsWhat’s the difference between Where and having?
Doing some tests on a database that in Mysql, I realized that: SELECT * From client WHERE uuid = '1kvsg4oracxq' returns the same result as: SELECT * From client HAVING uuid = '1kvsg4oracxq' What…
-
18
votes2
answers4057
viewsVocabulary of our language, where to find VOLP data?
The applications of complete and reliable dictionaries are immense (you don’t even have to choose them here!)... Our language, unlike English and many others without an "official reference", is…
-
18
votes3
answers437
viewsDatabase should follow the OO standard?
Object Orientation According to the Rules of Pure O, we have: "The Object must manipulate methods and attributes belonging only to it" That is, what does not strictly belong to class should be an…
-
18
votes1
answer8163
viewsWhat is a graph-based database?
I did not find on this site the answer to this question. So my question is basically this: What is a graph-based database?
-
18
votes2
answers4543
viewsWhat is an upsert?
I saw the term UPSERT in a blog and would like to better understand the functioning. It designates what type of operation? In which situations can be used? Has to do with idempotency?…
-
17
votes1
answer569
viewsWhat is Sargable argument?
In database queries what is the concept of a sargable argument (Search Argument Able)?
-
17
votes3
answers1699
viewsWhy doesn’t "= NULL" work?
In the SQL Server, by fetching all records with a given field with value NULL, if I do so no record is returned: SELECT * FROM clientes cli WHERE cli.cpf = NULL But if you use the following syntax:…
-
16
votes1
answer1772
viewsIs Nosql synonymous with an Object-Oriented Database?
Nosql is synonymous with Object-Oriented Database? If the answer is nay: What’s the difference between the two?
-
16
votes2
answers256
viewsHow to solve special situations of unnatural value for a domain?
The question has a slightly more conceptual bias, so I’m going to use a simple generic example. There are cases where some column may be in a special situation, this because an information: is not…
-
16
votes4
answers8313
viewsIs using addslashes against SQL injection safe?
Use the addslashes() is it really safe against SQL injection? If not, tell me why. I’ll wear mine like this addslashes() <?php $id = addslashes ( $_GET ["id"] ) ; /* Adicionei as barras */ echo…
-
16
votes2
answers673
viewsWhen and in which columns should indexes be used?
Reading an article that has nothing to do with database I came across information that use of indexes can bring great improvements to database performance. I have two questions about that: When…
-
16
votes1
answer1078
viewsWhat is the difference between the relationships between tables?
I know there are three types of relationships between data from different tables: 1 : 1 (one to one); 1 : N (one for several) ; N : N (several for several); But what would be the difference between…
-
16
votes3
answers44552
viewsHow to connect Python to Mysql database?
I wonder how I can make a simple connection to Mysql through a Python script. To do this I need to install some library? Or is there something that comes by default in Python (like in PHP)?…
-
15
votes3
answers22703
viewsWhen is the use of composite primary key recommended?
A key simple is associated with a single value, or field, of the record. A key composed corresponds to the combination of two or more keys, and may be required to eliminate ambiguity by forming a…
-
15
votes3
answers1209
viewsWhat is SQL? How to use?
I already know at least that SQL has relation with database, with the query of values in database. But it’s not clear what would be SQL. What would you use this resource for? And how do you use SQL,…
-
15
votes1
answer7144
viewsWhat is Data Warehouse and what are its advantages and disadvantages?
What is Data Warehouse and what are the advantages and disadvantages of using it.
-
15
votes1
answer1791
viewsHow to apply Dexes to improve the performance of the queries?
I’m looking to increase the performance of my database, which has over 1 million records. Research I have undertaken Sobre index link1 Cluster-wise link1 Link2 Doubt The idea of cluster it seemed…
-
15
votes3
answers5035
viewsWhen to use Sqlite?
When I should and should not use Sqlite? I have a project that I intend to do I have no idea how many tables will be, but I believe that more than 15 with about a thousand lines in some tables. It…
-
15
votes4
answers332
viewsIn relation to object orientation, should queries have a class of their own or can they stay in a specific class?
What I have is this: a user class and a connection class with the bank. I need to insert a user into a database, the query "insert into usuarios values (..)" should be in my user class or in the…
-
15
votes2
answers7839
viewsWhat is the difference between View and Materialized View?
According to Oracle documentation, a Materialized View is a database object that contains the results of a query and a View is a logical table based on one or more tables or views and does not…
-
15
votes1
answer3815
viewsWhat are the ideal use scenarios for Node.js?
The theme is broad, but I’ll try to focus on what I really need to understand. Lately I’ve been studying Node.js, and I’ve been surprised by the tool, in the comparative that I’ve seen, seems to be…
-
15
votes3
answers4552
viewsUse VARCHAR(255) for all fields or choose the best size for each field?
Assuming the following fields (for example): Nome, Rua, Cidade ,UF. The Nome would be the client’s name. There are people with 2 short names or people with 5 or more names, so it is possible to have…
-
14
votes4
answers1643
viewsIs it really necessary to define constraints in the database?
Ruby on Rails seems to have been thought of considering that it is not necessary to define constraints (as Foreign Keys) in the database, just define them via application. Usually the only…
-
14
votes3
answers2619
viewsCan subqueries decrease performance? Myth or truth?
Well, I usually just work with frameworks. I work with frameworks MVC and I usually use Orms to query the database. In my case I use Laravel, but I’ve used other frameworks, and had the opportunity…
-
14
votes3
answers3192
viewsWhat is the difference between Full Text Search and LIKE?
I’ve heard a lot about the term Full Text Search (FTS) lately, and I’ve been told that I should use this instead of drafting the queries with LIKE. But how to use the Full Text Search? What are the…
-
14
votes1
answer16891
viewsWhat does COLLATE LATIN1_GENERAL_CS_AI do?
I’m asking this question because I came across this reply by @Sorack; I didn’t understand what influence COLLATE LATIN1_GENERAL_CS_AI had the result, I’ve seen some answers here on Stackoverflow and…
-
14
votes4
answers2496
viewsPerformance of COUNT(*) and COUNT(1)
What’s the difference between COUNT(1) and COUNT(*) in an SQL query. For example: SELECT COUNT(1) FROM USUARIOS; and SELECT COUNT(*) FROM USUARIOS; Is there any difference of interactions within…
-
13
votes3
answers3561
viewsJava and Offline Databases
I need some help with a Java database. I want to make a database that the program generates a file, such as "database.db" and this file I can access without any internet connection, using only the…
-
13
votes1
answer8955
viewsInheritance in relational database
one of the great challenges in developing object-oriented software is to abstract the data from its base to power-like objects better manipulate them, today the available ORM frameworks make this…
-
13
votes4
answers1574
viewsDatabase and transaction control in value transactions
In my project I need to develop a system of transactions where the user will put credit and the services he hired will consume these credits. I built the following structure but I don’t know if it’s…
-
13
votes2
answers2784
viewsWhat is the argument limit of the IN operator in SQL Server?
In Oracle are 1000 arguments, which limit in SQL Server?
-
12
votes3
answers2560
viewsDatabase redundancies are always undesirable?
I am developing a system that keeps a record of all financial transactions occurring in a bank account (simple matches). There is a redundancy in my data model: a table saldo_conta keeps a list of…
-
12
votes3
answers1569
viewsHow to create multiple entries in an index based on columns in the same row?
I have never found a good way to index multiple columns of a row as index entries or simulate this feature in Mysql. The problem arises when you have fields working as tags or a similar concept.…
-
12
votes4
answers2869
viewsIs it recommended to use natural primary key?
Natural primary key is one that contains real data, not just a random value, but an integer. Example: // comum CREATE TABLE pessoas ( id INTEGER PRIMARY KEY, cpf INTEGER NOT NULL, // outros campos…
-
12
votes1
answer10002
viewsDifferences between Natural Join and Inner Join
What characteristics differentiate a consultation performed with the use of Natural Join other with the use of Inner Join? Is there any question related to performance or any other condition that…
-
12
votes2
answers15638
viewsWhat is the difference between Function and Procedure?
What are the differences between the two, and examples of where and generally are used.
-
12
votes1
answer2421
viewsWhat is the best way to store money in Sqlite?
Li that post on the lack of precision of double, and virtually every link in the post. Then I realized that this was a vulnerability of my software in production (since I have rounds to every corner…
-
12
votes2
answers23371
viewsHow does the BLOB field work?
Hello, directly asking, how does this kind of field work? I know there are three types: BLOB = 64KB, MEDIUMBLOB = 16MB and LONGBLOB = 4GB Given this example: CREATE TABLE COMPROMISSOS ( ID INTEGER…
-
12
votes1
answer6364
viewsWhat are the advantages of using object-oriented databases?
What are the advantages and disadvantages of using object-oriented databases in relation to relational databases? What are the most commonly used object-oriented databases?
-
11
votes4
answers3989
viewsHow the relationship between the same table works
Performance changes? (Compared to different tables) In which case it could be used? It is recommended?
-
11
votes3
answers3726
viewsWhat good is a "self Join"?
I would like an example for me to understand why I use a self relationship on the same table? I have intermediate knowledge in SQL but still do not understand Self Join.
-
11
votes2
answers2353
viewsWhen should I inactivate or delete a record? Good database practices
I have the following doubt: When should I inactivate a record? When should I delete a record? In case you would like a good practice tip, in which tables it pays to create a STATUS column? Being the…
-
11
votes1
answer385
viewsIs the C# language recommended to be distributed online with a database?
It is very easy to get the entire code of a C# program using . NET Reflector. Would it be possible for me to put the same security in a C# program a program made in C++? I found that answer no Stack…
-
11
votes3
answers1682
viewsIs it common to have multiple different servers for the same web application?
Setting: I’m starting to participate in the development of a web application. This application is not yet available "online", IE, we only have it here on the test server where we have, on the same…
-
11
votes1
answer1183
viewsWhat is a collation?
I never knew exactly what it meant. I know it has to do with the coding of the data that will be entered in the table, but in addition, there is some more specific reason to select a collation? I…
-
11
votes2
answers435
viewsWhat characterizes a database?
What makes a data collection to be called a database? For example, if I have a file pessoas.txt as follows: Vinicius João Maria José And I write, read and update the data there, it is considered a…
-
11
votes1
answer8640
viewsLimit and Offset for Web Paging in SQL Server
I am working with PHP and have about 8000 records currently on DB. As it is for a web page, I need to make a pagination to be able to read the data. From what I understand, I have to do something…