You are on page 1of 3

Cold Fusion 1.How do you print today’s date in (Tuesday, September 15,1998) format? 2.

Suppose in the address bar of your browser, the following address is written: How would you print the value of the URL? 3.How do you redirect a user to the page newemployee.cfm? (i)<cfredirect url=”newemployee.cfm”> (ii)<cfredirect goto=”newemployee.cfm”> (i)<cflocation url=”newemployee.cfm”> (i)<cflocation goto=”newemployee.cfm”> 4.Which of the following template displays the page a user came from? (i) #CGI.REFERER# (ii) #CGI.HTTP_REFERER# (iii) #CGI.HTTP_USER_AGENT# (iv) #CGI.USER_AGENT# 5.How do you print the value of 38? 6. (i)Differenciate between primary key and foreign key? (ii)Differenciate between count and count(*)? 7.Consider the following table---S.No Emp 1 Narendra 2 Saurabh 3 Ravi 4 Ramesh 5 Vijay 6 Vijaita 7 Animesh 8 Sandhya 9 Rashi 10 aparna Table name is EMP and Database name is Employee. Write a cold fusion code to fetch 4,5,6 th record without using where clause from the above table ? 8.What will be the output of the following cold fusion code? (i) <cfoutput> #ListFirst(“1,2/3,4”,”/”)# </cfoutput> (ii) <cfoutput>

4”)# </cfoutput> 9.D” .K. specify where it is? From=abc@yahoo.Differenciate between StructDelete and StructClear? 12.J. 10. specify where it is? .Write a coldfusion code for that.Consider the list “A.B.Consider the following code and tick on the correct answer <html> <body> <form> <cfinput type=text name=”txtemp”> <cfinput type=Submit name=”submit” value=”Submit”> </form> </body> </html> (i) the code executes without giving error (ii) if error exists.If we execute the following code.G. Write cold fusion code to add “E” to the end of the list.M” . Write a code for mail tag. Suppose we want to add “F” at the fifth position of the above list. <cfset A=”1”> <cfset B=”5”> <cfset C=A+B> <cfoutput> #C# </cfoutput> (i) (ii) the code executes without giving error if error exists. 11.#ListFirst(“1.E.C.C.B.Consider the list “A.How do you end a loop before it’s completion? (i) <cfabort> (ii) <cfexit> (iii) <cfbreak> (iv) break 14. The following are given To=xyz@yahoo.specify what will happen? Tick one of them.2/ Subject=”Sample Cold Fusion Example” Message=”Hi my name is Narendra” 13.