all groups > sqlserver server > june 2007
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
Application starts before SQL is running.
Posted by Graham. at 6/30/2007 8:16:03 PM
Very basic question.
OS Windows XP pro
On bootup, an application that starts automatically in the start-up folder,
starts before SQL server is running
This only happens on slower hardware, It must be a common problem, what's
the usual solution?
--
Graham.
%Profound_observation%
... more >>
labelling a case expression for reuse in select - MS SQL 2000
Posted by metaperl at 6/30/2007 5:32:42 PM
I would like to re-use the CASE expression without having it written
twice but trying to use "feeder" in the WHERE clause fails:
SELECT
feeder = CASE WHEN rtrim(system_feeder_id) = 'CORE' THEN 'CORE' ELSE
'ODS' END,
FROM
tbl
WHERE
CASE WHEN rtrim(system_feeder_id) = 'C... more >>
Help with stored procedures
Posted by Darlene Mack at 6/30/2007 4:04:00 PM
I need to write a stored procedure that polls a database every 10 seconds to
gather data and insert it into a table in another database. It needs a
retention span of one week, then will delete the oldest data prior to
inserting the new data. I have a working SQL to gather the data but am
h... more >>
isnull in SELECT ... help needed
Posted by metaperl at 6/30/2007 4:01:33 PM
SELECT
isnull(cval, 1) cval
FROM
tbl
I dont understand what
isnull(cval, 1) cval
does exactly.
Any help is appreciated.
... more >>
SQL Index Optimization
Posted by KA Kueh at 6/30/2007 12:00:00 AM
Dear all,
Suppose that I have a table contain the following columns.
create table prodstate (productid int, stateid int, year int, salesamt
float)
I will be doing the following query
Select * from prodstate where year=2007 and stateid = 2;
My Questions is:
1) Should I have a comp... more >>
please interpret this delete with 2 from clauses
Posted by metaperl at 6/30/2007 12:00:00 AM
I pretty much think I know what this does, but I've never seen a
DELETE statement with 2 FROM clauses:
delete from #acc
from ggg d
where #acc.id=d.nbr
and d.oid='294'
I think this is the same as
DELETE FROM #acc
WHERE #acc.id IN
(SELECT nbr FROM ggg d
WHER... more >>
contains/fuzzy/substring - type of join between two tables - MS SQL 2000
Posted by metaperl at 6/29/2007 8:57:38 PM
ok, I have a table with names of countries.
I have another table with a description field.
I want to join the country_name with the description field, BUT
instead of the join being based on equality, I want it be based on
country_name appearing in the description field.
Is this possible?
... more >>
SQL 2005 security
Posted by Carlos at 6/29/2007 7:16:44 PM
Hi,
i've installed SQL Server 2005 Standard SP2 on a W.2003 Std. SP2, and I'm
worried about the security. Server authentication is "SQL SERVER mixed
mode", and windows firewall is on, but 1433 tcp port is open beacuse the
users needs to manage their databases remotely. Databases are created t... more >>
Don't see what you're looking for? Search DevelopmentNow.com.
GETUTCDATE
Posted by Gonzo at 6/29/2007 4:40:50 PM
I think my Database is refering to the wrong time somewhere. If I run
SELECT GETUTCDATE I get the wrong time if I run SELECT GETDATE this shows
the right time. It looks like it's using GETUTCDATE can I force it to use
GETDATE? The actual Windows Server is correct as well.
... more >>
Cannot send attachment using sp_send_dbmail
Posted by Smarty at 6/29/2007 4:12:04 PM
Hi,
I've been scraching my head on this for so long. We have two servers (both
running SQL 2005 64-bit Enterprise Edn SP2 on Windows 2003 Standard 64-bit),
one of the servers is able to send the attachment in the email, whereas the
other is failing with Msg 22051 error:
Msg 22051, Level ... more >>
Standard Deviation Function peculiarities (stddev)
Posted by pyrahna at 6/29/2007 3:51:13 PM
I am using MS SQL 2005 and the stddev function to some sets of
records. It appears as though the sql server only needs 2 values to
produce a STD Deviation. Obviously this value isn't of very much use
at all, but it is weird that it calculates it at all, most std dev
functions need at least thr... more >>
SQL Profile Question
Posted by Lijun Zhang at 6/29/2007 3:51:03 PM
I am trying to optimize a stored procedure. One thing confused me is that on
the SQL Profile trace, the version with more cpu, read, and write has less
duration. Usually I see duration is almost directory linked to cpu time.
Does anyone know what could cause this? Thanks.
Lijun
... more >>
when I do "select @@servername" where does it get the server name?
Posted by BillE at 6/29/2007 3:14:04 PM
When I run
select @@servername
where does the servername come from?
It isn't the master.sysservers table like I thought.
Thanks
Bill
... more >>
Users/Schemas (newbie)
Posted by James at 6/29/2007 3:09:46 PM
I have inherited a SQL Server (2005) from an outgoing DBA and while I'm
familiar with databases from a data structure/manipulation standpoint, the
permissions/security model in SQL Server 2005 has baffled me thus far. I
digress...
There's a schema called dbo and every object is prefixed as:... more >>
Understanding deadlocks
Posted by Frank Rizzo at 6/29/2007 2:50:48 PM
Hello. In Sql Server 2005, the way deadlocks are reported has changed.
I get the following info (below). What do numbers following the KEY
mean? KEY: 19:72057600982122496. I suspect that 19 is the database ID,
but I can't figure out what 72057600982122496 refers to. I am trying to
g... more >>
way to long to run query
Posted by Mike at 6/29/2007 11:53:00 AM
I have a select statement that goes against a view. When I run it on my SQL
2000 database it takes 18 seconds, but when I run the same query against the
same database in SQL 2005 it takes over 18 minutes to return the same
records. What can I look for to find out why its taken so long on my SQ... more >>
backup set will expire
Posted by Andre at 6/29/2007 11:33:20 AM
Can someone explain the option "backup set will expire" to me? I figured
this would be the option to set how many backups I want to keep. I set it
to "After 1 day", yet I have 4 days worth of backups in my backup directory.
Did I set the wrong option? I only want 1 backup.
Thanks, Andre ... more >>
SQL 2000 Database Restore question
Posted by Saral6978 at 6/29/2007 7:44:03 AM
We have one production SQL server that houses 2 databases - a production
database and a demo database. We want to take the backup of the production
database from last night and restore it into the new demo database running on
the same server. We are having some issues with not being able to ... more >>
Linked servers SQL2000 to SQL2005
Posted by Simon at 6/29/2007 7:34:00 AM
Hi. I am struggling to link a SQL2005 box to a SQL2000 box via linked server.
I have done this before and am replicating what I did then but I can`t get it
to connect. However when I connect via query analyser using the same
credentials it connects with no issues. Has anyone seen this before ?... more >>
@terminate param for log shipping stored procs
Posted by archuleta37 at 6/29/2007 7:30:00 AM
SQL BOL says that the @terminate parameter for sp_change_primary_role
defaults to 0 while it defaults to 1 in sp_change_secondary_role. In both
cases, this param "Specifies that all pending transactions be immediately
rolled back" and puts the db in single user mode while the stored proc runs.... more >>
Identity Insert
Posted by Fred Chateau at 6/29/2007 4:59:49 AM
How do I turn on IDENTITY_INSERT for a table in SQL 2005?
--
Regards,
Fred Chateau
fchateauAtComcastDotNet
... more >>
Please comment
Posted by SQL at 6/29/2007 1:18:02 AM
Dear all
My server received following information around 2 months from event viewer.
Error: 17883, Severity: 1, State: 0
The Scheduler 3 appears to be hung. SPID 0, ECID 0, UMS Context 0x00CDA950
(We have not a scheduler 3 in my sql)
After that, i disable symantec antivirus on my server, ... more >>
SQL AWE Config Advice
Posted by Derek at 6/29/2007 1:17:41 AM
Hello,
I'm hoping someone here can give me some advice on the best way to configure
my situation.
We're running SQL Ent on Win2KA with 6GB RAM. We have both /PAE and /3GB
enabled, and SQL set to a max server memory of 2GB. However, when I look at
performance counters from the SQL Buffe... more >>
SQLAgent failing
Posted by ERoss at 6/29/2007 12:00:00 AM
SQLServer 2K all packs
SQLAgent won't start - the service is using all defaults,System Account
etc (although Itried using a domain account as well - still fails)
The error it is generating is below - thanks!
[298] SQLServer Error: 229, EXECUTE permission denied on object
'sp_sqlagent_... more >>
SQL2005sp1 | No Database Mail for Job Notification
Posted by Guzun, Alex at 6/29/2007 12:00:00 AM
Hi all,
I'm running sql 2005 sp1 on 64bit server.
Enabled Database Mail in SSSAC
Configured Database mail via Wizard.
Sent a test mail (with success)
Enabled mail profile under Alert System in SQL Server Agent Properties
Restarted SQL Server Agent
Now I'm opening my new job I made. -> P... more >>
How can i check the time the Database is using?
Posted by Gonzo at 6/29/2007 12:00:00 AM
My SQL 2000 server seems to be logging data an hour early, the Windows 2003
time is correct though. What steps should I take to find out what is
happening. I'm in the UK and we have to change our clocks for day light,
but these are all set to automatically adjust clocks.
Should it be usin... more >>
move log file to diff location
Posted by mecn at 6/29/2007 12:00:00 AM
Hi,
I got this error when I move the log file to a diff location in the cluster
environment.
Any ideas and solution?
Thanks
Msg 5184, Level 16, State 2, Line 1
Cannot use file 'T:\Logs\myrpdLog.ldf' for clustered server. Only
formatted files on which the cluster resource o... more >>
Is it possible to create a custom SQL session function/variable
Posted by GMG at 6/29/2007 12:00:00 AM
To avoid having to pass this user specific ID via a parameter in the stored
procedure, is it possible to create your own function like (like
suser_sid()) or variable (like @@SPID) ?
This value would be passed from a Web Service (asp.net 2.0) in the
connection string or something and could be r... more >>
feature?
Posted by Andre at 6/28/2007 10:27:17 PM
I was setting up a new SQL 2005 sp2 (x64) box and restoring dbs. I restored
DB1, then moved on to DB2. I was restoring from a file, so I added the
file, forgot to change the db name in the dropdown, so it still said DB1,
changed the file paths, and clicked ok. So of course when I clicked ok... more >>
Need some workaround( security question)
Posted by Hassan at 6/28/2007 9:35:33 PM
We have SQL 2005.
Say our SQL servers are in Domain 'ABC' and our clients are in Domain 'XYZ'
where the domains dont trust one another.
Theres more details but in short,I want to add Windows accounts i.e.
(XYZ\User1,XYZ\User2,etc.) without being authenticated against the domain
controlle... more >>
Compare Queries
Posted by Chris at 6/28/2007 7:41:58 PM
I am creating an SP. I want to compare alternative ways of writing the query
to see which one is the most efficient. I am trying to use the execution
plan but it doesn't give an overall cost of the query so I can compare it to
the alternative query. Rather I get a break down of the various ste... more >>
sql server memory
Posted by Kristina at 6/28/2007 6:42:14 PM
I am working to see if we have memory pressure.
We are on SQL Server 2000 with compatabiity level set to 70 Windows
2000 4 gigs memory. When I run the SQL Server Target Memory and Total
Server Memory they both come up with approx 1.6 gigs. My questions
are, we set memory dynamically and expect... more >>
More logical drives VS more striped drives
Posted by Paul Cahill at 6/28/2007 4:38:15 PM
A user called ZoomZoom made the posting below on Tech Republic. As it did
not get a reply there I am interested to know what the community's opinion
is.
Some of my Raid 10's are made up of 8 drives. Would it have been better to
have created 2 Raid 10's of 4 drives and then have two data files... more >>
Corrupted view
Posted by Ferdinand Zaubzer at 6/28/2007 3:58:42 PM
Some days ago I created a view on a sqlserver database, that returns the
price and some other infos of invoice items. everything worked fine.
Now, the view didn't return the same as when I created it. The price
column of the returned record set showed the invoice date instead of the
price a... more >>
Performance of stored procedure varies
Posted by Rahul at 6/28/2007 2:37:00 PM
I have run into an issue that if I use the parameters passed into strored
procedure directly the performance is slower than when i declare local
variable and assign the values passed in the procedure to those local
variable and then use the local variables.
Why is this the case?
Rahul
... more >>
Perfomance
Posted by Rahul at 6/28/2007 2:34:21 PM
I have stored procedure that is taking longer time in production than in
Test. I narrowed the longer time being taken to the order by clause in a
subquery. The execution plans look different in the test than in production
server. The databases are identical. What could be causing this?
The ... more >>
Connecting to SQL Server 2005 over VPN Not working
Posted by chack.busedge NO[at]SPAM gmail.com at 6/28/2007 10:10:59 AM
I am having trouble connecting to SQL Server 2005 from my home via VPN
connection to my office. I have enabled remote connections on the
server. I can actually connect to my local SQL Server instance from
the Server machine while connected to the VPN but not the other way
around. I can browse... more >>
Determining High Traffic Tables
Posted by Mohit K. Gupta at 6/28/2007 8:16:00 AM
Hi Folks,
Any easy way for me to analyze the number of inserts, updates, selects
and deletes on each table in the system? When most of the work heppens via
the SP? Note I am not database owner, I can't make structure, trigger,
scripting changes. I can monitor it using SQL Profiler, or... more >>
Saving Number Values
Posted by Brett_A at 6/28/2007 6:56:28 AM
I'm using SQL Server for the first time for a web site back-end and
I'm having problems with numbers. I have a field that accepts numbers
(the data type is float). When a user submits a value like 159,000 it
causes an error. When they enter 159000 it does not. Is this normal?
Thanks.
Br... more >>
2005 Fully qualified names.
Posted by Simon at 6/28/2007 1:36:15 AM
In SQL 2005 I have a server with a username of JM. This username created and
maintains a database. When I login via query analyser I can`t run queries on
a table unless I qualify it JM.tablename. How do I alter the login to ensure
i can query just on tablename ?
Simon... more >>
Cannot connect to SQL server over network after SP2
Posted by Damir at 6/27/2007 10:32:31 PM
Hello,
I'll try my luck in this group before I re-install the whole thing.
I'm running MS SQL Server 2005 developer edition on the Windows Server
2003 Small Business Edition.
Few days ago I have updated to the SP2 via windows update.
Since then I cannot connect to the SQL server remotely ... more >>
Performance issue between SQL2000 and IBM AS/400
Posted by Dann at 6/27/2007 10:12:11 PM
We are experiencing an odd performance issue with SQL Server 2000 SP3a
and remote queries to an IBM AS/400 when they are in a store procedure
call from another stored procedure. I have included some simple
examples below. Incidentally, this problem has only recently
developed.
If I call the... more >>
Monitor Filegrowth
Posted by David at 6/27/2007 9:52:01 PM
Hi All
With SQL Server 2005 what is the best way to be alerted when autogrowth on a
file occurs?
Thanks... more >>
Can SQL Server 2005 Standard Edition be installed on machine with Intel Celeron processor ?
Posted by S.Santorowski at 6/27/2007 8:29:35 PM
Reporting on two remote location databases
Posted by shub at 6/27/2007 8:07:56 PM
We have couple of SQL databases on different SQL Servers that are at
different remote locations in two different network domains. The
requirement is to generate reports by pulling in information from both
these databases.
What is the best way to go about it?
We have been asked to consider ... more >>
Can't update default instance of SQL 2000 to SP4. Not recognized.
Posted by Jim Helfer at 6/27/2007 7:43:26 PM
I have a SQL server 2000 server with two instances running. One the
default, one named.
I tried to upgrade the server to SP4, and I was prompted to choose
which instance to upgrade. I chose the default.
SP4 refused to upgrade the default instance with this message:
"MSSQLSERVER ... more >>
Log / Audit
Posted by question_123_question NO[at]SPAM yahoo.com at 6/27/2007 4:59:21 PM
Hi All,
I want to log all activities happening in SQL server. I already know
some auditing tools do it like:
1- DB Audit
2- ApexSQL
Also I activated SQL server audit log and all of them are helpful but,
the problem is they couldn't capture table fields that users see (not
update/delete/add... more >>
adding 2 or more vitural machines for sql server.
Posted by mecn at 6/27/2007 4:52:44 PM
hi,
the virtual sql servers are sharing the same windwos RAM memory, utilize
processor(s) and Disk IO?
What's is the diff between creating virtual sql servers and adding more sql
instances in one sql server?
1. each Virtual server need sql and windows licenses. sql instanses no need
addit... more >>
add an sql 2000 instance to a production server
Posted by mecn at 6/27/2007 3:09:48 PM
Hi,
If I add an sql 2000 instance to a existing prod sql box used as a
developping sql instance.
The developers don't need to tough the production box..
Is it feasible? it will reduce the production performance?
What's the side effect?
What about creating a virtual server --- 2-3 virtual ... more >>
Read/Write statistics, per table?
Posted by Derrick at 6/27/2007 1:57:03 PM
And one other Q, is there any way to get the number of reads/writes, one
each table, for a particular time period, without profiling the db?
Thanks again!
... more >>
|