  | 
			
				SoftTree Technologies 
				Technical Support Forums
			 | 
		 
		  | 
	 
	 
	
	
	
		
	
	
	
		| Author | 
		Message | 
	 
	
		
			iunknown 
			 
			
  
			
			
				Joined: 15 Feb 2007 Posts: 1 Country: eg | 
			 
			  
		 | 
		
			
				  Error Message | 
				     | 
			 
			
				Hi,
 
I have this error while typing a simple statement
 
	  | 
	
 
	  | 
	
 
---------------------------
 
SQL Assistant - Error
 
---------------------------
 
Execute: ODBC Error: SQLExecute
 
[Microsoft][ODBC SQL Server Driver][SQL Server]Cannot resolve collation conflict for column 1 in SELECT statement.
 
 
if @@version like 'Microsoft SQL Server 2005%'
 
 
	select
 
 
		name,
 
 
		case when type in ('S','U','G') then 'SC' else 'SR' end,
 
 
		principal_id
 
 
	from
 
 
		[TOTALVIEW].sys.database_principals
 
 
	where
 
 
		type in ('S','U','G','A','R')
 
 
	union all
 
 
	select
 
 
		name,
 
 
		case when type = 'R' then 'SR' else 'SL' end,
 
 
		principal_id
 
 
	from
 
 
		[TOTALVIEW].sys.server_principals
 
 
	where
 
 
		type in ('S','U','G','R')
 
 
else
 
 
	select
 
 
		name, 
 
 
		case when issqlrole + isapprole > 0 then 'SR' else 'SC' end, 
 
 
		cast(uid as int)
 
 
	from
 
 
		[TOTALVIEW].dbo.sysusers
 
 
	where
 
 
		issqluser = 1 or isntuser  = 1
 
 
	or	issqlrole = 1 or isapprole = 1
 
 
	
 
 
	union all
 
 
	select name, 'SL', 0 
 
 
	from master.dbo.syslogins
 
 
---------------------------
 
OK   
 
---------------------------
 
 | 
	 
 
 
 
please advise
  | 
			 
		  | 
	 
	
		| Thu Feb 15, 2007 12:05 pm | 
		          | 
	 
	
		  | 
	 
	
		
			SysOp 
			Site Admin 
			
  
			
			
				Joined: 26 Nov 2006 Posts: 7992
  | 
			 
			  
		 | 
		 | 
	 
	
		| Thu Feb 15, 2007 2:37 pm | 
		          | 
	 
	
		  | 
	 
	
		 | 
	 
 
  
	 
	    
	   | 
	
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
  | 
   
 
		 | 
	 
	  |