238 reputation
110
bio website
location
age
visits member for 1 year, 8 months
seen 12 hours ago

Jul
18
asked When there is a Type 1 and type 2 SCD in a dimension table, how are updates to the type 1 column handled after the type 2 column is updated?
Nov
12
awarded  Yearling
Mar
16
awarded  Custodian
Mar
16
reviewed No Action Needed MySQL user created via command line can't access PHPMyAdmin
Mar
16
reviewed No Action Needed NoSQL approach: design table “scheme”
Mar
10
comment db INDEX on ORDER BY FIELD in very simple query does not help - still slow response?
I dont know anything about db2, but assuming it is similar to SQL Server, did you try a clustered index instead of a non clustered index (since you are using a select * query)?
Jan
15
comment Fetch Records alternatively from database
hmm.. apparently theres no straightforward way to do it in MySQL since it doesn't have the equivalents of a CTE or RowNumber, so any method I suggest would be hacky. Probably try out Neo's answer if it works for you (and take ahofmann's advise for the future)
Jan
15
comment Fetch Records alternatively from database
Don't know if its possible in MySQL, but how about using a ROWNUMBER() over Date_Time , join the CTE with itself, with the join condition as rownumber+1 and a where condition to filter out records where the left rownumber is even or the right rownumber is odd
Jan
15
comment Stateful views in SQL Server
@despicable updated answer with more info
Jan
15
revised Stateful views in SQL Server
added 563 characters in body
Jan
14
comment How does paging work with ROW_NUMBER in SQL Server?
Ah, you're right, theres a performance difference. I had read this: blogs.technet.com/b/dataplatforminsider/archive/2011/11/01/… where he mentions no difference, but just saw channel9.msdn.com/posts/SQL11UPD03-REC-02 where he shows theres a lot of difference.. (though in the audio underemphasis the performance difference)
Jan
14
comment How does paging work with ROW_NUMBER in SQL Server?
Should be noted though that OFFSET/FETCH NEXT do not offer any performance benefits over the CTE method
Jan
14
awarded  Teacher
Jan
14
answered Connecting to a SQL Server database from a Flash program
Jan
14
answered Stateful views in SQL Server
Jan
14
awarded  Excavator
Jan
14
revised MySQL, foreign key, can't create table error 150
Mark correct answer
Jan
14
suggested suggested edit on MySQL, foreign key, can't create table error 150
Dec
18
awarded  Quorum
Dec
12
comment Forcing an index spool
Updated the statistics, though I have the actual data in the table. Still getting the row count spool, guess its a build difference since I'm on 11.0.2218