Questions tagged as 'sql'

3
answers

Condition in Where SQL Server

I have a SELECT with several LEFT JOIN , however I need to consider all these LEFT JOIN in some conditions, already in another condition I need disregard a made JOIN .    As an example: SELECT * FROM TabelaTot...
asked by 22.03.2016 / 21:11
2
answers

How to perform update on records marked with checkbox in a while

I'm not able to UPDATE the fields that are only selected by CHECKBOX, which I was able to develop below: BD.SQL CREATE DATABASE IF NOT EXISTS 'seq_acessos' DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; USE 'seq_acessos'; CREATE TAB...
asked by 07.04.2016 / 23:50
1
answer

Empty string return - Oracle

I have a table with a string and several fields separated by | (pipe) I need to bring each field into a column. I even got a way, the problem is that when a record does not have the field filled in the string brings ||. Detail, I can not...
asked by 07.04.2016 / 21:05
1
answer

Problems working with dates in the database using a maskedtextbox in the format dd / MM / yyyy

I'm using a MaskedTextBox in the en-BR culture to force the user to fill the date in the correct format (dd / mm / yyyy). Retrieve the string from the MaskedTextBox to insert into the database and record information containing the date of this i...
asked by 07.03.2016 / 21:20
1
answer

Champ Error inconnu dans on clause - SQL

I have the following situation with 3 tables: ocorrencias : It has 6 columns: tipo_falha_1 to tipo_falha_6 . It is a 2-digit code, from 1 to 20. tipo_falha : Has a description of the faults. The cod field is...
asked by 10.03.2016 / 12:39
1
answer

Modeling for student attendance

I have questions regarding the structure of the database for a frequency system. I thought of two structures and when doing a search I saw that the two exist and are used in different systems. 1 - The first one I have a frequencia table w...
asked by 18.04.2016 / 23:40
3
answers

Query in two fields of a table

Good afternoon, folks. I use two providence and occurrence tables - being that I have 1 occurrence for N providences. I need to perform a registry query that shows how many actions has occurred. Follow the image from my base, it's easier to u...
asked by 15.03.2016 / 19:47
1
answer

Query does not return results in PHP [closed]

There is a query in my PHP where I search the mailing list and return to PHP, however, it is not returning any results. Code PHP looks like this: <?php session_start("admin"); if($_SESSION["admin"] == "on"){ inclu...
asked by 16.03.2016 / 15:59
1
answer

Error fetching list in MYSQL

I have a problem in my system to send newsletter emails, when loading the index, where the list of registered emails are loaded, the following error appears: Warning: mysql_fetch_array() expects parameter 1 to be resource, boolean given in /...
asked by 16.03.2016 / 15:23
1
answer

How is a specialization implemented in a bank? [closed]

In my ER model and in the diagram I created a specialization for an entity called clients, where it relates to the physical and legal entities coming from that specialization. Do I simply create the relationships between these tables as if it we...
asked by 05.03.2016 / 14:08