all groups > sql server programming > august 2006 > threads for friday august 4
Filter by Day: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
Beginner to SQL database
Posted by jyetying at 8/4/2006 11:47:33 PM
Hi all,
I wanna to learn SQL database. Is there any SQL tutorial that can be
find from internet? Can u show me the link?
Thks all.
... more >>
After Restoring Database getting this message "Cannot Modify record"
Posted by dpk.sinha NO[at]SPAM gmail.com at 8/4/2006 10:38:34 PM
Good Morning Friends
I am in real soup. I am new to SQL server 7.0 and Visual basic 6.0. I
have got one application developed by some software agency using VB 6.0
and sql server 7.0. Since last 6 years everything worked fine.
Three days back my SQLserver machine crashed because of hard disk
... more >>
Transform 2 Rows into 1
Posted by JP at 8/4/2006 9:33:29 PM
I have an Excel spreadsheet in which I imported into a Temp table. The
temp table script is:
CREATE TABLE [dbo].[Temp](
[year] [float] NULL,
[week] [float] NULL,
[teams] [nvarchar](255) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[away/home] [nvarchar](255) COLLATE SQL_Latin1_General_CP1... more >>
delete duplicate items?
Posted by Qnguyen at 8/4/2006 3:48:01 PM
Does anyone know how to view and delete identical items on table?
What is SQL command to do this. Thanks... more >>
Self-join based on datetime
Posted by stavros NO[at]SPAM mailinator.com at 8/4/2006 3:24:49 PM
I'm trying to write a self-joining query that simply returns records
from a table alongside the previous record (based on a timestamp) for
each employee. I created a small mock-up table and wrote a query that
almost works, but not quite. Here are some details:
Table:
CREATE TABLE #TMPS... more >>
migrate from SQL Server 2005 Express to SQL Server 2005 Standard
Posted by contact1981 at 8/4/2006 3:12:04 PM
I was wondering if it was easy to migrate from SQL Server 2005 Express
to SQL Server 2005 Standard? If so, do you know how I can go about
doing the migration of data? Thank you.
Sincerely,
Eldhose Cyriac
... more >>
SQL 7 and SMO
Posted by Lee at 8/4/2006 3:11:02 PM
I tried to connect to a version 7 database with SMO to do a backup and got an
error indicating that it could not perform the operation becuase of the
version. I checked the documentation and version 7 should be supported. Is
this a an undocumented "feature"
Microsoft.SqlServer.Management.Co... more >>
Returning selected rows
Posted by gv at 8/4/2006 2:20:10 PM
Hi all,
I have some test data in a table like this.
Name Address State Phone1 Phone2 Phone3
Joe 2222 tx 457-7858 876-7845 369-4125
sue 7777 tx 451-8732 984-1111 235-7458
I want to return ... more >>
Don't see what you're looking for? Search DevelopmentNow.com.
"cleaning" some data on a table
Posted by Blasting Cap at 8/4/2006 1:38:54 PM
I have to do some work on a database that from a programming issue
several years ago, there are names in a table (business names) that have
a problem with apostrophes.
What happened is that in some instances, there are 2,3 4 and 5 quotes in
the names.
Instead of it being:
Bob's Hardwa... more >>
To send message to several directions of mail
Posted by L.Barzi at 8/4/2006 1:35:25 PM
I use xpsmpt.dll works to me very well but my question is the following
one:
I use the following code to ejeutar Extended Stored Procedures of sgte
way as it indicates the page http://www.sqldev.net/xp/xpsmtp.htm
declare @rc int
exec @rc =3D master.dbo.xp_smtp_sendmail
@FROM =3D ... more >>
Insert Data
Posted by Bob at 8/4/2006 12:40:26 PM
I need to insert data from one table into multiple tables. I understand how
to insert the data by coding to insert statements. However is it possible
to do one insert statement into two tables (I do want to select the data
twice)?
Thanks
... more >>
group by
Posted by skg at 8/4/2006 12:12:05 PM
i have a table with 5 million rows. It has a binary column. I am curious
to know if i do a group by on that column, will it be faster if i have it as
varbinary rather than binary
TIA
thx
... more >>
unused variables
Posted by Bill at 8/4/2006 12:09:01 PM
I'd like to eliminate any unused variables that are used in my stored
procedures. However, since I have hundreds of stored procedures this would
be quite time-consuming doing this manually. Does someone know of a
utility/tool that does this?... more >>
outer join -- losing records from parent table question
Posted by CRT## at 8/4/2006 12:01:41 PM
I want all values from MasterTable, and the associated SubNames from the
view. If a subname is not assigned, return 'Not Assigned'.
This seems to work:
SELECT
m.Value,
ISNULL(v.SubName, 'Not Assigned')
FROM MasterTable m
LEFT JOIN v_View v
ON m.Key = v.Key
WHERE (v.N... more >>
copy two tables with new id?
Posted by jkarpago at 8/4/2006 11:45:03 AM
Hi:
I have two tables and I want to copy some rows of origin table to
destination table but these rows have to change its id to a new one.
the problem is that the program that uses the tables insert the id, so
the sql table does not insert the id automatically.
I tried with:
INSERT INTO destin... more >>
TSQL Question
Posted by Mike at 8/4/2006 11:42:11 AM
Hi,
I have char field that holds a value like '001' and I need to increment
this char (like '002'). How can I do this?
Thanks
... more >>
Create view of winning lottery numbers
Posted by sean-usenet at 8/4/2006 9:48:15 AM
Hello everyone, I hope someone can help me out with this.
I have a table the contains past winning number for multiple lottery
games. Following is the format of the table:
DrawDate,GameName,SetNum,WhichNum,WinNum
2006-07-31,2by2,0,0,26
2006-07-31,2by2,0,1,15
2006-07-31,2by2,1,0,5
2006-07... more >>
Checking unique constraint from application
Posted by gary7 at 8/4/2006 9:41:27 AM
Hi Folks,
I have a unique column contraint (Indexed, non-clustered, Not-Null, Not
PK, the column value is nvarchar type(50)) on a dataset. I am trying to
figure out how to check for the unique value before submitting update
back to database.
I want to trap the user entry if it violates the co... more >>
Checking unique constraint from application
Posted by gary7 at 8/4/2006 9:40:19 AM
Hi Folks,
I have a unique column contraint (Indexed, non-clustered, Not-Null, Not
PK, the column value is nvarchar type(50)) on a dataset. I am trying to
figure out how to check for the unique value before submitting update
back to database.
I want to trap the user entry if it violates the co... more >>
How to join a table in another SQL server
Posted by Anderson at 8/4/2006 9:38:25 AM
Hi, all
Does anyone know how to join a table in another SQL server, thanks in
advance!
-ja
... more >>
Insert with Cursor values
Posted by Jo at 8/4/2006 7:17:54 AM
Hi there:
I want to insert using a cursor.
I have a table
Services:
ServiceId ServiceName SupplierId TextType1 TextType2
Flag
44 SomeName 787878 null
asdaasdasd Null
45 OtherName 324342 asdasdasdas nulll
Null
46... more >>
DTS Package runs, Scheduled Job Fails
Posted by moongirl at 8/4/2006 7:13:08 AM
I have been searching for the solution to this all day and have found
many people who have had the same problem but I still can't get this
resolved on my system, so I am really hoping someone can help! I
created a DTS package that is very simple. It connects to the database
using sql log in deta... more >>
sp_executesql problems
Posted by paulwragg2323 NO[at]SPAM hotmail.com at 8/4/2006 7:04:24 AM
Hi
Apologies for the case of my posting below but I upper cased everything
and I don't have time to change it all. I am having problems using
sp_executesql in that the output parameter does not seem to get the
value from the SQL statement that is executed. I have changed the table
name and co... more >>
sp_databases called from code
Posted by Naria at 8/4/2006 6:26:02 AM
Hi, I basically copied and editted sp_databases to only show me dbs over a
certain size and tested it in Query Analyzer and it works fine. I wrote an
asp page (and tried it through VBScript as well) that calls the stored
procedure. I checked with Profiler and the sp is getting executed by my a... more >>
sp_OACreate Execute permission denied
Posted by Martin at 8/4/2006 5:53:01 AM
Hi,
we are using sp_OACraete in a stored procedure to create an OLE-object
instance of an ActiveX-DLL. After migrating to SQLServer2005 we receive an
"Execute permission denied on object 'sp_OACreate' database
'mssqlsystemresource' schema 'sys'"
In Books online I get the Info "Requires m... more >>
BCP output perfect one minute, corrupt the next!
Posted by Matt Smith at 8/4/2006 5:31:42 AM
Hello,
I have little experience with SQL Server, but I've written a stored procedure
that extracts basic demographic information to be imported into another system.
I'm using a batch file as a scheduled task that extracts the data via bcp. The
batch file looks similar to this:
bcp "exec R... more >>
Problem Summing When joining a Sum from another Table
Posted by Sh0t2bts at 8/4/2006 3:57:40 AM
Hi,
I am having a problem Joining Statement into my main query when summing
the results, what happens is in the original query I get a result of 2
when included in the main query in increases to 12, Eh!!
Here is the query I am joining in:-
Select Distinct UserName, Convert(Char(10),Assessme... more >>
SQLServer gets busy, users timed out, what does this Error Log mean ?
Posted by krislioe NO[at]SPAM gmail.com at 8/4/2006 3:08:44 AM
Hi Sql Gurus,
(this is related to the post :
http://groups.google.co.id/group/microsoft.public.sqlserver.programming/browse_thread/thread/cad52b42320a6b60/2fe00ae19e805da1?lnk=gst&q=xtanto&rnum=1#2fe00ae19e805da1)
Our custom application run on SQL Server 2000. On random period of time
(but q... more >>
Dynamic SQL Problem..
Posted by arijitchatterjee123 NO[at]SPAM yahoo.co.in at 8/4/2006 1:25:58 AM
Hi Group,
Let me explain my problem
============================
declare @tableName varchar(200)
set @tableName = '##TempTab'
/*
Some external dll creating this table definition.
I am just passing the tablename to the dll.
But if the dll not getting the suitable data from the
AS then its un... more >>
Dynamic WHERE clause
Posted by ricky at 8/4/2006 12:00:00 AM
Hi
Is it possible to create something like this:
SELECT ...
FROM ....
WHERE
TransMonth
(CASE
WHEN @DateType = 'UserEntered' THEN
= @UserEnteredMonth
WHEN @DateType = 'YearToDate' THEN
<= MONTH(GETDATE() )
END)
Wher... more >>
Performance issues using Parameters
Posted by Reg Besseling at 8/4/2006 12:00:00 AM
Hi all,
(DDL's etc below)
I hope someone can help with this as I have tried everything I can think of
and had no luck
I have a table with 11M rows and have created a simple report/query on it.
When I run a "simple" sql on the table I get results in sub second times,
however when using ... more >>
SQL Agent question
Posted by Blasting Cap at 8/4/2006 12:00:00 AM
I have a batch job that does some work to a table and once it's
finished, I want it to run a completely separate batch job, and then
return to the currently executing one.
The "starting" job has about 20 steps in it, and the new job has 3 steps
in it - it creates a blank excel file, builds ... more >>
text variables?
Posted by Man-wai Chang at 8/4/2006 12:00:00 AM
I can't do "declare @var text". How could I get around it?
I need to open a cursor to fetch a text from the table into memory....
--
SoftMedia Technology Co., Ltd.
Website: http://www.softmedia.hk Tel: (852)2743 4228
* TryEasy Accounting/POS/Trading/ERP solutions... more >>
|