Viewing 15 posts - 3,331 through 3,345 (of 7,609 total)
Create a new table on database A to hold database B's data: host name, OS info, etc. For the sake of argument, let's say the new table is named "ip_details". ...
June 11, 2018 at 12:33 pm
June 11, 2018 at 8:28 am
Are you licensed for all the CPUs? At one time, the affinity mask was used to run on machine that had more processors than you were licensed for, by cancelling...
June 8, 2018 at 2:23 pm
Not easily, no. With the current query,for example, we have no way of knowing which row is the last pax.
Btw, you should truncate not round, or you will...
June 7, 2018 at 1:46 pm
This is relatively straightforward (the difference between start time and end time, for selected hours only), but you'll need to post directly usable data. That is, CREATE TABLE and INSERT...
June 7, 2018 at 11:42 am
The "standard" way to do that is to make sure the key doesn't already exist in the table to be insert to. If you need to, delete dups from the...
June 7, 2018 at 11:32 am
The table's already clustered by [TRANSACTION_TIME]. That's fantastic, it'll make your job so much easier. We'll just want to increase the fill factor from 90 to 99 for the historical...
June 6, 2018 at 3:02 pm
Need to see the definitions of indexes too, especially for the clustered index (or pk, as that will be the clustering key unless you explicitly say it isn't).
You...
June 6, 2018 at 12:07 pm
Is(are) there any index(es) at all on this table? If not, you'll definitely want to "create a brand new table to insert into while the old table data is being...
June 6, 2018 at 11:32 am
What you've stated and shown is contradictory. Is transaction_time a "string", as you stated, or a datetime, as your code shows?
Assuming it's a datetime, you don't really need...
June 6, 2018 at 10:33 am
Below is a re-coded version of the stored proc. It does the UPDATE of IsUsed inline, to reduce (eliminate?) chances of two near-same-time execs of it getting the same NextID...
June 5, 2018 at 2:05 pm
1) How is clustered? By ( Col, Col1) or something else?
2) How is normally searched? By ( Col, Col1 ) or by something else?
3)...
June 4, 2018 at 3:32 pm
INSERT INTO dbo.exportLogTable
SELECT
...list_of_all_columns_in_table...
FROM (
SELECT *, ROW_NUMBER() OVER(PARTITION BY tableID ORDER BY tableID) AS row_num
FROM dbo.exportLogTable2
) AS elt2
June 4, 2018 at 12:32 pm
SELECT * INTO Title2 FROM Title;
Not a good idea. A direct SELECT ... INTO new_table can cause system table locking and can cause concurrence issues. You should...
June 4, 2018 at 12:26 pm
Viewing 15 posts - 3,331 through 3,345 (of 7,609 total)