all groups > sql server new users > january 2006 > threads for january 8 - 14, 2006
Filter by week: 1 2 3 4 5
Using IF on a SQL view
Posted by Angel at 1/14/2006 9:35:17 PM
Help please!
I am trying to write a sql statement that will output a "1" in the column
if the country the item is sold to is USA, otherwise to place a "0" in the
column. This would mean that the sale was international and we need to sort
internationals first, but I can't figure out how to do... more >>
Database comes up as read only
Posted by MikeBach at 1/14/2006 4:51:27 PM
I downloaded the Northwind sample database from Microsoft. I attached the DB
through Enterprise manager. It comes up as Read Only, how can I change this
so I can manipulate. Second question, are there any practice lessons
regarding the sample database I can download to practice with ?
Using... more >>
Newbie needs help with trigger
Posted by -ActiveX- at 1/14/2006 11:59:06 AM
I am trying to prevent the deletion of records in the
w_schActivityPatients table if there is no PrintDate in the
coresponding parent table (w_schActivityCalendar)
The following deletes everything from the w_schActivityPatients table
regardless if there is a printdate in the w_schActivityCalen... more >>
Search string in parameter is NULL, how to handle?
Posted by Daves at 1/13/2006 11:25:05 PM
a select query in my stored proc:
SELECT ID, Name FROM Users WHERE Name LIKE '%' + @Name + '%'
What if the @Name parameter defaults to NULL (that is, no search string was
passed to SP)?
... more >>
Query for 1 row before and 1 row after
Posted by Christoph at 1/13/2006 12:39:57 PM
Let's say I have a table that looks like this:
id deductible rate
1 500 1
2 1000 1.5
3 1500 2
4 2000 2.5
5 2500 3
It's a simple enough query fo... more >>
What changes would you like to see in the setup of SQL Express?
Posted by Rob Walters [MSFT] at 1/12/2006 12:15:04 PM
Hi, we are in the process of planning the future version of SQL Server
Express and would like to solicit feedback from the community on the setup
and installation experience of SQL Server Express edition. So if you have a
few moments, please tell us what you think -- What do you like/dislike ... more >>
connection to sql express 2005
Posted by Sam at 1/12/2006 9:43:37 AM
after installing sql express 2005 + visual studio
users fail to connect db on server through odbc
what can be the problem?
thanks
... more >>
How to set dynamic column name or Change column name dynamicly
Posted by M at 1/10/2006 4:34:12 PM
How to Change column name dynamically
Declare @Column_name Varchar(30)
Set @Column_name = (Select Name from Customer where ...)
Create table #temp
(
Name Varchar(30)
Date datetime
Sales Money
)
EXEC sp_rename '#temp.Name', @Column_name, 'COLUMN'
It fails
... more >>
Don't see what you're looking for? Search DevelopmentNow.com.
Can I use True and False in SQL for BIT fields?
Posted by Doug Stephens at 1/10/2006 9:26:43 AM
I know BIT fields want to have a 1 or 0, as in SELECT * FROM ABC WHERE
FLAG=1. However, I am converting a large application and many Crystal
reports from Access to SQL. Both code and reports contain lots of
statements such as SELECT * FROM ABC WHERE FLAG=TRUE, which works in
Access.
Is there ... more >>
Log Shipping - Error
Posted by Gabe Matteson at 1/9/2006 3:26:37 PM
I have two servers, the sql agent service on both servers are running under
a domain account - rrg-sqlagent which is an administrator on both servers.
The initialization of the database works but 15 minutes later when the the
log shipping starts to occur i recieve the following errors. does an... more >>
vs MySQL
Posted by John at 1/9/2006 12:02:52 PM
Hi
How is SQL Server 2000 better than MySQL? I need to convince my boss as we
are contemplating doing a website with either SQL Server 2000 or MySQL as
backend.
Thanks
Regards
... more >>
Delete Duplicates
Posted by Aleks at 1/9/2006 11:37:10 AM
Hi,
I have two tables. One has the names of all my clients, it has the following
fields ("Clients" table)
1. ID - Unique
2. OldID - May be duplicate
3. Name
The other table has the invoices I have for that client, and I link the
tables by using the ID, so the invoices table has one in... more >>
Copying (or moving) data from one table into an existing like table
Posted by Jim in Arizona at 1/9/2006 10:28:57 AM
I have a small DB with several tables that are identical:
ID SMALLINT IDENTITY,
title VARCHAR(255),
url VARCHAR(400),
postedby VARCHAR(60),
postedwhen SMALLDATETIME,
I need to move data from one table into another table.
I don't know an easy way of doing this with SQL. Since the ID colu... more >>
Why doubles?
Posted by _adrian at 1/8/2006 4:21:57 PM
Alright.. I'm using this statement below.. that for some reason, is giving
me 2 copies of each record.. thoughts on why? I can't see it!
SELECT TOP 100 PERCENT dbo.Chapters.chap_name AS chap_name,
dbo.Quartets.[Year], dbo.Quartets.Quartet, dbo.Quartets.Chapter
FROM dbo.Quartets L... more >>
need SQL help
Posted by _adrian at 1/8/2006 3:56:51 PM
OK.. I"ve pretty much got the basics I need for most of my SQL needs..
however.. I need to do the following..
I've got two columns.. one we'll call colors.. and one we'll call numbers...
What I need to do, is to take the following values:
Colors Numbers
------ ----------
Red ... more >>
|