vongrunt,
The table is about 10GB. Yes, the update affects all 24M rows. And you will probably cringe - the update uses about 10 UDFs. However, the UDFs are in the various SET statements and not in the where clause. Also, each one of the UDFs mentioned in the SET statement have case...
I have a large table with 24 million rows. I have one complex update statement that is updating about 15 columns, but it is taking 4 hours to update the entire table.
I noticed when evaluating the table structure, that I have datatypes that are larger than necessary. For example, I have a...
donutman,
Here is the alter statement. It works with a create table statment:
ALTER TABLE CDW2POLICY_TRANSACTION
ALTER COLUMN POLICY_TRANSACTION_KEY INT IDENTITY(2766188, 1)
Error:
Incorrect syntax near the keyword 'IDENTITY'.
Also, my preference would be to have the seed value pulled from...
My source table has a integer key that sequentially numbers all the records inserted. I copied the records from that table into another with a slightly different structure for further staging. I did not set any constraints/properties on the second table's corresponding integer key, because I...
How do you load Query Designer? I see the reference in the manuals as Visual Database Tools. Is this a tool I have to load during the installation process?
Thank you for your help!
If you have a date for each start time and end time, you can use this to combine the date and time:
SELECT CAST(CAST('1899-12-30 22:35:12.000' AS DATETIME) + CAST('2004-12-17' AS DATETIME) AS DATETIME)
for each start and end date
Since 1899-12-30 represents a zero date, then adding the time +...
I'm attempting to make SQL Server transparent from a particular user's perspective. The user is very comfortable with MS Access. I have not done much using Access as a frontend to SQL Server, except linked tables through an ODBC connection.
What are the basic steps/commands to allow...
Donutman,
I wasn't really sure about your comment of "dynamic SQL" being part of the axis of evil. I understand cursors, triggers and U/D functions are performance drains. But does this example fall under "dynamic SQL"?
I have a lookup table with Julian Dates. For each Julian Date, I have...
What is the most efficient route to go?
Joining a table that has 2 million records to a table that has 26 million and feeding the 26 million rolls into an OLAP model.
OR
Or having the 2 million row table join to a lookup table of about 100,000 rows and calculate on the fly the 26 million...
I am using user-defined functions in a SQL View to create additional columns. For example, I may have a product function that receives a parameter from a field and uses a case statement to pass back a product description such as "receiver". I used to have the case statements embedded directly...
Does SQL Server have a method of running procedures on one record, and then moving to the next record and to the next, etc.? The analogy is similar to old dbase/foxpro using the NEXT and EOF (end of file) commands.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.