Viewing 15 posts - 151 through 165 (of 260 total)
I can make the msdb.dbo.agent_datetime function fail by supplying an invalid date value, such as 0 (zero). If you have invalid date values in your job history, and I'm...
February 1, 2022 at 8:02 am
In my case the SQLAgent script chokes on a disabled job where the date and time values passed to the function msdb.dbo.agent_datetime(R.run_date, R.run_time) are null values.
January 28, 2022 at 1:56 pm
I'd like to try SQLAgent but I get a conversion failed error. Can the author take a look a that?
Same here. Two Agent jobs returned and then the script...
January 28, 2022 at 1:33 pm
I'm no expert on MySQL at all (never used it), but I'm a little confused about the reference to MariaDB in the error message. I know MariaDB started out from...
November 30, 2021 at 6:06 pm
Okay, yes, you are of course correct. GO is not a TSQL instruction, so it cannot be used in a stored procedure.
I would try to split the code into two...
November 9, 2021 at 3:22 pm
You probably have to insert a batch separator (the standard batch separator is GO) before your -- SOME LOGIC section.
tsql - SQL Server: What are batching statements (i.e. using...
November 9, 2021 at 2:18 pm
This should work, I think:
UPDATE t
SET t.CarStatus = '2'
FROM #Test t
INNER JOIN (
SELECT CarID, MIN(Id) AS Id
FROM...
November 8, 2021 at 8:18 am
Or maybe even better, simply reverse the order of the join criteria? Might work... 🙂
SELECT a.a3ltrcode, b.CommentCode
FROM a3ltrcodeTBL a
INNER JOIN Comments b ON a.a3ltrcode =
...
November 5, 2021 at 3:37 pm
I have a table with 3 letter codes, and I have a comment table with comment codes. The comment code used is dependent on the 3 letter code. So...
November 5, 2021 at 3:07 pm
Oh, I think you mean the comment by Joe Celko about your low score etc.
Yes, I meant that. I really can't believe I reached out for help and...
November 5, 2021 at 1:59 pm
Huh??
Oh, I think you mean the comment by Joe Celko about your low score etc., even if you didn't quote that. At least I hope you didn't refer to my...
November 5, 2021 at 1:28 pm
I would probably create a mapping table between City and Region:
create table dbo.City2RegionMap (
City varchar(20) not null,
Region varchar(20) not...
November 5, 2021 at 10:01 am
This should work, I think:
UPDATE t
SET t.CarStatus = '2'
FROM #Test t
INNER JOIN (
SELECT CarID, MIN(Id) AS Id
FROM #Test
...
November 5, 2021 at 9:23 am
I'm not a SSRS expert. I know enough to get myself in trouble. Anyway, if memory serves, I recall seeing somewhere a blog post, maybe a Microsoft...
November 4, 2021 at 4:27 pm
/* Setting up test data */
declare @sales table (
DMDUNIT char(1),
U_ONSALE_DATE date
)
insert into @sales (DMDUNIT, U_ONSALE_DATE)
...
October 21, 2021 at 10:51 am
Viewing 15 posts - 151 through 165 (of 260 total)