Viewing 15 posts - 1,606 through 1,620 (of 3,489 total)
DECLARE @Ref VARCHAR(7) = '103-B00';
SELECT LEFT(@Ref,CHARINDEX('-',@Ref,1)-1);
February 25, 2017 at 9:07 pm
Consumable data?
February 25, 2017 at 11:17 am
Can you post the values assigned to the input parameters when you called it? And the CREATE TABLE script for the table you're inserting into?
February 24, 2017 at 8:59 pm
If all you want is a verbatim copy as a base for your new stored procedure, you can do something like this:
Right-click on the stored procedure you want...
February 22, 2017 at 2:15 pm
Build out a piece of it, add some dummy data and write some queries. Lather, rinse repeat. That's the way most of us learned. If you make a mistake, your...
February 21, 2017 at 8:07 pm
Not near enough information to tell. Reducing the number of subreports by merging datasets, if possible.
You know you sound exactly like Wendy Elizabeth? Same expressions and speech patterns,...
February 21, 2017 at 12:20 pm
Could you post the CREATE TABLE and INSERT scripts to give us some sample data and then an example of the expected output? Answering your questions is just waaaay too...
February 20, 2017 at 9:59 pm
Oh, like that... (feeling stupid)... definitely easier to see if they're all together, but I get it. Thanks!
February 20, 2017 at 12:34 am
I think this works... test it on a bigger dataset:
SELECT *
FROM (
SELECT SrvName
, [status]
, run_dt
, ROW_NUMBER() OVER (PARTITION BY SrvName, [Status]...
February 20, 2017 at 12:32 am
This is a 'Gaps and Islands' question. You're looking for all islands of size 4 or greater.
http://www.sqlservercentral.com/articles/T-SQL/71550/
February 20, 2017 at 12:05 am
Do you mean you want to use some code to identify the columns that only contain nulls so that you can skip them? If you know which columns are always...
February 19, 2017 at 6:35 pm
Ed,
Do you have an example of creating constraints the way Gail does, but naming them? The only examples I have seen require an ALTER TABLE ADD CONSTRAINT style... I...
February 19, 2017 at 4:56 pm
Probably a silly question, but if you don't name the foreign key, how do you drop it (the easy way)? Can you name the constraint when you declare it that...
February 19, 2017 at 12:57 pm
Does it work? Can you query the table to get the answers you need?
February 19, 2017 at 12:43 pm
Something like this?
CREATE TABLE dbo.Grades (
StudentID INT
,ExamID INT
,Grade TINYINT
,StudentStatus VARCHAR(10)
CONSTRAINT pkGrades PRIMARY KEY (StudentID, ExamID)
);
GO
ALTER TABLE dbo.Grades...
February 19, 2017 at 11:46 am
Viewing 15 posts - 1,606 through 1,620 (of 3,489 total)