Click here to Skip to main content
15,892,059 members
Home / Discussions / Database
   

Database

 
General[Message Deleted] Pin
Niladri_Biswas16-Dec-09 3:23
Niladri_Biswas16-Dec-09 3:23 
GeneralRe: How to group data which not the same ? Pin
Golden Jing16-Dec-09 14:51
Golden Jing16-Dec-09 14:51 
AnswerRe: How to group data which not the same ? Pin
Luc Pattyn16-Dec-09 15:03
sitebuilderLuc Pattyn16-Dec-09 15:03 
QuestionADODB Recordset - using ActiveX Data Object in Access 2007 Pin
john john mackey15-Dec-09 12:38
john john mackey15-Dec-09 12:38 
QuestionMS-SQL - Bulk Insert query Pin
22491715-Dec-09 11:50
22491715-Dec-09 11:50 
AnswerRe: MS-SQL - Bulk Insert query Pin
Ashfield15-Dec-09 21:01
Ashfield15-Dec-09 21:01 
GeneralRe: MS-SQL - Bulk Insert query Pin
22491716-Dec-09 6:14
22491716-Dec-09 6:14 
QuestionQuestion about using conditional SQL statement Pin
James Shao15-Dec-09 4:22
James Shao15-Dec-09 4:22 
I have a time series data in which a numerical indicator fluctuates over time. If I want to find out for which given day, this indicator has crossed above 30 in the past 3 days. Is it possible to write a SQL query that retrieve this information?

The logic to check for the crossing movement is:

IF indicator(day x) > 30 AND indicator(3 days ago from day x) <30 THEN
Return "YES WE HAVE AN UPWARD CROSSING MOVEMENT THROUGH 30 FOR PAST 3 DAYS!"
END IF

Can this be accomplished using a SQL CASE statement with a HAVING clause or something else?

I'd greatly appreciate any help! If possible please provide a sample code Poke tongue | ;-P
AnswerRe: Question about using conditional SQL statement [modified] Pin
Ashfield15-Dec-09 4:34
Ashfield15-Dec-09 4:34 
GeneralRe: Question about using conditional SQL statement [modified] Pin
James Shao15-Dec-09 15:02
James Shao15-Dec-09 15:02 
GeneralRe: Question about using conditional SQL statement Pin
Ashfield15-Dec-09 20:57
Ashfield15-Dec-09 20:57 
AnswerCROSS POST Pin
dan!sh 15-Dec-09 5:08
professional dan!sh 15-Dec-09 5:08 
GeneralRe: CROSS POST Pin
James Shao15-Dec-09 12:46
James Shao15-Dec-09 12:46 
QuestionSql Doubt Pin
rajanandal15-Dec-09 2:26
rajanandal15-Dec-09 2:26 
AnswerRe: Sql Doubt Pin
Richard MacCutchan15-Dec-09 2:39
mveRichard MacCutchan15-Dec-09 2:39 
GeneralRe: Sql Doubt Pin
rajanandal15-Dec-09 2:53
rajanandal15-Dec-09 2:53 
GeneralRe: Sql Doubt Pin
dxlee15-Dec-09 4:27
dxlee15-Dec-09 4:27 
AnswerRe: Sql Doubt Pin
Niladri_Biswas15-Dec-09 15:18
Niladri_Biswas15-Dec-09 15:18 
GeneralRe: Sql Doubt Pin
rajanandal15-Dec-09 23:28
rajanandal15-Dec-09 23:28 
QuestionSQL Between Stored Proc Pin
Illegal Operation14-Dec-09 18:08
Illegal Operation14-Dec-09 18:08 
AnswerRe: SQL Between Stored Proc Pin
Niladri_Biswas14-Dec-09 18:15
Niladri_Biswas14-Dec-09 18:15 
AnswerRe: SQL Between Stored Proc Pin
Andy_L_J14-Dec-09 18:36
Andy_L_J14-Dec-09 18:36 
Questionssis script component Pin
Ebube14-Dec-09 4:24
Ebube14-Dec-09 4:24 
QuestionRe: ssis script component Pin
Unforgiv3n17-Dec-09 20:50
Unforgiv3n17-Dec-09 20:50 
QuestionCan VS support Ruby on Rails -like database migrations? Pin
GarethHowell14-Dec-09 2:40
GarethHowell14-Dec-09 2:40 

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.