Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
 
					
				
		
 kushalthakral
		
			kushalthakral
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Hi All
Just wanted to know what is the difference between $(Variable) and $(=Variable) while using them in Set Analysis
Thanks
Kushal Thakral
 
					
				
		
 marcus_sommer
		
			marcus_sommer
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		In this simple case it looked identically - but it isn't. The difference here is where the variable-content will be evaluated. By $(=Variable) is it inside from the $-sign expansion and $(Variable) will be evaluated within the field respectively expression in which it is embedded.
The best explanation will you find within the link above and here: The Magic of Variables.
- Marcus
 
					
				
		
 marcus_sommer
		
			marcus_sommer
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		 
					
				
		
 kushalthakral
		
			kushalthakral
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Hi Marcus
I have checked if you use =$(Variable) in a text object or =$(=Variable), both are giving same result
i have defined Variable value 1+2 in variable overview.
Regards
Kushal Thakral
 vikasmahajan
		
			vikasmahajan
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		PFA document
Vikas
 
					
				
		
 swuehl
		
			swuehl
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Have also a look at
and the comments below this blog post.
I think the example using simple arithmetic is also not the best example, compare an aggregation like Max(Date) put into a variable and expanded in e.g. a chart dimensional context.
 
					
				
		
 marcus_sommer
		
			marcus_sommer
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		In this simple case it looked identically - but it isn't. The difference here is where the variable-content will be evaluated. By $(=Variable) is it inside from the $-sign expansion and $(Variable) will be evaluated within the field respectively expression in which it is embedded.
The best explanation will you find within the link above and here: The Magic of Variables.
- Marcus
 
					
				
		
 jonathandienst
		
			jonathandienst
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Simply put the difference is where the expression is evaluated:
$(Variable)
returns the expanded variable, which may then be evaluated by the expression. May be evaluated many times in a table.
$(=Variable)
evaluates the expression in the variable, and the value is returned. Evaluated once in a table or chart.
It is similar to the difference between a variable defined without a leading equals sign, or with a leading equals sign
EDIT - beaten to the punch by Marcus.
 
					
				
		
 kushalthakral
		
			kushalthakral
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Thank You All for your replies.
Regards
Kushal Thakral
 
					
				
		
 alsale_1968
		
			alsale_1968
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Hi,
Thanks. It has been very useful to me.
 ayandey18
		
			ayandey18
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Can anybody explain how the following expression perform on the run-time
vCompare = $(=If($(vTYMTDSales) - $(vLYMTDSales) > 0,0,1))
vCompare = =If($(vTYMTDSales) - $(vLYMTDSales) > 0,0,1)
