Contents > CFML Reference > ColdFusion Functions > IsSimpleValue PreviousNext

IsSimpleValue

Determines the type of a value.

True, if value is a string, number, Boolean, or date/time value; False, otherwise.

Decision functions

IsSimpleValue(value)

Parameter

Description

value

Variable or expression

<!--- Shows an example of IsQuery and IsSimpleValue --->
<h3>IsSimpleValue Example</h3>
<!--- define a variable called "GetEmployees" --->
<cfparam name = "GetEmployees" default = "#Now()#">

<p>Before the query is run, the value of GetEmployees is 
<cfoutput>#GetEmployees#</cfoutput> <cfif IsSimpleValue(GetEmployees)> <p>GetEmployees is currently a simple value </cfif> <!--- make a query on the snippets datasource ---> <cfquery name = "GetEmployees" datasource = "cfsnippets"> SELECT * FROM employees </cfquery> <p>After the query is run, GetEmployees contains a number of rows
that look like this (display limited to three rows): <cfoutput QUERY = "GetEmployees" MaxRows = "3"> <pre>#Emp_ID# #FirstName# #LastName#</pre> </cfoutput> <cfif IsQuery(GetEmployees)> GetEmployees is no longer a simple value, but the name of a query </cfif>

Contents > CFML Reference > ColdFusion Functions > IsSimpleValue PreviousNext

ColdFusion 9 | ColdFusion 8 | ColdFusion MX 7 | ColdFusion MX 6.1 | ColdFusion MX | Forums | Developer Center | Bug Reporting

Version 6.1

Comments are no longer accepted for ColdFusion MX 6.1. ColdFusion 8 is the current version.