macromedia.coldfusion.database_access
[Top] [All Lists]

Re: CF to MySQL stored proc question

Subject: Re: CF to MySQL stored proc question
From: "MichaelSJudd" <mikejudd@xxxxxxxxxxxxxxxx>
Date: Tue, 15 Apr 2008 04:59:11 +0000 (UTC)
Newsgroups: macromedia.coldfusion.database_access

Well, when I use the Stored Procedures, I simply access the cfprocresult's 
RecordCount to see if anything was returned. The specifics (from example 2 that 
you had) is:

 <cfif searchResults.RecordCount GT 0>
 do the "yup he's a real guy"
 <cfelse>
 do your failure routine
 </cfif>

 You should get an error message, for instance, if you tried to do a cfoutput 
on that variable, that you are trying to access a complex data type (or 
something like that). So I would try to access the RecordCount as 0 or not 0 if 
you are simply looking to see if it found SOMETHING.

 - Mike


<Prev in Thread] Current Thread [Next in Thread>