home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.databases.ms-sqlserver      Notorious Rube Goldberg contraption      19,505 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 18,522 of 19,505   
   Tony to All   
   more about timestamp   
   24 Nov 11 11:19:19   
   
   From: johansson.andersson@telia.com   
      
   One strange thing when I add a timestamp column to a table and then changed   
   some rows and then made a select in the Server explorer that exist in VS I   
   didn't see any values in this timestamp column. It showed only this   
    in the timestamp column.   
   But if I instead used the same select from within SQL Server Management   
   studio I can see values like 0x0000000000001F43   
   Can somebody why a select on the timestamp give different result beween   
   Server explorer and SQL Server Management studio   
      
   My next question is when I run the aspx page below that use timestamp like   
   this as you can see below where ProductId=@ProductID AND   
   RowTimestamp=@RowTimestamp"   
      
   I get run time error saying the following Must declare the scalar variable   
   "@RowTimestamp".   
   So how do I define the timestamp parameter RowTimestamp to get rid of this   
   error ?   
   After the definition of the following SqlDataSource I made an attempt to fix   
   read more   
      
      
                 
                    
                 
          
      
   The first parameter ProductID is fetched from the DropDownList control   
   ddlProducts so that was easy.   
   The second RowTimestamp is just to check for concurrency. This mean that is   
   somebody has changed the record with this ProductID after I fetched this   
   record from the database then  this with not be true   
   RowTimestamp=@RowTimestamp.   
      
   So I have even tried to use these properties ConflictDetection and   
   OldValuesParameterFormatString but I get the same error   
   Must declare the scalar variable "@Original_RowTimestamp".   
   So if I must define this RowTimestamp in the selectParameter tag how should   
   this be done ?   
      
      
                 
                    
                 
          
      
   //Tony   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca