Viewing 15 posts - 271 through 285 (of 291 total)
I don't think you gave me enough information to solve the problem. I'm giving it a stab but making a lot of assumptions that probably are not correct.
Assumptions:
1. No duplicate...
May 9, 2007 at 9:00 am
I don't know if the will help, but after looking at your design and query I gave it up as "not worth the effort". The design is not suited to...
May 9, 2007 at 7:55 am
Step back from the problem and look at the result of the "JOIN" clause. A left join will retrieve all rows from the tblSysSp table, and for each row it...
May 8, 2007 at 10:23 am
This is a pretty vague request. Do you simply want to over write the current production database? If so then a simple restore of a backup:
--Backup the development database
backup database...
May 8, 2007 at 9:41 am
/* I always work best with examples, so I've recreated your table (sort of), populated it with some test
data and then provided a SQL Script to report it the...
May 8, 2007 at 6:40 am
While I agree with some of the other posts that nobody should take your test for you I'll assume you have a legitimate interested in learning the answers to these...
May 7, 2007 at 9:32 am
First I don't think you really need the "If Exists" portion of the SQL statement, at least not in the context you are using it. Second change the cmdSP1.ExecuteReader to...
May 7, 2007 at 8:17 am
There are several ways to perform the query, the simplist would probably be:
SELECT post.post_id, aspnet_Users.UserName, post.post_name,
post.post_date, post.post_views, (select count(comment.comment) from comment where comment.post_id = post.post_id) as Total_Comments
FROM post...
May 7, 2007 at 7:51 am
Unless I've missed something in your question the query is straight forward:
Select * from [tablename]
That will return the data from the table, listed row after row with the column names...
May 7, 2007 at 7:43 am
-- Quick example of dropping/creating a column in same location.
-- Basically we are going to move the data to a temp table, drop and recreate the existing table
-- and copy...
May 7, 2007 at 7:36 am
Well, I recommend a backup just before you perform the change. That is always the best policy. If you just want to keep the data around for a little while...
April 27, 2007 at 12:59 pm
--Same principal as the last example
update yourTable_
set col2_ = replace(col1_,'\','@') + '.com'
--You can get more specific
update yourTable_
set col2_ = replace(col1_,'DOMAIN\','DOMAIN@') + '.com'
--Or just those records where col1 begins...
April 27, 2007 at 6:36 am
--Here is a method to eliminate dups:
--First select all the columns of the existing table into a temp table (make sure you have enough disk space for this)
--adding a new...
April 26, 2007 at 2:53 pm
Here is how you can use the REPLACE command:
UPDATE [tablename]
SET [columnname] = Replace([columnname],'existing string value','new string value')
obviously you can use the WHERE clause to limit what data...
April 26, 2007 at 1:05 pm
Make sure your package is not referencing the "loaddate" column in it's update/insert statement. Exclude that column and it should work as expected.
April 26, 2007 at 12:41 pm
Viewing 15 posts - 271 through 285 (of 291 total)