User Profile

Collapse

Profile Sidebar

Collapse
lohima
lohima
Last Activity: Jul 27 '12, 04:05 AM
Joined: Jul 3 '12
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • How to get date difference of integer and timestamp in days?

    hi
    i want to get date difference between two columns. month and DOJ in days. month is integer datatype and doj is in time stamp. the colums data was like this. i mentioned '|' in btw of 2 columns for your clarification.

    doj | month_sid

    5/30/2008 12:00:00 AM | 201103
    5/19/2008 12:00:00 AM | 201111
    5/19/2008 12:00:00 AM | 201112
    5/19/2008 12:00:00 AM | 201201
    5/19/2008...
    See more | Go to post

  • hi Rabbit,
    thank you for ur reply. i tried this already it is showing datatype error.
    when i used datatype conversion i am getting the data.

    'select 'a'+cast(a as varchar(10))+' '+cast(rowid as varchar(10)','b '+cast(a as varchar(10))+' '+cast(rowid as varchar(10)', etc...'

    what i need is i dont want to add column name "['a' +]" here to get output as a1. Is there any other possibility to get column...
    See more | Go to post

    Leave a comment:


  • How to combine both row data with column name and get as output

    Hi,
    i had a table like below which contains some rows and columns.

    rowid a b c
    1
    2
    3

    now i want the output like

    rowid a b c
    1 a1 b1 c1
    2 a2 b2 c2
    3 a3 b3 c3

    it's a combination of both row data and column name.
    See more | Go to post
No activity results to display
Show More
Working...