#DateForumTypeThreadPost
509 Sep 2015 @ 08:58 PDTDatabaseReplyQuery neededRow_number wont run without order by clause. SELECT address, MAX(CASE WHEN rownum =1 THEN age END) AS cus_id1_age, MAX(CASE WHEN rownum =2 THEN age END) AS cus_id2_age, MAX(CASE WHEN rown...
403 Sep 2015 @ 10:05 PDTDatabaseReplyPrevious month entire date's in the select query?You can use the following command to get the previous month entire date range# Processing Processing_Date BETWEEN (CAST(((ADD_MONTHS(DATE, -1)/100)*100+1) AS DATE)) AND ( DATE-DATE MOD 100)
303 Sep 2015 @ 09:58 PDTDatabaseTopicHow to find the maximum or minimum out of char datatype?I need to find the maximum and minimum from the character datatype. E.g The Table Customer contains Customer id and State code such as CA, IL, MN  and customer id contains 12310, 12300, 124...
226 Mar 2014 @ 06:36 PDTDatabaseReplySpace in the database ---- Database level Space Check SELECT  DatabaseName ,SUM(CurrentPerm)/1024/1024 AS USEDSPACE_IN_MB ---  includes wasted perm due to skew ,MAX(CurrentPerm) * (HASHAMP()...
126 Mar 2014 @ 06:28 PDTDatabaseTopicNo More Spool Space issue encountered.Please tell why this issue is happening that I am getting error as NO MORE SPOOL SPACE when I try to run the SQL from table (UDW2BASE.PROV_NPI_TXNMY) and when I create a volatile table of the same ...