Viewing 15 posts - 5,911 through 5,925 (of 14,953 total)
Check out sp_MSForEachDB and see if that will do what you need.
Or create a group that has read/write access to all databases, and add him to that group instead of...
- Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
Property of The Thread
"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon
November 23, 2010 at 9:06 am
There are a few things you could do.
One would be to add a check to your hourly job for databases with no backup history.
One would be to run...
- Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
Property of The Thread
"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon
November 23, 2010 at 9:03 am
On the first stored procedure, I'd convert all the inserts into the table variable into a single CTE, with a few OR statements in the Where clause. Then get...
- Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
Property of The Thread
"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon
November 23, 2010 at 7:13 am
It's definitely not useless data. It's very useful. It just needs some caveats, which it has. It's a good article and obviously took a lot of work...
- Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
Property of The Thread
"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon
November 23, 2010 at 6:39 am
If the value will come in any way from user input, make sure to check it against sys.databases, before you build it into a string you're going to execute.
First, it...
- Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
Property of The Thread
"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon
November 23, 2010 at 6:35 am
You're welcome.
- Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
Property of The Thread
"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon
November 23, 2010 at 6:34 am
You'd use string concatenation.
Say, for example, you have three search fields: First Name, Last Name, Department
If someone fills in Last Name only, you'd have:
"Where LName = 'whatever they typed'"
If they...
- Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
Property of The Thread
"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon
November 23, 2010 at 6:32 am
CirquedeSQLeil (11/22/2010)
GSquared (11/22/2010)
CirquedeSQLeil (11/22/2010)
- Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
Property of The Thread
"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon
November 22, 2010 at 2:43 pm
You can't just split up rows by group, you have to indicate what groups can view what what rows, and that's essentially a many-to-many join. Those can be efficient,...
- Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
Property of The Thread
"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon
November 22, 2010 at 2:39 pm
Try something like this:
DECLARE @String VARCHAR(100);
SELECT @String = '122 campbell ave., west haven, CT 00000-0000';
SELECT
SUBSTRING(@String,
0,
CHARINDEX(',', @String)),
SUBSTRING(@String,
CHARINDEX(',', @String)+1,
CHARINDEX(',', @String, CHARINDEX(',', @String)+1)-CHARINDEX(',', @String)-1),
SUBSTRING(@String,
CHARINDEX(',', @String, CHARINDEX(',', @String)+1)+2, 2),
SUBSTRING(@String,
CHARINDEX(',',...
- Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
Property of The Thread
"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon
November 22, 2010 at 2:37 pm
Right, but do the groups overlap on what data they can see?
- Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
Property of The Thread
"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon
November 22, 2010 at 2:27 pm
You can't restore databases to prior versions of SQL Server. Can't detach-reattach back versions either, for the same reasons.
Import/Export will work. Either with a wizard or with SSIS,...
- Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
Property of The Thread
"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon
November 22, 2010 at 2:26 pm
Would adding a row_number() column (that's a function) do what you need?
- Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
Property of The Thread
"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon
November 22, 2010 at 2:25 pm
Is the security hierarchical? As in, do people in Group A get to see their own data, and that of Group B and Group C, while Group B can...
- Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
Property of The Thread
"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon
November 22, 2010 at 2:24 pm
Unfortunately, I'm not particularly familiar with merge replication. I'm more accustomed to either transactional or snapshot. Can't really help you on that point.
If it were me, I'd read...
- Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
Property of The Thread
"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon
November 22, 2010 at 2:20 pm
Viewing 15 posts - 5,911 through 5,925 (of 14,953 total)