|
|
|
SSCommitted
      
Group: General Forum Members
Last Login: Wednesday, January 16, 2013 4:11 AM
Points: 1,569,
Visits: 56
|
|
|
|
|
|
SSC Veteran
      
Group: General Forum Members
Last Login: Wednesday, February 27, 2013 9:28 AM
Points: 262,
Visits: 91
|
|
| Versioning is too specific. You'll have to update this code everytime you apply a CU or SP. Why not just look at the first character? Show us how without the cursor, there must be a set-wise way to do this.
|
|
|
|
|
SSC Eights!
      
Group: General Forum Members
Last Login: Thursday, December 06, 2012 8:30 AM
Points: 879,
Visits: 810
|
|
I receive this error: Msg 213, Level 16, State 7, Line 2 Insert Error: Column name or number of supplied values does not match table definition.
This does not look well...
Greetz, Hans Brouwer
|
|
|
|
|
SSCommitted
      
Group: General Forum Members
Last Login: Wednesday, January 16, 2013 4:11 AM
Points: 1,569,
Visits: 56
|
|
Hi Hans,
I am not getting any error, I have executed it & there is no
|
|
|
|
|
SSCommitted
      
Group: General Forum Members
Last Login: Wednesday, January 16, 2013 4:11 AM
Points: 1,569,
Visits: 56
|
|
Hi Hans,
I am not getting "Insert Error: Column name or number of supplied values does not match table definition." Its working fine.
Please try again & let me know if there it still give problem.
Thanks
Sudhir
|
|
|
|
|
SSCommitted
      
Group: General Forum Members
Last Login: Wednesday, January 16, 2013 4:11 AM
Points: 1,569,
Visits: 56
|
|
Hi Sigal,
Actually the only purpose to use cursor is to avoid DBO, SYS, INFORMATION_SCHEMA and Guest users, else we can directly execute sp_helpuser and it will return all user's role data.
To avoid cursor, while creating #tmpuser table, we can add another field with identity column and then run a while loop.
We have to run a loop to get roles of each user excluding system users.
your comments are appreciated.
Thanks
Sudhir
|
|
|
|