Forum Replies Created

Viewing 11 posts - 1 through 11 (of 11 total)

  • RE: Query help...

    This is returning nothing 🙁

    --drop table tempdb..#cnums

    --drop table tempdb..#dnums

    IF OBJECT_ID('tempdb..#cnums') IS NULL

    BEGIN

    CREATE TABLE #cnums(Cnum bigint,D1 varchar(6), D2 varchar(6), D3 varchar(6), D4 varchar(6), D5 varchar(6), D6 varchar(6), D7 varchar(6))

    ...

  • RE: Query help...

    It's a varchar right ?

  • RE: Query help...

    Here what it looks like...and getting Error converting data type varchar to float.

    --drop table tempdb..#cnums

    --drop table tempdb..#dnums

    IF OBJECT_ID('tempdb..#cnums') IS NULL

    BEGIN

    CREATE TABLE #cnums(Cnum bigint,D1 varchar(6), D2 varchar(6), D3 varchar(6), D4...

  • RE: Query help...

    select c.Cnum,c.d1 ,c.d2,c.d3,c.d4 from

    #dnums d,(SELECT distinct Cnum,D1,D2,D3,D4

    FROM #cnums )c

    where c.D1 = d.D OR c.D2 = d.D OR c.D4 =...

  • RE: Query help...

    Thank you, I liked the mister.magoo's idea, as it is faster. But, I didn't realize that, some of the vlaues in the #dnums are float like 11.20, 34.55 etc...

    So,...

  • RE: Code help, may be can be acheived through CTE

    Hi Jeff,

    This works perfectly like what I wanted...But, I didn’t understand this part …Why are we doing this?

    ROW_NUMBER() OVER (ORDER BY ID,Date) - ROW_NUMBER() OVER (PARTITION BY...

  • RE: Removing all the partitions

    I think, now we are back to square 1..

    Remove the partitioning:

    My questiopn was how to remove the partition? Do I have to do it manually? Since I have 22 partitions...

  • RE: Removing all the partitions

    HI,

    I created a drop and create table scripts with the table partitioning. But, this didn't remove the partition at all..

    I see all the partitions (around 22) and I can’t drop...

  • RE: Removing all the partitions

    I was think of dropping and recreating the tables too..

    Thanks for all of your suggestions and help!

    -VG

  • RE: Query

    The gap is filled, but not the exact way I wanted....So, I posted my query..

    It is very starange that, sometimes, people ask for a query to post, when I post...

  • RE: Query

    THis is how I got the result like before....I have defined this as a function to join these results to a table with cross apply. Basically we have to fill...

Viewing 11 posts - 1 through 11 (of 11 total)