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
-
1
votes1
answer156
viewsHow to troubleshoot "3183" error importing a bank into SQLSERVER 2012
Good afternoon! First of all, I warn you, I’m a layperson. I need to run a local bank on my machine to work on a project. I installed the programs: SQLSERVER Express 2012 SQL Management Studio 2012…
-
1
votes1
answer152
viewsFirebird GEN_ID() function equivalence in ORACLE
Speak guys, I’m starting learning with BD Oracle, before I used Firebird. However I’m having a problem that I’m not able to solve. I can not include a new country by the system (java), if I insert…
-
1
votes0
answers123
viewsMS SQL Query for JSP
I’m creating a website based on the JSP language but I don’t know how to return a consultation which I did in the MSSQL Server, the same goes below: DECLARE @Nomes VARCHAR(8000) SELECT @Nomes =…
-
1
votes3
answers62
viewsGet only 1 of each journey
Well, I have a table called tabelajornadas. In it, I have several records, and in which I have the column jornada, who’s kind int. In it, they contain several records with the same number in the…
-
1
votes1
answer45
viewsDelete row from grid (BD) website C#
Good, I need a little help because I’m building a web page that shows BD data on a grid. I put the Update and delete button. I managed to change the BD via the web. But I’m having trouble deleting…
-
1
votes1
answer326
viewsSelect bestsellers in related table
I have a table pedidos, produtos and another produtos_em_pedidos described as follows: produtos: id | nome pedidos: id | data produtos_em_pedidos: produto_id | pedido_id | quantidade I need to…
-
1
votes0
answers201
viewsWhat is the difference between SELECT * AND SELECT field1,...?
If I need all fields in the table, there is a difference in performance between using the joker "*" (SELECT * FROM ...) and specify all fields in the table (SELECT campo1, campo2... FROM ...)?…
-
1
votes0
answers492
viewsStore contents of file . txt for a vector and vice versa
Good evening. I need to read a text file and store each book (Struct book) in an array of books. The code has functions to add, edit, delete and view in the array each book. I cannot properly save…
-
1
votes1
answer98
viewsHow to save sessions in the browser
How to record sessions in the browser with php. Currently I have a login system, and always validates [$_SESSIONS] existing in the browser, but every time I close and open the browser again, the…
-
1
votes1
answer263
viewsJavascript counter for php controller
I have a form with dynamic inputs: <form method="post" action="getDatabases/getCurso.php"> <div class="field_wrapper_curso"> <div class="col-md-12 contentCurso"> <div…
-
1
votes2
answers62
viewscensor a registered word in a database
Is there a way to censor and replace a word registered in Mysql through a precedent or Trigger for example? The word in the case would be Flash House and I need it replaced by Old School.…
-
1
votes3
answers1195
viewsConvert nvarchar(50) field to SQLSRV table datetime
I need to change a field in the SQL database table whose format is in nvarchar(50) and data were saved in date format 07/09/2017, containing values NULL also! I need to convert this field directly…
-
1
votes1
answer464
viewsMysql: Query Table N:N
Create database Banco default character set utf8 default collate utf8_general_ci; use Banco; create table Cadastrados( Nome varchar(50), Sexo enum('M', 'F'), Matricula varchar(9) unique, Curso…
-
1
votes1
answer462
viewsSQL SERVER 2008 R2 - TEMPDB ERROR
Good morning, by the way, does anyone know a solution to this mistake : Msg 8921, Level 16, State 1, Line 1 Check terminated. A failure was detected while collecting facts. Possibly tempdb out of…
-
1
votes2
answers3456
viewsGrant for several Oracle tables
I need to create a database user, where he can have permission from all DML, but when creating Grant I have to specify table by table, there is some way to give permission to the whole database,…
-
1
votes1
answer36
viewsDoubt in Table creation
Good Night, I am creating a database for an association, where it is necessary to do the renewal every semester. I created a registration table with the members data: create table Cadastrados( Nome…
-
1
votes2
answers1288
viewsHow to create 1:N relationship tables?
I’ve studied databases and understand how to diagram this type of relation, but now that I’m trying to implement this database using sqlite3 and python I’ve seen some problems. I have the following…
-
1
votes1
answer38
viewsHow to change a table indicating that data from a certain field can only vary from date 1 to date 2?
I have a table called "LOC_VEICULO" where the vehicle data are contained. I have the following field: DT_FABRICACAO (DATE), where the dates of manufacture of vehicles are stored. I need to change…
-
1
votes1
answer173
viewsInner Join in tables 1 - n
I have two tables: Vehicle and Images, where a vehicle can have n images. When performing an Inner Join I get the following result: Vehicles1-Addressimage Vehicles1-Addressimage…
-
1
votes1
answer785
viewsUnlink: No such file or directory
Hello, I was developing the pages and suddenly the following occurred Warning: Warning: unlink(upload/publicacoes/Empresa Demonstração…
-
1
votes1
answer177
viewsCreating a "match" system with days of the week and different periods between two matches
When I was doing a university project, I came across a problem that proved to be an obstacle. I need to create a system whose user is required to select days of the week and periods (night, day,…
-
1
votes2
answers1980
viewsGenerate Inserts from a populated table
I have a populated table and I need to generate the scripts of insert of the data stored in it, I cannot export, it has to be the script of insert into ... Do for select concatenating is very…
-
1
votes1
answer610
viewsDrop Inventory with SQL Triggers
I started doing a course on SQL and I’m in doubt about triggers this is the table create table Produto ( codProduto int primary key identity(1,1), Nome varchar(50), Quantidade int, Preco smallmoney…
-
1
votes1
answer252
viewsRunning a system command with parameter inside a Function in Postgresql
I’m having a hard time create a function in the Postgres execute a command shell linux, with one detail: it is a function in a Trigger after insert and I need to use some columns from NEW. In Mysql,…
-
1
votes1
answer1533
viewsSplit column into multiple rows (split)
I have a table cidade_bairro with several cities and neighborhoods. I want to transfer this data to a new table, but in several lines instead of being in one. EX: Cidade Bairros<br> SP |…
-
1
votes0
answers77
viewsExport data from Informix
I’m developing an application based on the data of an ERP. This ERP uses the INFORMIX database whose file export standard is BOUNDED BY PIPES AND WITHOUT TEXT RATING. I need to import Informix data…
-
1
votes0
answers70
viewsHow to save date (yyy-MM-dd) and time (hh:mm:ss) in Postgresql?
I need to store in the Postgresql database the date and time that a particular record has been changed or inserted, but when creating this column I was in doubt about which format to choose,…
-
1
votes1
answer448
viewsProblem connecting Access to Visualstudio
I created a small database in Access and I’m trying to make the connection with Visualstudio, but gives the following error message: Unrecognized database format 'c: Users wss desktop dbteste.accdb'…
-
1
votes0
answers1170
viewsPhpmyadmin does not open after sena default change
Good afternoon, everyone, After modifying the default Mysql password (In the Xampp interface), it no longer opens and displays the following error message: 1045 - Access denied for user…
-
1
votes1
answer2148
views -
1
votes1
answer79
viewsIs it possible to change a user-defined table type?
I created a kind of table to use in some procedures, and after creating the procedures, I realized that I need to change some of the column types. Is there any instruction to change a table type?…
-
1
votes1
answer812
viewsProblems with Phpexcel columns
I started to perform the development on my system to generate a file . xls in a very dynamic way. Where you receive the data from a page via POST, and are saved in variables, follow the code:…
-
1
votes2
answers444
viewsJoin returning many records
Hi, I’ve researched here about this error and I haven’t seen one that fits my problem, so my problem is that I have two tables, I need to get some information from table B and insert in the query…
-
1
votes2
answers1631
viewsForm making empty INSERT in Database
I am creating a simple registration page and created a Form to store what was typed in the Database. However, even with the validation of the Form in PHP to see if there is an empty field, when I…
-
1
votes3
answers196
viewsQuery listing the dates
Good night, How Query can get the following action in Postgresql: List the dates that fell on Sunday of the last 6 months based on the current date, regardless of the data in the database. NOTE: The…
-
1
votes0
answers158
viewsOracle physical database file
I’m having the same problem with that question : Where SQL Developer saves the BD file? more like I have no points to comment on, and ask right there, start a new "topic". I tried to do the way the…
-
1
votes0
answers182
viewsManage Paradox database with PHP 7
I have a program developed by third party and I need to manage his database, which is done in Paradox. I discovered the pxlib which, according to my research, should be compiled for the Windows. I…
-
1
votes0
answers124
views -
1
votes2
answers145
viewsProblems with Bake in Cakephp 3.x "Your database does not have any Tables."
Greetings! I’m trying to generate models, controllers and templates in a Cakephp 3.x project using the Postgresql database. I’ve already created the tables, set up the connection (which is working…
-
1
votes0
answers175
viewsInsert Sequential Number into column C#
I have this table called Articlebarcode: In the column Code I need to insert a sequential number, that is, I have to read the maximum number that is there and insert the next one that is available !…
-
1
votes1
answer83
viewsProcessing cost between code and database
Among the many forms of development, there was a doubt about what will consume the most of my processing between the same operation in different ways... If I have a function that can be done…
-
1
votes2
answers414
viewsIs there a security problem using the public schema in Postgresql?
First time I’m working with postgresql and I’m wondering if you have a security problem using the public Schema it creates ? Or if it’s just a matter of organization
-
1
votes1
answer1305
viewsMSSQL How to find out which table a record has been included or modified
There is a way to find out via query which table in a database has changed from Update or Insert?
-
1
votes0
answers319
views -
1
votes3
answers722
viewsHow to enter birth date in comic book?
How to enter date of birth in the comic book? Code taken from the form: $data = $_POST['dtn']; $dataP = explode('/', $data); $dataBd = $dataP[2].'-'.$dataP[1].'-'.$dataP[0]; function that sends the…
-
1
votes0
answers552
viewsHow to put an attribute as a foreign and primary key at the same time?
Utilise Mysql Workbench and I have to represent a DER in the physical model. I come across a specialization: TABELA_PESSOA cpf* nome sexo TABELA_CLIENTE cpf_pessoa* email senha TABELA_FUNCIONARIO…
-
1
votes1
answer4491
viewsSafe update error using stored Procedure in MYSQL
I am having trouble updating my stock table using a stored Procedure in MYSQL. Follows the code: CREATE DEFINER=`root`@`localhost` PROCEDURE `atualiza_estoque`(id_produto int) BEGIN update estoque e…
-
1
votes1
answer519
viewsWhat is the correct way to save an IP in the database?
How to save both IP types IPV4 and IPV6 in a Mysql database? What is the correct typing and column size? Any other remarks? I receive the IP through the $_SERVER['REMOTE_ADDR'] with PHP.…
-
1
votes1
answer28
viewsEqual fields Date between tables
In a table I have a Date A field in the format 'dd.mm.yyyy'. In another, date field B in the format yyyymmdd I want to search all fields where date A equals B
-
1
votes1
answer931
viewsComposite Key Table without repetition
How do I make a table with composite key, but I can’t repeat the combination of values. I want to store FRIENDSHIPS, using a syntax similar to is: tb_amizades id_usuario_um id_usuario_dois SELECT *…