Viewing 15 posts - 2,221 through 2,235 (of 2,458 total)
If you have db backed up as a single .BAK file then restoring the database is the only way I can think of; there is no way to dig around...
June 25, 2013 at 9:39 am
Are you looking for something like this...
--(1) THE DATA
IF OBJECT_ID('ajbtest.dbo.PivotA') IS NOT NULL
DROP TABLE PivotA;
CREATE TABLE dbo.PivotA (IDT int, A int, B int);
INSERT dbo.PivotA VALUES (24,1,-1),(24,2,-2),(24,3,-3),(24,4,-4),(25,5,-5),(25,6,-6),(25,7,-8),(26,8,-8),(26,9,-9),(26,10,-10);
--SELECT * FROM dbo.PivotA;
--(2) THE...
June 19, 2013 at 12:46 pm
sabah_seattle (6/14/2013)
Thanks for responding. Here is the error I am getting -
An error occurred during local report processing
An error has occurred during report processing.
Query execution failed for dataset "Sales".
Login...
June 17, 2013 at 9:32 am
HowardW (6/13/2013)
You can write your own queries, using the DMVs, which is a good learning exercise, but I'd recommend using the brilliant sp_whoisactive.
I wanted to second that.
June 13, 2013 at 9:55 am
To get rid of those dashes you could do something like this:
DECLARE @x XML,
@x1 varchar(1000)='
- <CLUB>
-...
June 13, 2013 at 9:31 am
You would need to do something like this:
-- (1) SAMPLE DATA SETUP
IF OBJECT_ID('tempdb..#tblHoliday') IS NOT NULL
DROP TABLE #tblHoliday;
IF OBJECT_ID('tempdb..#dates') IS NOT NULL
DROP TABLE #dates;
--Holiday table, I only added New Years,...
June 12, 2013 at 10:55 am
Ed Wagner (6/12/2013)
Depending on how you write it, this approach can be very efficient.
After...
June 12, 2013 at 8:09 am
mike.dinnis (6/12/2013)
I have a table with five fields used to hold address data. Due to poor practices the users have been able to enter any data in any field. They...
June 12, 2013 at 7:52 am
I have a solution that will work with your sample data. I was trying to come up with something that works when there are more than 3 records but this...
June 7, 2013 at 3:31 pm
vxhughes (6/6/2013)
I've already started on
http://beginner-sql-tutorial.com/sql-commands.htm
and
http://www.w3schools.com/sql/sql_intro.asp
and I've bookmarked "Stairway to T-SQL DML" at
http://www.sqlservercentral.com/stairway/75773
A couple of quick questions:
• Which of Itzik Ben-Gan's T-SQL fundamentals books do I...
June 6, 2013 at 12:53 pm
OTF (6/6/2013)
bgraham 64271 (6/5/2013)
SQLSACT (6/5/2013)
vxhughes (6/4/2013)
Can anybody recommend a good online guide to SQL commands? Or at least a list of the ones I should learn first?
Have a look...
June 6, 2013 at 10:33 am
Misread the requirement. Comment removed.
May 29, 2013 at 9:19 am
Something like this perhaps:
IF OBJECT_ID('tempdb..#tmp') IS NOT NULL
DROP TABLE #tmp;
CREATE TABLE #tmp (val varchar(10) primary key)
GO
INSERT INTO #tmp
SELECT '5'UNION ALL
SELECT '6DN'UNION ALL
SELECT '7'UNION ALL
SELECT '10'UNION ALL
SELECT '11DN'UNION ALL
SELECT '12'UNION ALL
SELECT...
May 29, 2013 at 9:08 am
SQL_Surfer (5/29/2013)
May 29, 2013 at 8:48 am
Lynn Pettis (5/28/2013)
Alan.B (5/28/2013)
OTF (5/22/2013)
phc (5/18/2013)
SELECT C.first_name"Provider", Count(C.provider_no) "Diabetics with...
May 28, 2013 at 5:11 pm
Viewing 15 posts - 2,221 through 2,235 (of 2,458 total)