Advanced Web Programming MCQ's With Answers
AWP UNIT 4 MCQ's
1. In disconnected data access, _________ object is used to manage the connection with the data source.
- DataReader
- DataAdpater
- DataSet
- SqlCommand
Ans : DataAdpater
2. In disconnected data access model ________ is used to keep copy of data in memory
- DataReader
- Database
- DataSet
- DataAdpater
Ans : DataSet
3. Which of the following is not an ADO.NET object?
- Connection
- Command
- DataReader
- Table
Ans : Table
4. ______ is standard data access language used to interact with relational databases.
- XML
- SQL
- T-SQL
- XSL
Ans : T-SQL
5. The data binding is perform ____________.
- Before page init
- After page render
- During page render
- Before page render
Ans : Before page render
6. Which of the following is the correct syntax of single value data binding?
- <% expression %>
- <%# expression %>
- <%# expression #%>
- <% expression -->
Ans : <%# expression %>
7. If you are using DataSet and you have to display the data in soted order then what will you do?
- Use Sort() method of DataTable
- Use Sort() method of DataSet
- Use DataView object with each sort.
- Use DataPaging and sort data
Ans : Use DataView object with each sort.
8. How do you execute multiple SQL statements using a DataReader?
- Call the ExecuteReader method of two Command objects and assign the results tothe same instance of a DataReader
- Set the Command.CommandType property to multiple result sets
- Call the ExecuteReader method of a single Command object twice
- Set the Command.CommandText property to multiple SQL statements delimited by a semicolon.
Ans : Set the Command.CommandText property to multiple SQL statements delimited by a semicolon.
9. Which property can be used to configured the numbers and dates using a format string.
- FormatSting
- DataFormatingString
- DataFormate
- DataFormatSring
Ans : DataFormatingString
10. Which property is perticularly used to specify the data source object to which the control link?
- Bind
- DataSource
- DataTextField
- DataValueField
Ans : DataSource
11. ______object can hold more than one rowset from the same data source and the relationships between them.
- DataReader
- DataSet
- OleDB connection
- DataAdapter
Ans : DataSet
12. To enables the inserting a row in details view _________________ property is to be true.
- AutoGenerateInsertButton
- AutoInsertButton
- InsertButton
- GenerateInsertButton
Ans : AutoGenerateInsertButton
13. Optimistic Concurrency control is based on______________.
- Record Number
- Record ID
- RecordIndex
- Record Version
Ans : Record Version
14. Which of the following is not DataReader mothod?
- NextResult()
- GetName()
- GetValue()
- GetDataType()
Ans : GetDataType()
15. Which of the following is not a connection string property?
- Data Source
- Initial Catalog
- Database Name
- Integrated Security
Ans : Database Name
16. ____________works in a connected environment and supports forward-only, read-only access to data in the data source.
- DataAdapter
- DataReader
- DataSet
- DataTable
Ans : DataReader
17. The value of the data-binding-expression will be substituted when you call ____________ method for the page.
- Construct()
- DataBind()
- Eval(String)
- LoadControl(String)
Ans : DataBind()
18. In repeated-value data binding ____________method activates the binding.
- Bind();
- Binding()
- Refresh()
- DataBind()
Ans : DataBind()
19. Linking __________ control to a data source is an example for repeated-value binding.
- TextBox
- Label
- ListBox
- LinkButton
Ans : ListBox
20. Which of the operation is not supported by GridView?
- Select
- insert
- Edit
- Delete
Ans : insert
21. Which of the following is not a valid templates for FormView?
- ItemTemplate
- EditItemTemplate
- InsertItemTemplate
- DeleteItemTemplate
Ans : DeleteItemTemplate
22. _____________ is the process how the user interface controls of a client application are configured to retrieve from, or update data into, a data source.
- Auto generation of rows
- Paging
- Data binding
- Data formatting
Ans : Data binding
23. ___________ feature of FormView support backward and forward traversal.
- Data binding
- BoundField
- Paging
- TemplateField
Ans : Paging
24. ___________ control displays data provided by a data source in a tabular format.
- DetailsView
- GridView
- FormView
- ListView
Ans : GridView
25. Which of the following is not a property of a GridView?
- AutoGenerateInsertButton
- AutoGenerateDeleteButton
- AutoGenerateEditButton
- AutoGenerateSelectButton
Ans : AutoGenerateInsertButton
26. Which of the following is not a style element of a GridView?
- RowStyle
- SelectedRowStyle
- ItemStyle
- DataStyle
Ans : DataStyle
27. Which of the following method is wrong for adding a select button for each row of a GridView?
- By adding a BoundField with HeaderText = "Select"
- By adding a CommandField column with the ShowSelectButton property set to true.
- By adding a ButtonField column with the CommandName property set to “Select”.
- By setting AutoGenerateSelectButton attribute of GridView to True.
Ans : By adding a BoundField with HeaderText = "Select"
28. Which of the following is not an ADO.NET class for SQL Server data provider?
- sqlConnection
- sqlCommand
- sqlDataReader
- sqlTable
Ans : sqlTable
29. Sqlcomma Do class is present in _________________ namespace.
- System.Web
- System.Data.SqlTypes
- System.Data
- System.Data.SqlClient
Ans : System.Data.SqlClient
30. Which of the following is not an ADO.NET class for SQL Server provider?
- sqlConnection
- sqlCommand
- sqlDataReader
- sqlTable
Ans : sqlTable
Post a Comment