Questions tagged as 'mysql'

0
answers

Join of two sql commands

Hello, I would like to join two SQL commands, which are: SELECT DATE_FORMAT(data_os, '%d/%m/%Y %H:%i') FROM tbos e: SELECT* FROM tbos WHERE os =     
asked by 02.04.2018 / 22:13
1
answer

The more you want in MySQL the greater the consumption?

I am developing a website and my code is using many queries / queries in MySQL at once, I am trying to decrease these queries to the smallest number since I think the more queries the more resources will be consumed, am I right? > Example 1:...
asked by 02.03.2017 / 01:31
1
answer

Catch last id inserted in mysql with php [duplicate]

I have the following query of inclusion of registers mysqli_query($conexao,"INSERT into cadastro set nome='$nome',telefone='$fone',cep='$cep',secao='$categoria'"); How do I not have to give a select in the last inserted data to get the ge...
asked by 06.09.2016 / 17:55
1
answer

Can not add foreign key constraint

Help with error in MySql create table cliente( endereco varchar(256), codigo integer primary key auto_increment, telefone varchar (18), tipo varchar(20) ); create table fisica( cpf varchar(20), foreign key(cpf)...
asked by 09.10.2018 / 02:20
1
answer

index.php blocking server

Good afternoon, I downloaded a free PHP script with open source code and put it in my server's folder But when I enter the index.php page it opens normal, but when I open it again it does not load and gives "server error" and it blocks my ser...
asked by 14.02.2018 / 21:33
1
answer

Store select value fed by SQL and change WHERE search

I need the user to select a date in the combo box, change the value of the variable corresponding to the period in WHERE, so that it shows the table only of the corresponding period. SELECT <select id="data"> <?php $data = my...
asked by 14.02.2018 / 16:30
1
answer

INSERT and INNER JOIN together in MySQL?

Hello, is it possible to use INNER JOIN together with INSERT ? I have a table A with 3 columns X, Y and Z and table B with columns W, X and Y and I need to insert table W in table A, column W? I'm trying this way but I get no res...
asked by 22.03.2018 / 18:21
1
answer

Executing PHP commands saved in MySQL

I would like to know how to save and execute PHP code saved in my MySQL database. I have already created a basic structure for the instruction register. My question is about how to handle the use of these codes. For example, I created an 'Instru...
asked by 21.03.2018 / 13:37
1
answer

Problem with Mask of CNPJ in the print in the database (solved)

This is the class that validates the CNPJ: package br.com.Sistema.meuProjeto; import java.util.InputMismatchException; public class ValidaCNPJ { public static boolean isCNPJ(String cnpjFornec) { // considera-se erro CNPJ's formados por um...
asked by 10.08.2018 / 01:05
1
answer

Fill in the table with bank data. (Mysql and Bootstrap 4.1)

Save folks, I'm trying to populate a table with data coming directly from the database (Mysql). I'm new to the web, I've been able to put together an outline of what I'm trying to do. If anyone can give you some tips, I would be extremely gratef...
asked by 27.07.2018 / 21:11