Viewing 15 posts - 2,446 through 2,460 (of 7,613 total)
Yes, that is common but horrible, but at least it would not affect the logical design, which could still be forward engineered to proper physical form. Just keeping accurate logical...
SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".
March 9, 2020 at 2:12 pm
Sure, you could do a design with only pencil and paper, just as you can eventually get across town by walking. But for anything but the most trivial design, you...
SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".
March 9, 2020 at 1:58 pm
I suspect you many not need individual dates in the result at all. I also adjusted the range to 7 days rather than 8, as a week seems like a...
SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".
March 6, 2020 at 8:55 pm
SQL's Query Cost Governor is all that I'm aware of toward that end. This is a before-execution, based-on-estimates governor, so it's not 100% accurate. But hopefully it would prevent anything...
SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".
March 6, 2020 at 6:26 pm
The single most important thing to understand, though, is that data modeling is a logical process, not a physical one.
Physical things -- identities, files, etc. -- do not exist in...
SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".
March 5, 2020 at 8:36 pm
ERwin is great, one of the best tools I've ever used, but it is expensive.
An excellent feature to look for is a "data dictionary" / "data element" component. That is,...
SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".
March 5, 2020 at 8:34 pm
>> Since the incoming sales order notes will not have the same PK (NoteID) value as before (due to an auto-incrementing PK) <<
Turn off the auto-incrementing for the rows you're...
SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".
March 4, 2020 at 9:27 pm
No. CHECK does not go across rows. You will need an index or some other multi-row method.
SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".
March 4, 2020 at 8:31 pm
Whether the number must be NULL or NOT NULL can be done with a CHECK constraint:
CONSTRAINT data__CK_1
CHECK(CASE WHEN letter_column = '1e' THEN CASE WHEN number_column IS NULL THEN 1
ELSE 0...
SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".
March 4, 2020 at 7:36 pm
I don't believe the inserted table (view), which is current data, could be created from a version store, which is historical data.
SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".
March 3, 2020 at 3:31 pm
First, can someone speak to the premise that the entire row is updated when updating one column?
No. Only the modified column(s) are updated.
We can certainly prove that with...
SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".
March 3, 2020 at 3:16 pm
My inclination would be to move the char(7200) to a different table. Or, depending on the specific circumstances, change it to varchar(max) and force it LOB (out of the main...
SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".
March 2, 2020 at 10:25 pm
First, can someone speak to the premise that the entire row is updated when updating one column?
No. Only the modified column(s) are updated.
Is this a good suggestion? What are the...
SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".
March 2, 2020 at 9:43 pm
Is the view reference directly in the code or is it some type of generated / dynamic SQL? Naturally the view can only give references for the code that is...
SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".
March 2, 2020 at 9:30 pm
Not perfect, but this should get you much closer:
SELECT
ReferencingObjectType = o1.type,
ReferencingObjectName = o1.type_desc,
ReferencingObject = SCHEMA_NAME(o1.schema_id)+'.'+o1.name,
ReferencedObject = ISNULL(ed.referenced_database_name, DB_NAME()) + '.' +
...
SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".
March 2, 2020 at 8:42 pm
Viewing 15 posts - 2,446 through 2,460 (of 7,613 total)