Results 1 to 3 of 3

Thread: Manipulating the records in ASP

  1. #1

    Thread Starter
    Junior Member
    Join Date
    May 2003
    Posts
    17

    Question Manipulating the records in ASP

    I am having this problem with the
    objRs.Fields. When I retrieve the record from SQL if the value is 9 I
    have to change it to 0. This is not working - can any of you help me
    point where exactly I am missing the logic.


    If objRs.Fields ("CirusStatusIndicator") = "'9'" Then
    SET objRs.Fields ("CirusStatusIndicator") = "'0'"
    Response.Write "<TD align=left>" & objRs.Fields
    ("CirusStatusIndicator") & "</TD>"
    Else
    Response.Write "<TD align=left>" & objRs.Fields
    ("CirusStatusIndicator") & "</TD>"
    End if

    Thanks
    Sri

  2. #2
    Frenzied Member Memnoch1207's Avatar
    Join Date
    Feb 2002
    Location
    DUH, Guess...Hint: It's really hot!
    Posts
    1,861
    if it is an integer you don't need the quotes.

    Code:
    If(objRs.Fields ("CirusStatusIndicator") = 9) Then 
        newCirusStatusIndicator = 0
       Response.Write "<TD align=left>" & newCirusStatusIndicator & "</TD>" 
    Else 
       Response.Write "<TD align=left>" & objRs.Fields ("CirusStatusIndicator") & "</TD>" 
    End if
    Being educated does not make you intelligent.

    Need a weekend getaway??? Come Visit

  3. #3

    Thread Starter
    Junior Member
    Join Date
    May 2003
    Posts
    17
    Thanks a lot I shall try and let you know how it worked in few hours..
    Thanks much!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width