Viewing 15 posts - 736 through 750 (of 1,193 total)
You can't do that directly, unfortunately.
There's been at least one long-lived Connect item requesting this ability: https://connect.microsoft.com/SQLServer/feedback/details/352110/t-sql-use-scalar-functions-as-stored-procedure-parameters.
Until MS decides to allow scalar functions to be used directly for specifying parameter...
December 18, 2015 at 3:58 pm
That's the hashed key value.
If you are really digging into the locking behavior of your queries, you can use that to find the actual key value locked by using %%lockres%%....
December 18, 2015 at 1:47 pm
Yeah, since you had a lock partition of 106, that indicated at least 107 (it starts at 0). I was curious how many more there were. That's a very nice...
December 18, 2015 at 12:46 pm
For that, the format is db_id:object_id:lock_partition.
https://technet.microsoft.com/en-us/library/ms187504(v=sql.105).aspx explains lock partitioning.
106 is a very large number for that. Out of curiosity, how many cores do you have on that machine?
Cheers!
December 18, 2015 at 12:10 pm
Here's an alternative solution, but with some additions to the sample data it gives different results than Chris'.
What is the expected result with the following rows added?
INSERT INTO workorders VALUES...
December 17, 2015 at 1:06 pm
Duplicate post of http://www.sqlservercentral.com/Forums/Topic1745830-2799-1.aspx.
December 16, 2015 at 4:37 pm
Yes, 9 is the database_id. The second number is the partition_id, so if test_db were the database with database_id of 9, you could run this:
USE test_db;
SELECT ...
December 16, 2015 at 4:33 pm
Phil's solution is a nice way of doing what you're wanting to do.
You were encountering the error because the data type returned by a CASE is the data type with...
December 16, 2015 at 1:22 pm
The number of pages can be found by summing the backed_up_page_count in msdb.dbo.backupfile.
The throughput can be calculated a couple different ways. You could use backup_size in the msdb.dbo.backupset table, using...
December 16, 2015 at 11:05 am
I was just going to pick one of Nashville/Chicago/Cleveland, since they're the closest to me. Probably going to end up with Chicago, since travel's easiest to arrange for it.
December 16, 2015 at 8:24 am
Something like this?
CREATE TABLE test_table1 (first_string varchar(MAX),
...
December 15, 2015 at 3:49 pm
Jason A. Long (12/10/2015)
sql84 (12/10/2015)
the only purpose of this table to be used by a reporting tool. this table is...
December 10, 2015 at 4:26 pm
Frank Dijk (12/10/2015)
Thank you very much Jacob.I think I found it with your help. I changed MIN to MAX(id) and that worked.
Adding the column is helpful indeed.
Thank you again!
I...
December 10, 2015 at 2:37 pm
As I understand your requirement, that should be the correct result.
You can see that by adding MIN(ID) to the column list returned by the SELECT.
| getal | aantalmaal | MIN(ID)...
December 10, 2015 at 2:25 pm
Frank Dijk (12/10/2015)
Thank you for your reply.Unfortunately the addition of MIN(id) ASC does not the trick. It's not always working 🙁
For your info: It is MySQL (if that matters).
As Gail...
December 10, 2015 at 12:08 pm
Viewing 15 posts - 736 through 750 (of 1,193 total)