Viewing 15 posts - 16 through 30 (of 55 total)
CREATE TABLE TableTest1 (
ID INT NOT NULL,
CONSTRAINT PK_ID1 PRIMARY KEY(ID)
);
CREATE TABLE #TableTest2 (
ID INT NOT NULL
CONSTRAINT FK_TableTest1_ID FOREIGN KEY (ID) REFERENCES TableTest1(ID)
);
INSERT INTO TableTest1 (ID)
VALUES
(1);
INSERT INTO #TableTest2 (ID)
VALUES
(2);
select * from...
August 16, 2016 at 8:00 am
Thank you George Vobr, you are right, but if you do not use tempdb, it will not give you the information. The @@trancount will do.
July 27, 2016 at 12:22 pm
If I use #tbl for insert values, and use 'dbcc opentran' to see the active transactions, it give me
No active open transactions.
DBCC execution completed. If DBCC printed error messages,...
July 27, 2016 at 8:16 am
The question did not tell us what data type and how many characters it is. So the correcter answer will be depend on. for example:
declare @myString char(12);
set @myString...
February 19, 2016 at 11:38 am
Don, you are right, we should try only use explicit conversion for better performance.
October 29, 2015 at 8:37 am
try select cast('19.4615381' * -1.0 *1.00000 as numeric(18,6))
October 26, 2015 at 8:21 am
Every Problem has a Solution; Every Solution has a Problem: Smile:-P
July 27, 2015 at 8:04 am
Do not realized need to use Sql Server 2012 forward version. Is it possible to do same thing in SSRS 2008 R2?
July 23, 2015 at 11:58 am
How about use ISNULL?
-- Q3
SELECT
*
FROM
#abc a
...
April 29, 2015 at 7:50 am
Can we use Group By 1,2,3, ... to make query DRYer it?
April 7, 2015 at 12:48 pm
Viewing 15 posts - 16 through 30 (of 55 total)