We have a web applicaiton backend database uses sql server. Now we stop using this web application. I would like to stop this sql server database. What do you usually do? I can backup this database and delete this database. Or if i want to keep this database. What should i do?
Thanks for you help.
i'm desperate! I have a application in my SQL Express and only one database for it. But right now it have 3,97gb, without log file. i'm already buying a SQL Enterprise to upgrade this, take some days, but my question is: when this size came to 4,00gb my application will be stop working ? my business stop ???
I need help, because i'm executing a shrink database file (file with 189 GBytes of size), and i need to stop before it finish. If I stop the shrink process exist any possible that data corruption occurred.
We used windows authentication and we have our domain users set up to perform certian tasks like input time on their time sheet. Then I found out thru excel you can connect to the database and select any table that you have read access on. Then you can download all of the data to an excel workbook.
See my code below... it nicely insert in database data...
but I wish: if user of program in field "txtPozicija" try insert in database same data detail like is in "Pozicija" field in database that he be stopped and informed by message: you can not insert TWO SAME data in the "Pozicija" table.
any advice here?
I AM TRY SOLVE THIS LIKE BELOW, NO ERROR BUT NOT WORK using System; using System.Data; using System.Configuration; using System.Collections; using System.Web; using System.Web.Security; using System.Web.UI; using System.Web.UI.WebControls; using System.Web.UI.WebControls.WebParts; using System.Web.UI.HtmlControls; using System.Data.SqlClient;
if (e.CurrentStepIndex == 1) { //Register user into the database not hear because wizard have one step only // SaveDataDB(); } } protected void CustomValidator1_ServerValidate(object source, ServerValidateEventArgs args) { if (ddRegija.SelectedIndex == 0) args.IsValid = false; } protected void CustomValidatorPozicija_ServerValidate(object source, ServerValidateEventArgs args) { string ConnStr = ConfigurationManager.ConnectionStrings["croestate_dbConnectionString"].ConnectionString; SqlConnection Conn = new SqlConnection(ConnStr);
try { Conn.Open();
String sqlQuery = "SELECT Pozicija FROM PozicijaObjekta WHERE Pozicija='" + txtPozicija.TemplateControl + "'"; SqlCommand cmd = new SqlCommand(sqlQuery, Conn); SqlDataReader dr = cmd.ExecuteReader(); if (dr.Read() == true) args.IsValid = false;
I am working (or trying to work) in Management Studio. I have one database that I use on my one and only machine. ( I am not using any of the default databases.) I have several queries saved as files, which I open as needed. Every time I open a file I get that VERY ANOYING Connect to Database Engine dialog box. OK, it's no big thing. I don't use Server Authentication so all I have to do is hit enter and I get connected. But why should I even have to hit enter once after I'm already connected?
I am reading a guide telling how to create a private server and it says I need to restore the database. So I go to File->Open->File->My Computer->Local Disk->Program Files->Microsoft SQL Server->MSSQL.1->MSSQL->Data->GunzDB. Then the following message comes up: "The file cannot be opened because it is being used by another process. Please close all applications that might access this file and try again."
The question is, how do I get past this? I need the answer as soon as possible, I am a newb with this program so I don't entirely know what I am doing. I have tried searching for the answer, but I cannot find anything.
We created one SA login [login name: test_db] and give the Db_owner permission for particular user db, but this test_db login able to access the all system database except model database.Here problem is I am giving the only one particular user database but that login why able to access the system database.Here how to stop the system database access…
We have 3 maintenance jobs configured in this particular DB instance:
Daily backup of system database - SubPlan1 (Check Database Integrity Task --> Rebuild Index Task-->Backup Database Task)Daily backup of user databases - Five subplans for each task : (Check DB integrity --> Rebuild Index -->Backup User Database, Backup Log -->Cleanup History)Weekly maintenance - SubPlan1 (Check Database integrity job (system+user DB)Â + rebuild index job (system+user DB) )
PROBLEM: I just noticed that the User DB Rebuild Index task has been running since the 03/04 and the Weekly maintenance plan - subplan1 since the 12/04.
Which job is "safe" to stop without impacting the database?
Hi, I'm specify the size of the interger dataypes in my code behind files; e.g. commad.Parameters.Add("@SomeID", SqlDbType.Int, 4) I know it may seem silly, but I have to ask: Will specifying ths size (i.e. 4) eventually stop the auto-icnrement of the underlying primary key SomeID in the SQL Server 2005 database? What restriction, if any, does this place if the next SomeID value is 10000, which is 5 digits? or 999999, which is 6 digits? Thank you
I use EM to handle 2 SQL servers. One I can `stop`; the other I can`t. (except I think I used to be able to do so).
When I select the `stop` I get the following message from EM:
"An error 1051 - (A stop control has bee sent to a service which other running services are dependent on) occurred while performing the service operation on the MSSQLServer service."
How do I track down what this other running service is? How do I stop SQL?
Hi out there!My publisher database holds an table with an column that is to small.The related subscriber-table I already have expanded (column fromvarchar50 -> varchar60).But I can't expand the table in the distributer-base, i get the error thatit can't be done because of replication.How can I expand my column? Have I to delete replication? If yes, how?Greetings Bjørn
I program a batch file for SQL server2000 disarstrer recovery. It just stops sqlserver service and copy data file to a flash drive, then restart service.
Could someone please tell me what I have to set at the Server side so that I will be able to STOP and START the SQL Server using Enterprise Manager and `sa` login remotely, say from the workstation.
Since yesterday the sqlserver service has been falling over, my error logs says the below?
006-04-26 11:28:41.64 spid51 Using 'xpstar.dll' version '2000.80.2039' to execute extended stored procedure 'sp_MSgetversion'. 2006-04-26 11:28:41.92 spid51 Error: 15457, Severity: 0, State: 1 2006-04-26 11:28:41.92 spid51 Configuration option 'show advanced options' changed from 1 to 1. Run the RECONFIGURE statement to install.. 2006-04-26 11:28:42.04 spid51 Using 'xplog70.dll' version '2000.80.2039' to execute extended stored procedure 'xp_msver'. 2006-04-26 14:44:08.92 spid2 SQL Server is terminating due to 'stop' request from Service Control Manager.
What do I need to do? Is is just a matter of running the reconfigure script? Yesterday night we had some monitoring installed on the server. Can anyone help?
Hello buddies , I hope you hade good day , I didn't have ... but anyway.... I installed Active Directory on my dedicated server and after that uninstall that from my server and I delete NETWORK SERVICE from my Program Files completely and again I gave full permission to it and I chaked that Microsoft SQL Server and all folder has this account permission. As i meantioned it's my dedicated server and It's damn problem for me can anybody tell me what I have to do exactly please But when I tried to start my SQL Server , I got this error , (my VIA Portocol is disable) :
2007-10-11 02:52:38.46 Server Microsoft SQL Server 2005 - 9.00.1399.06 (Intel X86) Oct 14 2005 00:33:37 Copyright (c) 1988-2005 Microsoft Corporation Enterprise Edition on Windows NT 5.2 (Build 3790: Service Pack 2) 2007-10-11 02:52:38.46 Server (c) 2005 Microsoft Corporation. 2007-10-11 02:52:38.46 Server All rights reserved. 2007-10-11 02:52:38.46 Server Server process ID is 3388. 2007-10-11 02:52:38.46 Server Logging SQL Server messages in file 'C:Program FilesMicrosoft SQL ServerMSSQL.1MSSQLLOGERRORLOG'. 2007-10-11 02:52:38.46 Server This instance of SQL Server last reported using a process ID of 216 at 10/9/2007 5:48:01 AM (local) 10/9/2007 2:18:01 AM (UTC). This is an informational message only; no user action is required. 2007-10-11 02:52:38.46 Server Error: 17053, Severity: 16, State: 1. 2007-10-11 02:52:38.46 Server UpdateUptimeRegKey: Operating system error 5(Access is denied.) encountered. 2007-10-11 02:52:38.46 Server Registry startup parameters: 2007-10-11 02:52:38.46 Server -d C:Program FilesMicrosoft SQL ServerMSSQL.1MSSQLDATAmaster.mdf 2007-10-11 02:52:38.46 Server -e C:Program FilesMicrosoft SQL ServerMSSQL.1MSSQLLOGERRORLOG 2007-10-11 02:52:38.46 Server -l C:Program FilesMicrosoft SQL ServerMSSQL.1MSSQLDATAmastlog.ldf 2007-10-11 02:52:38.48 Server SQL Server is starting at normal priority base (=7). This is an informational message only. No user action is required. 2007-10-11 02:52:38.48 Server Detected 1 CPUs. This is an informational message; no user action is required. 2007-10-11 02:52:38.64 Server Using dynamic lock allocation. Initial allocation of 2500 Lock blocks and 5000 Lock Owner blocks per node. This is an informational message only. No user action is required. 2007-10-11 02:52:38.67 Server Attempting to initialize Microsoft Distributed Transaction Coordinator (MS DTC). This is an informational message only. No user action is required. 2007-10-11 02:52:39.71 Server Attempting to recover in-doubt distributed transactions involving Microsoft Distributed Transaction Coordinator (MS DTC). This is an informational message only. No user action is required. 2007-10-11 02:52:39.71 Server Database Mirroring Transport is disabled in the endpoint configuration. 2007-10-11 02:52:39.73 spid5s Starting up database 'master'. 2007-10-11 02:52:39.90 spid5s CHECKDB for database 'master' finished without errors on 2007-10-09 05:27:12.937 (local time). This is an informational message only; no user action is required. 2007-10-11 02:52:39.95 spid5s SQL Trace ID 1 was started by login "sa". 2007-10-11 02:52:39.98 spid5s Starting up database 'mssqlsystemresource'. 2007-10-11 02:52:40.10 spid5s Error: 15466, Severity: 16, State: 1. 2007-10-11 02:52:40.10 spid5s An error occurred during decryption. 2007-10-11 02:52:40.15 spid5s Failed to check for new installation or a renamed server at startup. The logic for this check has failed unexpectedly. Run setup again, or fix the problematic registry key. 2007-10-11 02:52:40.17 Server Error: 17182, Severity: 16, State: 1. 2007-10-11 02:52:40.17 Server TDSSNIClient initialization failed with error 0x5, status code 0x90. 2007-10-11 02:52:40.17 Server Error: 17182, Severity: 16, State: 1. 2007-10-11 02:52:40.17 Server TDSSNIClient initialization failed with error 0x5, status code 0x1. 2007-10-11 02:52:40.17 Server Error: 17826, Severity: 18, State: 3. 2007-10-11 02:52:40.17 Server Could not start the network library because of an internal error in the network library. To determine the cause, review the errors immediately preceding this one in the error log. 2007-10-11 02:52:40.17 Server Error: 17120, Severity: 16, State: 1. 2007-10-11 02:52:40.17 Server SQL Server could not spawn FRunCM thread. Check the SQL Server error log and the Windows event logs for information about possible related problems.
Hi, This is my firs time in this forum, we are getting this error and my sql server stop responding to users, we have upgraded our server from sql 2000 to sql 2005 in jan 2008 and since jan it waz working f9 but from last month we are facing this problem, we have Windows 2003 32bit and sql 2005 on HP Proliant server with RAID. Is this a hardware problem or something wrong with sql server 2005. followin the msg from sql log SQL Server has encountered 1 occurrence(s) of I/O requests taking longer than 15 seconds to complete on file [F: empdbdata empdb.mdf] in database [tempdb] (2). The OS file handle is 0x00000A20. The offset of the latest long I/O is: 0x000000097a0000 -masroor
Hi, i've this phenomenon that my SQL SERVER 2005 SP2 Build 3042 (W2K3 STD SP2) stop responding to connections. when i make stop and start to the sql server service it's back to life. when i observer the windows event log and sql events i see those errors
from windows eventvs
AppDomain 24 (system.dbo[runtime].24) is marked for unload due to memory pressure.
AppDomain 24 (system.dbo[runtime].24) unloaded.
SQL Server failed with error code 0xc0000000 to spawn a thread to process a new login or connection. Check the SQL Server error log and the Windows event logs for information about possible related problems. [CLIENT: 10.165.2.173]
from SQL events
SQL Server failed with error code 0xc0000000 to spawn a thread to process a new login or connection. Check the SQL Server error log and the Windows event logs for information about possible related problems. [CLIENT: 10.165.2.173]
Could not connect because the maximum number of '1' dedicated administrator connections already exists. Before a new connection can be made, the existing dedicated administrator connection must be dropped, either by logging off or ending the process. [CLIENT: 127.0.0.1]
SQL Server failed with error code 0xc0000000 to spawn a thread to process a new login or connection. Check the SQL Server error log and the Windows event logs for information about possible related problems. [CLIENT: <local machine>]
I have written ETL software that runs on SQL Server. We are running it for the first time on a 4cpu (2 x dual core) machine on sql server 2005.
One of the things this software does is perform a 'select * from tablename' to validate that the tables passed to it as parameters exist. This has worked fine on previous releases and on single cpu machines because what the optimiser decides to do is to return just the first page of data and then fetch more. I guess it even works in 2005 standard edition.
However, 2005 enterprise edition allows parallelism. And what the optimiser is deciding to do with such a query is to parallelise it and fetch all rows and then give the result back to the program. So, instead of seeing a fraction of a second to return the first page of data we are seeing up to 90 seconds and the database goes and fetches 15M rows in parallel.
Obviously, what we would like to do is to somehow tell the optimiser that this set of programs should not perform any parallel queries. Or, we would like to turn parallelism off on the specific tables we are dealing with for the period of running these ETL programs....they have no need of parallel processing at the database level for virtually all the calls that are performed.
Would someone please be so kind as to advise us if we can do something like pass a parameter to ODBC to stop parallelism or if we can issue commands against specific tables to stop parallelism for a period and then turn it back on?
I'm working on a script to produce XML. There are two parts to the XML: an envelope (called "message") and a payload ("payload). Here's an example of what the result should look like:
(Note that I had to add a space between the '&' and 'lt' and 'gt' to get it to post in the forum without the forum converting them back to < and >!)You can see that SQL escaped the < and >. Also the CDATA escape sequence is missing.I want to see < instead of & lt and > instead of & gt. Also, I need the CDATA escape sequence.
I have two extended events sessions running on a server. I do have sql jobs that automatically stop the XE sessions and import the results to working tables. I see two "ALTER EVENT SESSION XXXX ON SERVER STATE = STOP" statements that are being executed for more than 2 days, the wait types are XE_SERVICES_MUTEX and PREEMPTIVE_XE_SESSIONCOMMIT. This is not the first time I see this behavior.I do not want to kill the sessions (I guess the sessions won't die anyway) neither restart the sql service
Hi I have upgraded my local to sql server 2005, but still need to access the remote instance which is still at version 2008/8.0. Enterprise Manager has been removed (by the SQL server 2005 installation) Does anyone know how I can restart older version of SQL server instance (ie 2000/8.0) using SQL server Management Studio?
I don't have admin access on the server which the sql remote instance is hosted. Can get around it by asking the sys admin guy to do it for now but would prefer to continue to be able to do it myself. SQL Server Configuration Manager can only manage SQL server 2005 versions - a nice little caveat!
Is there a way to stop/start remote services using 'net stop/start'? - without having to write code.... I'll continue to search for a solution, but if someon can point me in the right direction, I'd be most greatful.
I have a very simple query that simply does this: select * from badgetemplates where badgeid=39 , the badge template table has four fields, one of them is of type IMAGE, however the data on badge 39 IMAGE field only amounts to about 600kb, it used to run very quickly (a second or so) now it takes over a minute, i have checked this via the SQL profiler. What is strange is if I remove some of the data stored within the IMAGE field and reduce it to much smaller that 600kb it runs very quickly again. 600kb is fairly small and it used to return this very quickly as I say. Other queries are running at normal speed and the server perfomance does not seem to be reduced elsewhere, it only seems to have effected this only table but only with data over a certain size, the table itself only contains 20 or so rows. What could this be?!
Any help would be really appreciated as I have no clue.....
I have been getting this message in the event viwer and my SQL server goes down. I have to go and start the service once again. Can somebody throw some light as how to solve this problem?
I have transactional replication configured where the publisher and subscriber are on two different servers. Yesterday a database upgrade was carried out, and the DBA dropped replication by issuing sp_removedbreplication on the published database. The subscription is still set up.
I have two questions:
1 - What is the safest way to temporarily switch off replication without losing the publication or subscription? As far as I was aware (my replication knowledge isn't great), simply disabling the relevant agents would do the job.
2 - I now have the task of creating the publication again (fortunately we have a saved script). If I recreate this publication, will I be able to point the existing subscription at it?
This store procedure will get some executable queries from the select statement, the cursor will fetch each rows to execute the query and insert the queries into table_3 to mark as 'E'. Until 17:00, this store procedure will stop execute the queries and just get the queries from select statement insert into table_3 to mark as 'C'.
I don't know why the outputs in table_3 are quiet different than I think. This store procedure comes out with two exactly same queries and one marked as C and another marked as E.
CREATE PROCEDURE procedure1 AS DECLARE cursor_1 CURSOR FOR SELECT 'This is a executable query' FROM table_1 DECLARE @table_2