Viewing 15 posts - 2,941 through 2,955 (of 3,010 total)
The storage size of the decimal(19,0) is 9 bytes vs. 8 bytes for bigint, so it would save some storage space, but you wouldn't save that much space unless the...
February 25, 2007 at 4:34 pm
Here are a couple of way to do it:
select M1 = right(1000000+MyNumber,4) , M2 = right('0000'+convert(varchar(20),MyNumber),4) from ( select MyNumber=1 union all select 10 union all select 44 union all select 7777 union all select 9999 union all select 111 ) a
Results:
M1 M2 ---- ---- 0001...
February 24, 2007 at 11:01 am
One thing you might try, if you haven't already, is using Profiler to capture the query workload to a table, and then use the Index Tuning Wizard to see if...
February 23, 2007 at 9:10 pm
Sorry, but I'm sure you understand I don't want someone walking into the next interview knowing the answer in advance.
I will say it is based on a real question that...
February 23, 2007 at 8:07 pm
It is also possible that the database was originally developed in SQL Server 6.5 or 7.0 before the BIGINT datatype was available.
February 23, 2007 at 3:55 pm
I give people a test consisting of 5 questions with 4 SQL problems and one table design problem. I tell candidates that they have an hour to complete the test. ...
February 23, 2007 at 3:49 pm
Yes, maybe what you really need to do is add some indexes to some tables, or optimize some stored procedures. You need to be sure that you are actually doing...
February 22, 2007 at 9:10 am
Did anyone notice this? The new datatype, vardecimal, is available only in Enterprise Edition!
"Added new functionality in the SQL Server 2005 Enterprise Edition to provide another storage format that...
February 21, 2007 at 11:46 am
Add it the same way you would add any login to SQL Server.
February 21, 2007 at 11:36 am
Make another user the owner of the database, and then delete the user you want to get rid of.
February 20, 2007 at 11:43 am
You should read SQL Server 2005 Books Online:
February 19, 2007 at 3:33 pm
It would be a courtesy to at least post a link to the blog if you’re going to copy the whole thing:
http://weblogs.sqlteam.com/davidm/archive/2007/02/14/60092.aspx
February 19, 2007 at 9:39 am
Just run a DBCC SHRINKFILE EMPTYFILE on the file that contains all the data.
It will not let you completely empty the file, since it contains system objects, but it should...
February 19, 2007 at 8:48 am
Your link to "an interesting blog entry" is not working.
It strikes me as unfair that Microsoft insists on licensing SQL Server for each processor on the server, since their Virtual Server...
February 17, 2007 at 2:43 pm
This simple test works with any length of string:
declare @t table ( c varchar(20))
insert into @t select '11' union all select '1a' union all select 'a1' union all select '1 ' union all select...
February 17, 2007 at 11:55 am
Viewing 15 posts - 2,941 through 2,955 (of 3,010 total)