Click here to Skip to main content
15,844,903 members
Home / Discussions / Database
   

Database

 
Generalselect year/month syntax (for contracts up for renewal in X month) Pin
tellytub18-Dec-07 17:09
tellytub18-Dec-07 17:09 
GeneralRe: select year/month syntax (for contracts up for renewal in X month) Pin
Giri K18-Dec-07 18:11
Giri K18-Dec-07 18:11 
GeneralRe: select year/month syntax (for contracts up for renewal in X month) Pin
tellytub18-Dec-07 21:15
tellytub18-Dec-07 21:15 
GeneralRe: select year/month syntax (for contracts up for renewal in X month) Pin
Giri K19-Dec-07 12:55
Giri K19-Dec-07 12:55 
Questionjoins of two tables +search Pin
regin18-Dec-07 2:42
regin18-Dec-07 2:42 
GeneralRe: joins of two tables +search Pin
pmarfleet18-Dec-07 2:59
pmarfleet18-Dec-07 2:59 
GeneralRe: joins of two tables +search Pin
andyharman18-Dec-07 4:47
professionalandyharman18-Dec-07 4:47 
QuestionHow to get generated Primary Key when adding a record Pin
gunner_uk200018-Dec-07 2:35
gunner_uk200018-Dec-07 2:35 
AnswerRe: How to get generated Primary Key when adding a record Pin
Pete O'Hanlon18-Dec-07 2:38
subeditorPete O'Hanlon18-Dec-07 2:38 
AnswerRe: How to get generated Primary Key when adding a record Pin
Giorgi Dalakishvili18-Dec-07 2:42
mentorGiorgi Dalakishvili18-Dec-07 2:42 
Questionselect the max value from the row and its other values Pin
Deques18-Dec-07 2:19
Deques18-Dec-07 2:19 
GeneralRe: select the max value from the row and its other values Pin
Tobias Schoenig18-Dec-07 2:41
Tobias Schoenig18-Dec-07 2:41 
GeneralRe: select the max value from the row and its other values Pin
Deques18-Dec-07 2:51
Deques18-Dec-07 2:51 
GeneralRe: select the max value from the row and its other values Pin
Tobias Schoenig18-Dec-07 2:59
Tobias Schoenig18-Dec-07 2:59 
GeneralRe: select the max value from the row and its other values Pin
Deques18-Dec-07 3:05
Deques18-Dec-07 3:05 
GeneralRe: select the max value from the row and its other values Pin
Tobias Schoenig18-Dec-07 3:10
Tobias Schoenig18-Dec-07 3:10 
GeneralRe: select the max value from the row and its other values Pin
Deques18-Dec-07 3:17
Deques18-Dec-07 3:17 
GeneralRe: select the max value from the row and its other values Pin
Tobias Schoenig18-Dec-07 3:22
Tobias Schoenig18-Dec-07 3:22 
GeneralRe: select the max value from the row and its other values Pin
Deques18-Dec-07 3:31
Deques18-Dec-07 3:31 
GeneralRe: select the max value from the row and its other values Pin
Tobias Schoenig18-Dec-07 3:32
Tobias Schoenig18-Dec-07 3:32 
GeneralRe: select the max value from the row and its other values Pin
Deques18-Dec-07 3:43
Deques18-Dec-07 3:43 
GeneralRe: select the max value from the row and its other values Pin
Tobias Schoenig18-Dec-07 3:49
Tobias Schoenig18-Dec-07 3:49 
GeneralRe: select the max value from the row and its other values Pin
Deques18-Dec-07 3:53
Deques18-Dec-07 3:53 
GeneralRe: select the max value from the row and its other values Pin
Rupert Todd19-Dec-07 10:36
Rupert Todd19-Dec-07 10:36 
I believe you need to join the table to a subset of itself.

You create a subquery that gives you the values of project and the highest col1 and attribute that to a temptable. You then join you orignal table to your temp table on the values of col1. This should do the trick!

SELECT PT.* FROM out_pumptable PT join
(select project, max(col1) as MaxVal from out_pumptable group by project) TEMPTABLE1 on TEMPTABLE1.MaxVal = PT.col1
Generalcalling a storedprocedure from a function in mysql Pin
sepel18-Dec-07 1:35
sepel18-Dec-07 1:35 

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.