Viewing 15 posts - 196 through 210 (of 225 total)
Michael, are you a local administrator on the machine you installed MSDE (desktop engine) on? By default, MSDE should allow administrators to connect with the "-E" option because of a SQL...
January 21, 2005 at 1:49 pm
This may be moot because using a temp table for a large count set is desirable, but what if the record count exceeded 2,147,483,647 (the count function returns and integer), do you...
January 19, 2005 at 11:01 am
This has been a really fun topic! Just for fun I populated a huge CHECK_DATA table to see the effects of the queries for a long history. I am getting the...
January 19, 2005 at 10:04 am
I think 2GB is it. Although, with SQL Standard licensed per processor, maybe a machine with 4GB memory, and 2 instances of SQL standard could each use their own 2GB??
I'm...
January 19, 2005 at 8:26 am
Andreas, you can avoid a temp table - that is what Steve's solution was for. Post your table name and properties if need be and we can post the exact...
January 19, 2005 at 6:51 am
Andreas, Steve's solution is correct (and clever):
Based on your example:
Create TABLE temptable (col1 varchar(10), col2 varchar(10), col3 varchar(10))
GO
INSERT INTO temptable values('Val 1a', 'Val 2a', 'Val 3a')
INSERT INTO temptable values('Val 1b',...
January 18, 2005 at 3:20 pm
Can you live with a table variable???
DECLARE @tempTableVariable TABLE (IDENT int IDENTITY(1,1), col1 varchar(10), col2 varchar(10), col3 varchar(10))
INSERT INTO @tempTableVariable
SELECT * FROM SourceTable
select * from @tempTableVariable
Yields:
1 Val 1a Val 2a Val 3a
2 Val 1b Val...
January 18, 2005 at 2:42 pm
Matt, I'm sure there is a much more creative way to do this without a temp table, but here is an untested solution with a temp table.
CREATE TABLE #UnionTable (BusinessDate...
January 17, 2005 at 2:16 pm
Simon, you may get a lot of differring opinions on this - and in many cases it will depend on the specific situation. However, as a GENERAL guideline, I always...
January 17, 2005 at 8:07 am
That's an interesting problem. This may not be the best way to do this...but, a quick way I would do it would be to:
Create a temp table and change the...
January 17, 2005 at 7:29 am
Senthil,
As a final note. See Remi's use of the table variable. If you are using this for a one time query, you really will want to do it that way. ...
January 14, 2005 at 2:54 pm
Wayne, maybe my Friday afternoon reading is getting a bit lazy - if so please forgive...
Anyway, BOL states: "If the values in the VALUES list are not in the same...
January 14, 2005 at 2:49 pm
From books on line:
"TRUNCATE TABLE permissions default to the table owner and are not transferable."
Ryan
January 14, 2005 at 2:34 pm
Senthil, is this an example of what you are looking for?
use tempdb
create table sp_who (ID INT IDENTITY (1,1) NOT NULL
,spid varchar (10)
,status varchar (20)
,loginname varchar(20)
,hostname varchar(20)
,blk varchar(20)
,dbname varchar(20)
,cmd varchar(20))
GO
use master
INSERT...
January 14, 2005 at 2:29 pm
Wayne,
For example one you have to explicitly state your insert fields since you are not inserting into the identity column. Simply adding the insert fields makes it work.
DECLARE @tmp1 TABLE...
January 14, 2005 at 2:19 pm
Viewing 15 posts - 196 through 210 (of 225 total)