Stump the CFChump - 4
Published on
I am doing a "Stump the CFChump" series. I recently passed the ColdFusion 9 exam and this is material I learned while studying. I have several CodeSchool gift cards to giveaway so comments who answer correctly I'll email you the discount code. "Stump the Chumps" is from the "Car Talk" so I am spinning that title for ColdFusion. These are questions that stumped me when studying.
- Please try to not google or run the code before answering.
- This is for fun so don't be afraid to guess.
- Let others guess so phrase your comment like "I think ... because ..." or "My guess is ... because ...".
- I ran out of code school gift cards and will be getting more.
Stump the CFChump 3
Answer
Stump the CFChump 4
Question
What tag and attribute would you use to set the maximum number of rows returned to 10 in the code below?
COLDFUSION
<cfstoredproc procedure="foo_proc"
dataSource = "MY_SYBASE_TEST" username = "sa"
password = "" dbServer = "scup" dbName = "pubs2"
returnCode = "Yes" debug = "Yes">
<!--- cfprocresult tags --->
<cfprocresult name="RS1">
<!--- cfprocparam tags --->
<cfprocparam type="IN" cfsqltype="CF_SQL_INTEGER" value="1">
<cfprocparam type="OUT" cfsqltype="CF_SQL_DATE" variable="FOO">
<!--- Close the cfstoredproc tag. --->
</cfprocparam>
Answers
A.
COLDFUSION
<cfstoredproc maxrows="10" ...=""></cfstoredproc>
COLDFUSION
<cfprocresult maxrows="10" ...="" ></cfprocresult>
COLDFUSION
<cfprocparam type="IN" maxrows="10" ...=""></cfprocparam>
COLDFUSION
<cfprocparam type="OUT" maxrows="10" ...=""></cfprocparam>