Viewing 15 posts - 15,241 through 15,255 (of 15,381 total)
That sounds like it is a bit odd. You are creating duplicate data of all three tables??? Is this a one time thing or something you need to do regularly?
August 13, 2010 at 7:21 am
Are the destination tables new ones? If they are my suggestion would work without the need for temp tables at all. If the destination tables already have data then it...
August 13, 2010 at 7:14 am
I meant that you could turn identity_insert on for all 3 of your tables, then you just insert your data and turn identity_insert back off. That would keep all the...
August 13, 2010 at 7:10 am
Assuming you are trying to copy all the data from one set of tables to another, just create your new tables and then turn on identity_insert for each new table....
August 12, 2010 at 12:57 pm
You should be able to create an update trigger that could run a sql job when your column is updated to "I". The sql job would execute a dts package....
August 12, 2010 at 12:51 pm
If all the users only have access to views why not just make the db readonly?
August 12, 2010 at 8:05 am
You can reference them by ordinal position also. rs(0) for the first column etc.
August 12, 2010 at 7:00 am
Have you tried the SQL search tool from RedGate? I am not sure that it will find it but I have really good luck finding a lot of otherwise obscure...
August 10, 2010 at 11:41 am
Oh yeah :hehe:.
You need to add an isnull to the order like (although you should count a field from order detail). That should just about get you there.
count(isnull(order.orderdate, 0))...
August 10, 2010 at 11:27 am
try this
select j.jobcode, j.jobdesc, count(order.orderdate) as NumSold
from jobcode j
left join am on am.jobcode = j.jobcode
left join order on order.acctcode = am.acctcode
where [whatever stuff here]
group by j.jobcode, j.jobdesc
August 10, 2010 at 11:01 am
I think you would have a lot better luck if you opened the csv as a datasource instead of a filestream. Then you can read the rows directly into an...
August 10, 2010 at 10:51 am
not really sure what you are trying to get but here is a guess....
SELECT
am.name,
...
August 10, 2010 at 10:35 am
You could do something like select sum(datalength([binarycolumnhere])).
That would get you a reasonable close estimate. It would not take into account index space usage but should be pretty close. Maybe somebody...
August 10, 2010 at 10:15 am
right click the table in SSMS and view properties. select General on the left, in the right panel under the storage section it will show you the data space and...
August 10, 2010 at 8:36 am
sum(myHoursCalculationHere)
looks like 7200/60/60 is one of the values you have? So in this case you would be looking for 1. Keep in mind that unless you do something like 7200/60/60.0...
August 9, 2010 at 9:05 am
Viewing 15 posts - 15,241 through 15,255 (of 15,381 total)