SQL and VB.NET Programming Basics
Test your knowledge of SQL Server queries and VB.NET programming concepts including aggregate functions, joins, constraints, object-oriented programming, and .NET features.
Questions
What is used to validate complex string patterns like an e-mail address ?
- Extended expressions
- Regular expressions
- Irregular expressions
- Basic expressions
Some bits of a Visual Basic 6 application, like most APIs, can be easily migrated to VB.NET; other parts are not so straightforward. Which of the following will NOT have to be re-architected during a VB 6-to-VB.NET migration ?
- DHTML pages
- ADO to ADO via Interop
- ActiveX documents
- OLE controls
which program will you use to assemble a program written in IL:
- ildasm
- clr
- ilasm
- All the above
What’s the difference between a class field property ?
- A field always has Get and Set Methods
- A property always has Get and Set Methods
- Both 1 and 2
- None of the above
Can you create Windows Services using VB.Net
- Yes
- No
- Not always
- None of these
Can a toolbar display text instead of pictures in the buttons ?
- No, a toolbar can only display images
- No, a toolbar can only display text
- Yes, a toolbar can display text, images, or both.
- None of these
The vbc.exe compiler generates:
- IL Code
- Native code
- Byte Code
- None of these
Select the keyword used to refer the name space in our code in VB.Net
- Using
- Package
- Imports
- None of the above
How do you enable Strict Type Checking in VB.NET
- With OPTION STRICT ON keyword
- With OPTION EXPICIT Keyword
- With OPTION STRICT OFF keyword
- All the above
How do you Dereference an Object in VB.NET ?
- By setting the object to Null
- With Close keyword
- By setting the object to Nothing
- None of the above
What two controls are needed when creating a toolbar ?
- Only Toolbar control
- ImageList and Toolbar control
- Both 1 and 2
- All the above
With SQL, how do you select all the records from a table named "Persons" where the value of the column "FirstName" starts with an "a"?
- SELECT * FROM Persons WHERE FirstName='%a%'
- SELECT * FROmPersons WHERE FirstName LIKE '%a'
- SELECT * FROM Persons WHERE FirstName='a'
- SELECT * FROM Persons WHERE FirstName LIKE 'a%'
The OR operator displays a record if ANY conditions listed are true. The AND operator displays a record if ALL of the conditions listed are true
- True
- False
Which SQL statement is used to return only different values?
- SELECT UNIQUE
- SELECT DIFFERENT
- SELECT DISTINCT
- None of the above
With SQL, how can you return the number of records in the "Persons" table?
- SELECT COUNT() FROM Persons
- SELECT COLUMNS() FROM Persons
- SELECT COLUMNS(*) FROM Persons
- SELECT COUNT(*) FROM Persons
How many clustered indexes can be created on single table
- 1
- 128
- Up to number of columns in table
- 256
Which is not the type of join in SQL SERVER
- Inner
- Left
- Cross
- Multiple
- Right
Which of the following is not valid constraint in SQL SERVER
- Default
- Check
- Distinct
- Unique
Which SQL keyword is used to sort the result-set?
- ORDER BY
- ORDER
- SORT
- Distinct
Which of following is not an aggregate function in SQL SERVER
- MIN
- MAX
- AVG
- COUNT
- SUM
- GROUP