Hey, I have recently been asked these questions in an interview. Could someone answer them plz? - Can you create a MS SQL Server 2000 database using an asp page? If yes how, if no why not? - whats the capacity of bigint datatype in mssql server 2005. - How will it effect a sql query if i use a varchar datatype instead of a date datatype in ms sqlserver database. thanx
I believe bigint is 8 bytes which makes it 64 bits minus one for the sign. That gives you 2^63 as the max and 2^63 as the min. (+- 9223372036854775808) If you sort a varchar in the form of a date vs sorting a date type, the order will be incorrect. Varchars are also flexible in length where date is fixed in length. You could create a Database from an ASP page as long as the database user has the permissions to do so. Simply using the syntax "CREATE DATABASE databasenamehere"