Viewing 15 posts - 58,771 through 58,785 (of 59,076 total)
Hi Michael,
Doesn't having the full table name on columns make the code a bit difficult to read for troubleshooting? I guess it would be ok if the table names were...
--Jeff Moden
Change is inevitable... Change for the better is not.
May 1, 2005 at 7:12 am
Just about anything that can get to the xp_CmdShell and, that would be a lot of things... that's why a lot of DBA's disable it. I don't know how to...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 30, 2005 at 9:06 am
If you truly need to use positive logic (IS NULL instead of IS NOT NULL) and you also want to check for a zero value, the NULLIF function does a...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 29, 2005 at 9:32 pm
For goodness sake, add a Primary Key to the table. Not for sorting but will nearly double the speed at which queries on large wide tables run because SQL doesn't...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 29, 2005 at 9:17 pm
I agree with Ray's basic idea but, just a thought... table names, especially when they are large, can make code pretty well unreadable. I usually use 1, 2, or 3...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 29, 2005 at 9:12 pm
Very, very nice. I do a lot with Hierarchies and this will really help when 2005 comes out. Your examples and text based diagrams are awsome. Thank you very much...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 26, 2005 at 11:38 am
>I cannot get Jeff's solution to work without using GETDATE().
What I wrote was meant to solve the original posting which stated... "I would like to be able to...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 25, 2005 at 11:02 pm
If the file you are trying to bring in is a text file (fixed field, CSV, Double-Quoted CSV, etc), you can use BCP or, perhaps, Bulk Insert which both operate...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 24, 2005 at 7:54 pm
If you aren't making any modifications, seems like the old DOS COPY command would work better and faster. ![]()
What is it that you are...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 24, 2005 at 7:40 pm
Angela,
Lookup "Expanding Hierarchies" in "Books Online"... has full explanation and an easily modifiable example script that could be changed to a stored procedure. That's one way to do this.
Another way...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 24, 2005 at 7:33 pm
Here's a couple of other ways...
SELECT
LEFT(SalesName,25) As Name
FROM
CommERV
WHERE
ProcessDate = '1/1/05'
AND RevDate = '1/1/05'
AND TIN = '2042416'
SELECT
CAST(SalesName AS VARCHAR(25)) As Name
FROM
CommERV
WHERE
ProcessDate...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 23, 2005 at 9:24 pm
If you have a clustered index or a primary key on the table (and you absolutely should have a Primary Key on every table), the data will be displayed in...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 23, 2005 at 9:14 pm
Andrew,
You'll need to limit the outputs of the UDF's to make it fit your needs, but here's the whole ball of wax... explanation is in the comments. Includes the test...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 23, 2005 at 8:57 pm
High praise from the resident MVP. Thanks, Frank.
--Jeff Moden
Change is inevitable... Change for the better is not.
April 23, 2005 at 8:09 pm
I would do as you said... add the extra column with the 2 character country code to the Country table .
--Jeff Moden
Change is inevitable... Change for the better is not.
April 23, 2005 at 12:29 pm
Viewing 15 posts - 58,771 through 58,785 (of 59,076 total)