Jump to content

bbenedict

Members
  • Posts

    9
  • Joined

  • Last visited

About bbenedict

  • Birthday 12/31/1986

Profile Information

  • Location
    Philadelphia

bbenedict's Achievements

Newbie

Newbie (1/7)

0

Reputation

  1. I am trying to execute this statement but get the error in the title. Google has not been any help, any ideas? select inq_type, COUNT(d.id)from DBl_olap.dbo.Dim_lead d, BDl_OLAP.dbo.FACT_LEADwhere createddate between 2012-1-1 and 2012-12-31group by inq_typeorder by COUNT(d.id) desc thanks!
  2. Update: I inserted ,Cast(CAST(BANNER_ID AS VARCHAR(50))as decimal) as BANNER_ID to try and fix the notication and return it back to a simple number and now I get this 'Error converting data type varchar to numeric." so i think i am getting closer.
  3. Thanks! So i got this to work but there is still one wierd problem, when the cast statement is executed the values in one of the colums goes through this transformation: original (float, null) - 12594570New (after: CAST(thing_ID AS VARCHAR(36)) AS Thing_ID) 1.25946e+007 In the warehouse I cannot link these notations with the fact table.
  4. Need to convert some columns to different data type, but this statement will not work. Any idea what I am missing? (mgmt Studio has the first 'CAST' and 'AS' underlined. SELECT CAST [ETL_ID as int] as ETL_ID, NAMEX, DU_DEGREE_STATUS, DU_ESTS_DESC, Cast [bANNER_ID as (varchar(36),Null)]as BANNER_ID, DU_COLLEGE_DESC, cAST [DU_DEL_TERM_CODE_ADMIT as (VARCHAR(255),NULL)] AS DU_DEL_TERM_CODE_ADMIT, AGE, ETHNICITY_DESCRIPTION, GENDER, cAST [T1 as (VARCHAR(255),NULL)] AS T1, T1Status, cAST [T2 as (VARCHAR(255),NULL)] as T2, T2Status, cAST [T3 as (VARCHAR(255),NULL)] as T3, T3Status, cAST [T4 as (VARCHAR(255),NULL)] as T4, T4StatusFROM dbo.['Tracking 3$']
  5. yes its backed up. I wll give this a try.
  6. I would but there are over 60k rows I do not have the time for that. I just want to change any zipcode that has a count of 1 lead to 12345 for example. Then I will have a managable amount to run update queries. It does not have to have a strong relationship with state and country.
  7. Hi,I have chosen a zipcode that i will be using to replace the junk entries. there is just to much data to be percise so i am taking all zipcodes with the lead count of 1 (99% of which is junk) and changing them to a predetermined zip.
  8. Hey,I am making a demo database and I have some really dirty data that I need to clean up. In the GEO dim I want to change all the Zipcodes with the count of one lead to reflect a zipcode that I can use in a map dashboard. Currently most counts of one contain --=-== and other completely usless informaiton. I think best way is to create a temp view but I can't figure out the code I should use to change the count (1) to whatever zipcode I need. Any ideas would be much appreciated.Thanks!B
×
×
  • Create New...