#DateForumTypeThreadPost
515 Sep 2009 @ 07:25 PDTDatabaseReplyDecimal not what it seems?In SQL Assisstant, check option "Display full accuracy for BigINt and Decimal(16) or above (See Help)".
425 Aug 2009 @ 01:12 PDTAnalyticsReplyDate Gap AnalysisOK, I misunderstood the task - my code simply identifies records that have a wrong date i.e. date intervals overlap or there's a gap between them.How about that:WITH RECURSIVE tmp ( upc, effect_sta...
321 Aug 2009 @ 11:18 PDTAnalyticsReplyDate Gap AnalysisTry this:SELECTt.upc,t.effect_start,t.effect_end,MIN(t.effect_end) OVER (PARTITION BY t.upcORDER BY t.effect_startROWS BETWEEN 1 PRECEDING AND 1 PRECEDING) AS effect_end_prevFROMMyTable AS tQUALIFY...
201 Apr 2009 @ 04:31 PDTDatabaseReplyIdentity Column Not Coming in a sequence. Need Suggestion.Hi,Well, to generate a sequence of n numbers with ROW_NUMBER() or other window function you need to have a table that has at least n rows which is an unnecessary assumption (how can you guarantee t...
116 Sep 2008 @ 02:31 PDTDatabaseReplyGeeting count of data from 2 diff table swhich dont have common columns in itMake it UNION ALL, not just UNION - if both Table1 and Table2 have the same number of records UNION will eliminate one of the COUNT(*)s (treating one of them as a duplicate) and you will get the wr...