Click here to Skip to main content
15,793,546 members
Home / Discussions / Database
   

Database

 
AnswerRe: Read Only Database Pin
Mycroft Holmes23-Jun-14 2:13
professionalMycroft Holmes23-Jun-14 2:13 
GeneralRe: Read Only Database Pin
Jörgen Andersson23-Jun-14 2:18
professionalJörgen Andersson23-Jun-14 2:18 
GeneralRe: Read Only Database Pin
Mycroft Holmes25-Jun-14 1:26
professionalMycroft Holmes25-Jun-14 1:26 
GeneralRe: Read Only Database Pin
Jörgen Andersson25-Jun-14 10:53
professionalJörgen Andersson25-Jun-14 10:53 
GeneralRe: Read Only Database Pin
Bastien Vandamme23-Jun-14 17:44
Bastien Vandamme23-Jun-14 17:44 
GeneralRe: Read Only Database Pin
Mycroft Holmes25-Jun-14 1:35
professionalMycroft Holmes25-Jun-14 1:35 
GeneralRe: Read Only Database Pin
Bastien Vandamme26-Jun-14 1:02
Bastien Vandamme26-Jun-14 1:02 
QuestionGet the max elements in a join? Pin
Bastien Vandamme22-Jun-14 18:14
Bastien Vandamme22-Jun-14 18:14 
I have two tables

1. A table USER with a USER_ID, NAME, ...
2. A table STATUS with a STATUS_ID, PEOPLE_FK (foreign key to USER_ID), LABEL, DATE_START...

A USER can only have one active status. I use the DATE_START field to keep the history of all status of the user. I never delete a status. If I create a join between USER and STATUS I can easily get all my users with all they status. BUT I would like to create a query to retrieve all my users with they last status only. I'm still learning SQL. What should I use? Is a select in a select recommended? I would like to avoid the solution of with subquesries.

EDIT -- I searched for a duplicate of this question without success. If this question has been already answered just show me the link. thank you.

modified 22-Jun-14 23:27pm.

AnswerRe: Get the max elements in a join? Pin
Kornfeld Eliyahu Peter22-Jun-14 20:31
professionalKornfeld Eliyahu Peter22-Jun-14 20:31 
AnswerRe: Get the max elements in a join? Pin
Jörgen Andersson22-Jun-14 21:08
professionalJörgen Andersson22-Jun-14 21:08 
QuestionIs it recommended to use trigger to manage business rules with SQL Server? Pin
Bastien Vandamme22-Jun-14 18:00
Bastien Vandamme22-Jun-14 18:00 
AnswerRe: Is it recommended to use trigger to manage business rules with SQL Server? Pin
Kornfeld Eliyahu Peter22-Jun-14 20:15
professionalKornfeld Eliyahu Peter22-Jun-14 20:15 
GeneralRe: Is it recommended to use trigger to manage business rules with SQL Server? Pin
GuyThiebaut22-Jun-14 22:59
professionalGuyThiebaut22-Jun-14 22:59 
GeneralRe: Is it recommended to use trigger to manage business rules with SQL Server? Pin
Kornfeld Eliyahu Peter22-Jun-14 23:02
professionalKornfeld Eliyahu Peter22-Jun-14 23:02 
GeneralRe: Is it recommended to use trigger to manage business rules with SQL Server? Pin
Jörgen Andersson22-Jun-14 23:20
professionalJörgen Andersson22-Jun-14 23:20 
GeneralRe: Is it recommended to use trigger to manage business rules with SQL Server? Pin
Kornfeld Eliyahu Peter22-Jun-14 23:21
professionalKornfeld Eliyahu Peter22-Jun-14 23:21 
GeneralRe: Is it recommended to use trigger to manage business rules with SQL Server? Pin
Jörgen Andersson22-Jun-14 23:24
professionalJörgen Andersson22-Jun-14 23:24 
GeneralRe: Is it recommended to use trigger to manage business rules with SQL Server? Pin
Kornfeld Eliyahu Peter22-Jun-14 23:28
professionalKornfeld Eliyahu Peter22-Jun-14 23:28 
AnswerRe: Is it recommended to use trigger to manage business rules with SQL Server? Pin
Jörgen Andersson22-Jun-14 20:52
professionalJörgen Andersson22-Jun-14 20:52 
AnswerRe: Is it recommended to use trigger to manage business rules with SQL Server? Pin
Mycroft Holmes23-Jun-14 2:04
professionalMycroft Holmes23-Jun-14 2:04 
QuestionCompare two tabel and add/update query Pin
member002618-Jun-14 21:44
member002618-Jun-14 21:44 
AnswerRe: Compare two tabel and add/update query Pin
Mycroft Holmes18-Jun-14 23:33
professionalMycroft Holmes18-Jun-14 23:33 
QuestionValidate Date Time value on Sqlite before insert / update Pin
rahmat198517-Jun-14 23:29
rahmat198517-Jun-14 23:29 
AnswerRe: Validate Date Time value on Sqlite before insert / update Pin
Mycroft Holmes17-Jun-14 23:57
professionalMycroft Holmes17-Jun-14 23:57 
GeneralRe: Validate Date Time value on Sqlite before insert / update Pin
Eddy Vluggen18-Jun-14 1:28
professionalEddy Vluggen18-Jun-14 1:28 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.