i need to do patching of the application servers, some of the databases are configured in availability group .as part of this need to remove the database from availability and rejoin the db after doing patching .
Loooks like I have a corrupt database. I cannot delete it because "database is used for replication" I am told in an error box . There are no items shown when trying to expand the database. Opening Query anylizer the database is not shown in the dropdown box. If I try to create a database with same name SqL says it is already there. Also the database icon is grey not yellow like the active working databases. Anyone have an Idea of how to get rid of this rogue database. This was a temp entry and no backup was made
I tried to remove AdventureWorksDB in the "Add or Remove Programs" of Contol Panel and I got the following errors: (1) AdventureWorksDB Error 1326: Error getting file security: CProgram FilesMicrosoft SQL ServerMSSQL1MSSQLGetLastError: 5. |OK| and (2) Add or Remove Programs Fatal Error during installation (after I clicked the |OK| button). Please help and tell me how I can solve this problem.
I have uninstalled the CTP version of the SQL Server express so that I can install the released version but CTP version is still listed in the add/remove program list but without the change/remove button. I have been to different sites to find information on cleaning this up and I have ran all the uninstall tool I can find but the problem still prevails. I cannot install the released version without completely getting rid of the CTP version. Please help anyone.
Hi Everyone.. I want to remove all the constraints from all the tables in a database. I'm using SQL Server 2000. will you please help me.. Thanks in advance
Hi All, How to remove case sensitity from database like table names,column names etc. If we type either select * from AUTHORS" or "select * from authors" should result the same value. Abdul
I have a table that was set up with a primary key - that i need to change. The problem is that the database is being replicated to a remote location, and will not allow me to remove or change the primary key on a published database. Due to the size of the database and bandwith limitations it is not an option to re-initialise the published database. Is there any to do this without breaking replication
i have a data base sql Server .I wrote a stored procedure or attach my database but it is attached in read only mode how can remove read-only.
this is my stored procedure.
create procedure attache as declare @trouvemdf int declare @trouveldf int if exists (select name from sysdatabases where name='Gestion_Parc')
[Code] ....
i try this EXEC sp_dboption 'Gestion_Parc', 'read only', 'FALSE' but it causes those error
Msg 5120, Level 16, State 101, Line 1 Unable to open the physical file "C: Gestion_Parc.mdf". Operating system error 5: "5 (Access is denied.)". Msg 5120, Level 16, State 101, Line 1 Unable to open the physical file "C: Gestion_Parc_log.ldf". Operating system error 5: "5 (Access is denied.)". Msg 945, Level 14, State 2, Line 1
We are using server 2012 and SQL express.I am trying to omplement a new software called Ifineo and at deployment is dumps the following error (unfortunately French):
2015-10-27 14:36:57.8983|INFO|InsideSQLAssistant.Assistant|Connecteur Sage 100 Gesttion Commerciale v20 2015-10-27 14:37:18.3024|ERROR|InsideSQLAssistant.Assistant|Error (1807): Impossible d'obtenir un verrou exclusif sur la base de données 'model'. Recommencez l'opération ultérieurement. Échec de CREATE DATABASE. Certains noms de fichiers de la liste n'ont pas pu être créés. Voir les erreurs associées.
[code]...
Now I did try to set it in sing user or multiple user and the following command to kill some parts of it:
select 'KILL ', spid from master..sysprocesses where dbid=db_id('Votre Base')
But my admin still remains connected to the DB(I have even disabled it but still the same)there seem to be to persons connected to the db the admin and my account, found that via exec sp_who
I'm attempting to alter a database by removing one of two log files. I have truncated both log files successfully and the database has no processes but I get an error stating file cannot be removed because it is not empty. Help
I have a table that is corrupted and want to remove and add a backup version of it. How can i remove this table and add it again preserving all the foregin key restraints, permissions, dependencies, etc? Simply exporting and importing does not work. I could painfully remove the table and then painfully reconnect it again, recreating all the foreign key restraints, etc, by hand; but there has to be an easier way! What is the How-to?
I am using the Database is Oracle SQL Developer, here the Requirement is like Before insert the values in Database I need to remove the Database table and insert new values.
DELETE FROM XXMBB_NOSVOS_TMP_VO_NO WHERE EFFECTIVE_DATE BETWEEN '01' || '-' || TO_CHAR(to_date(:N_Date,'DD-MM-YY'),'MON-YY') AND to_date(:N_Date,'DD-MM-YY') AND LEDGER_ID = LED and name_rdf='NOSVOS'; COMMIT; DELETE FROM XXMBB_NOSVOS_BAL_TMP_VO_NO WHERE PERIOD_NAME = TO_CHAR(add_months(to_date(:N_Date,'DD-MM-YY'),-1),'MON-YY')
I was trying to update an SSAS database on a test server and got the following error when trying to deploy from Visual Stuido. I get a similar error in SMS. I tried to delete the database before deploying but I get an error when trying to delete. I rebooted the server.
(SQL Server 2005 R2, Windows Server 2008R2.)
Error 1 File system error: The following file is corrupted: Physical file:
?D:Program FilesMicrosoft SQL ServerMSSQL.2OLAPDataHeidtman Sales Cube.0.dbDim Age.0.dim5.Dim Age.Dim Age.dstore. Logical file . Errors in the metadata manager. An error occurred when loading the Age dimension, from the file, '?D:Program FilesMicrosoft SQL ServerMSSQL.2OLAPDataHeidtman Sales Cube.0.dbDim Age.5.dim.xml'. Errors in the metadata manager. An error occurred when loading the Heidtman DW cube, from the file, '?D:Program FilesMicrosoft SQL ServerMSSQL.2OLAPDataHeidtman Sales Cube.0.dbHeidtman DW.7.cub.xml'. 0 0
I am having a hard time removing my SQL instance inside the Add/Remove program. After i select the SQL Instance name and then I tried to remove it but it won't allow me to delete it. There isn't any error message or whatsoever. Actually, when i try to log it in my SQL Management studio, that certain sql instance name is not existing according to the message box. Is there any way to remove the Sql Instance in my system?
We are running SQL server 2003 with SP3. I'm trying to shrink a data files with the emptyfile option so I can eventually remove the file using the alter database command. However, I get the following error message when I run the alter database command:
Error: the file PRADATA4 cannot be removed because it is not empty.
The file that I'm trying to remove still has 62 extents on it. I looked MS Knowledge base 254253 and 279511 on this problem but they say it is corrected by SQL server 7.0 with service pack 3. commands that I'm running are as follows:
1) USE PRA DBCC TRACEON(8901) DBCC SHRINKFILE ('PRADATA4', EMPTYFILE) DBCC TRACEOFF(8901)
2) USE PRA GO ALTERDATABASE PRA REMOVE FILE PRADATA4 GO
BEGIN TRANSACTION Copy records from live to archive END TRANSACTION with commit or rollback execute sproc to write audit log with success or fail IF transaction was committed BEGIN TRANSACTION Delete records from live the archive END TRANSACTION with commit or rollback execute sproc to write audit log with success or fail End IF
END TRANSACTION OUTERTXN with commit if both inner transactions were successful or rollback if either failed
If either inner transaction rolled back execute sproc to write audit log saying whole process is rolling back End IfMy problem is that if the outer transaction rolls back then I am losing the two audit records because they are part of the transaction scope. I want these executes to commit even if the master transaction fails.
I downloaded the AdventureWorks2012 OLTP script. When I ran it it gave me some errors. I also noticed that it tried to install into the bult-in master database, it created a lot of tables and objects. Some questions :
1) How can I remove everything that the script installed into master database? 2) Do I need to create 1st an empty database and then run the script there? 3) I am running the script from a custom path (C:DownloadsMicrosoft SQL Server 2012AdventureWorks 2012 OLTP Script.zipAdventureWorks 2012 OLTP Script) not sure if this is causing some of the errors as the script, in the beggining has a path to other folders :
:setvar SqlSamplesDatabasePath "C:Program FilesMicrosoft SQL ServerMSSQL11.MSSQLSERVERMSSQLDATA" -- NOTE: Change this path if you copied the script source to another path :setvar SqlSamplesSourceDataPath "C:Program FilesMicrosoft SQL ServerMSSQL11.MSSQLSERVERToolsSamplesAdventureWorks 2012 OLTP Script"
4) Final question, I also downloaded the AdventureWorks 2012 simple database (AdventureWorks2012_Data.mdf). Is this file the same database as the one created by the OLTP script?
Hi all, i encountered this problem.. whenever i tried to create publications it always prompt me this error msg "sql server replications does not support nicknames,such "." or "(local)". i know i need to delete the registration and register a new server with a different name.. i just want to double confirm whether deleting the registration will affect the databases or not ? :
I was trying to test mirroring and now would like to delete the mirror database but it says I need to remove database mirroring first. I deleted the endpoint and cannot figure out how to remove the mirroring. Can someone please help.
Hi all In my table one of the column consists the values like this Krishna" Rama" - - - - - I want to remove ". I started with instr to findout the occurence. Its giving the message that 'InStr' is not a recognized built-in function name.. How to solve it. Waiting for valuable replies Thank u Baba
Please help to remove (-) The EM_TERMINATION_DATE column have records with no data. I am using the following below script to format the dates. The problem is : the format with (-) between yyyy-mm-dd retrive NULL records with (-) see the output. How to fix it? Here is my ouput: EM_TERMINATION_DATE 2006-03-15 - - - - - - - -
Here is my script:
select
cast(left(EM_TERMINATION_DATE, 4) as varchar(4))
+ '-' +
Cast(right(EM_TERMINATION_DATE, 4) as varchar(2))
+ '-' +
Cast(left(Right(EM_TERMINATION_DATE,2), 2) as varchar(2))as TERM_DT
Hi, I don't need sql express, never use it and I would like to remove it. Is it possible without loosing important functionalities in VWD? Is that true that cannot compile the applications (ctrl+f5) anymore?
I had sqlcachedependancy installed. But now I cannot uninstall it? 1. I unregistered: C:WINDOWSMicrosoft.NETFrameworkv2.0.50727>aspnet_regsql.exe -E -S localhost-d DNN1 -dd 2. I remove the Dependencry.Start() from my application_start ' System.Data.SqlClient.SqlDependency.Start(ConfigurationManager.ConnectionStrings("SiteSqlServer").ConnectionString) 3. I removed the cache section from my web.config 4. I removed the outputcache statements from my aspx pages. <!--<%@ OutputCache Duration="1" VaryByParam="*" SqlDependency="CommandNotification" %>--> However, I still get the next error:
File
Error When using SqlDependency without providing an options value, SqlDependency.Start() must be called prior to execution of a command added to the SqlDependency instance. What to do? Any help or advice is appreciated. Jelle
Would someone mind helping me with formatting a string please?? I have a column DECIMAL(4,2). In a stored proc I am selecting this field and converting it to varchar so I can append certain characters to it (this is really irrelevant to my question). However, before appending the characters, I need to remove zeros after the decimal point. Examples: 3.00 should be 3 3.20 should be 3.2 3.05 should be 3.05 etc