Questions tagged as 'sql'

2
answers

Error: Column count does not match value count at row 1

include "config_db.php"; $sql = "INSERT INTO tb_produto (NOME_PROD,DESC_PROD,VALOR_PROD,VL_COMP_PROD,STATUS_PROD,COD_CAT,TAM_PROD,COR_PROD,COD_BARRA_PROD,ID_FORN,MAT_FUNC, QTD_PROD,FT_PRODUTO)VALUES('$nome',$desc,$val,$vld,'$status',$cat,'$ta...
asked by 15.11.2017 / 15:36
1
answer

Convert table data to UTF8

In my table there are characters in Japanese, Korean and Chinese, but they are not converted, when I echo with php, so it shows ?????? , In my doubt would be, how can I convert the DATA of this table? the table is already in utf8_...
asked by 16.11.2017 / 15:48
0
answers

PL / SQL - Trigger: Can I see the entire row updated in a row after trigger?

I am studying PL / SQL in college and the teacher has passed some questions based on Oracle's own Human Resources model. The question I am asking asks for a trigger that prevents an employee from having a salary greater than his boss. And for th...
asked by 12.11.2017 / 07:15
0
answers

8000 character limit in ASP Classic / SQL server

Dear friends, I'm trying to make an update to a table in SQL Server 2008 R2, but the field writes only 8000 characters. The column is set to 'text', but I already tried to change it to 'varchar (max)' without success. I've also used 'ca...
asked by 22.11.2017 / 19:01
2
answers

Conditions in SQL

Hello, I have a question in SQL. In the company's system there are several products registered, and these products have different sales unit, ie some are sold by Package, Box, Unit and etc ... Every product is sold for UNIT = 1, but there are pr...
asked by 13.12.2017 / 00:52
2
answers

Difficulty with Select

I want to make a query of 1 table that has the records: Predio | Local | Produto | FIFO P01 | WH01 | Maçã | 21/02/17 P01 | WH01 | Maçã | 22/02/17 P01 | WH01 | Maçã | 23/02/17 P01 | WH01 | Maçã | 28/02/17 P...
asked by 04.12.2017 / 20:42
0
answers

Creating Event in MYSQL to delete records per day

I'm trying to create an automatic event in MySQL so that every 24 hours it runs the following command to delete promotions without the administrator interaction, where if the end date is less than the current date it will delete, I'm not sure if...
asked by 24.11.2017 / 02:37
1
answer

Delete a Limit of Hibernate Records (Limit)

I'm migrating my WEB application to the Hibernate framework, however I have several SQL requests with very specific parameters. In one of these requests, I always need to include a new record in the database, delete the first 20...
asked by 10.11.2017 / 14:55
0
answers

Data passing performance as a parameter in stored procedure

I'm developing a system, in Java and Sybase, where I need to pass the current date as a parameter in a procedure . With this, I was curious about how to pass the date ... Is there a significant difference in performance by passing the current d...
asked by 17.11.2017 / 20:01
1
answer

HELP - I can not identify error - PHP and SQL

Hello,  I am trying to bring in a table the grouping of all steps and item evaluation per year along with the average of the scores and weights. I can only bring the last step and item p table, that is, it is not doing the grouping, although...
asked by 08.11.2017 / 15:03