I'm trying to use a user defined alias type in a table creation, and everything works as expected, right until the moment where I rightclick on [Indexes] and click [new index] to create a new index.
Then I get this error:
TITLE: Microsoft SQL Server Management Studio
------------------------------
Cannot show requested dialog.
------------------------------
ADDITIONAL INFORMATION:
Cannot show requested dialog. (SqlMgmt)
------------------------------
Object reference not set to an instance of an object. (SqlManagerUI)
------------------------------
BUTTONS:
OK
------------------------------
I'm trying to use a udt in a table creation, and everything works as expected, right until the moment where I rightclick on [Indexes] to create a new index.
Then I get this error:
TITLE: Microsoft SQL Server Management Studio ------------------------------ Cannot show requested dialog. ------------------------------ ADDITIONAL INFORMATION: Cannot show requested dialog. (SqlMgmt) ------------------------------ Object reference not set to an instance of an object. (SqlManagerUI) ------------------------------ BUTTONS: OK ------------------------------
like I said in other posts, I'm new to sql server, worked with informix for a long time. Right now I got into an "argument" with the present "dba", the indexes for all the tables in the database are being rebuilt, he wanted to start a monthly process, I told him that he can't do processing because when an index is built the table is locked, now, since I'm new at sql server I would like to know from the experts..... can you run process in sql server against tables when:
- indexes are being created - the structure of a table is being modified - the database is being shrunk
If we had been talking about informix then I would have probably slapped him if he tried to "teach" me about how things work, I'm pretty sure its the same in SQL but I think its better to have complete assureness of what I'm talking about before the slapping starts :)
1. I am trying to create an index, which is running for a long time. Is there an option to know the progress so far or how much more time it is going to take?
2. Is there anyway to find out how much space is required to rebuild an index?
------------------------ I think, therefore I am - Rene Descartes
I could not find an SQL script, which would generate index creation DDL for a specific table/index. Query Analyzer does it, but I need to do it programmatically. Does anyone have a working script? Thank you.
I am trying to create a new full text index on some table and getting the follwing error
"The Microsoft Search service
cannot be administered under the present user account"
i have already checked that Microsoft Search service is properly installed with the server version of SQL Server and this is running under the system account
could anyone plz comeout with the solution to this problem]
I was reading this blog below about Indexed Views and needed some clarification.
When the author choose to create the unique clustered index he excluded the PER.BusinessEntityID columns and only included, (CustomerID, SalesOrderID, ProductID).
Why didn't the PER.BusinessEntityID get added?
[URL] ....
CREATE VIEW Sales.vSalesSummaryCustomerProduct WITH SCHEMABINDING AS SELECT CUST.CustomerID , SOH.SalesOrderID , SOD.ProductID , SUM(SOD.OrderQty) AS TotalOrderQty ,
I am getting an intermittent problem with executing queries on my workstation. Whenever I execute a couple of store procedures that return a large numbers of rows (200,000 to 500,000 rows) I receive an intermittent error message when running the same sp with the same parameters sometimes the procedure runs fine and returns the result, sometimes I get an error message
Error message is: Index was outside the bounds of the array.
Sometimes
Error message is: Internal connection fatal error.
Sometimes I get a datetime overflow
I also occasionally get these intermittent messages when I execute the native query that the SP wraps.
I have SSMS 2015 SP1 installed on my workstation, the servers are a range of server from 2008 R2 SP2 to 2014 SP1. It feels like a client problem as there are applications connecting to these servers and running the stored procedures without issue...
I need to find all the index and the creation date. I did cross apply of sys.objects & Sys.indexes on name column. I am getting some but the team is saying they created so many. Any other option to find Indexes and their creation date?
Can anyone suggest an appropriate strategy to create unique index's when a distributed database is used. As a bit of a background I have several SQL Server 2005 servers scattered around the country and I am trying to come up with a way to create a unique index i.e. one that hasn't been used in a particular table say Staff in any of the databases around the country.
Performance is an issue particularly as our network isn't that fantastic has anyone done something similar and achieved reasonable speeds?
is there a setting that will ebnable uniform extent allocation uponcreation of index/table by default ?if there isn't any default setting can you code it in?thanks,Doron
I have a Performance issue in ssrs report , query takes execution time 1 to 2 min. When I add the non clustered index for one of the table columns which takes only 2 sec to execute the query. But as from my environment I couldn't able to add the index due to these changes will effect for all reports. Without adding indexes which takes 2 min to run that report. My question is:
Is there any way to add the non-clustered index on the report itself like if a non clustered index exists "execute the query" else create a non clustered index and run that report with newly created index in report itself like a temp table concept. How to add this concept in this below query:Final Query without non clustered index, takes 2 min to execution time ---
with cte1 ( MovementDate, MovementTypeDesc, CDCNumber, MovementTime, LocationReportMovement, OtherLocationCode,
We are running SQL Server 2014 Enterprise Edition (64-Bit) on Windows 2012 R2 Standard (64-Bit).
1. When to create indexes, before or after data is added? Please address Clustered and Non-Clustered Indexes.
2. To move indexes to it's own filegroup, is it best to create the NON-Clustered Indexes on the separate filegroup with code similar to the example below?
CREATE NONCLUSTERED INDEX IX_Employee_OrganizationLevel_OrganizationNode ON HumanResources.Employee (OrganizationLevel, OrganizationNode) WITH (DROP_EXISTING = ON) ON TransactionsFG1; GO
I have read the following links that states that if you create the Clustered Index on a separate filegroup, it would also move the base table to that particular filegroup. (So I take it that you ONLY can move NON-CLustered Indexes to a separate filegroup.)
Placing Indexes on Filegroups:
[URL]
By default, indexes are stored in the same filegroup as the base table on which the index is created. A nonpartitioned clustered index and the base table always reside in the same filegroup. However, you can do the following:
• Create nonclustered indexes on a filegroup other than the filegroup of the base table.
Move an Existing Index to a Different Filegroup:
[URL]
Limitations and Restrictions
• If a table has a clustered index, moving the clustered index to a new filegroup moves the table to that filegroup.
• You cannot move indexes created using a UNIQUE or PRIMARY KEY constraint using Management Studio. To move these indexes use the CREATE INDEX statement with the (DROP_EXISTING=ON) option in Transact-SQL.
Hi all,I have a table called PTRANS with few columns (see create script below).I have created a view on top that this table VwTransaction (See below)I can now run this query without a problem:select * from dbo.VwTransactionwhereAssetNumber = '101001' andTransactionDate <= '7/1/2003'But when I create an index on the PTRANS table using the command below:CREATE INDEX IDX_PTRANS_CHL# ON PTRANS(CHL#)The same query that ran fine before, fails with the error:Server: Msg 242, Level 16, State 3, Line 1The conversion of a char data type to a datetime data type resulted inan out-of-range datetime value.I can run the same query by commeting out the AssetNumber clause and itworks fine. I can also run the query commenting out the TransactionDatecolumn and it works fine. But when I have both the conditions in theWHERE clause, it gives me this error. Dropping the index solves theproblem.Can anyone tell me why an index would cause a query to fail?Thanks a lot in advance,AmirCREATE TABLE [PTRANS] ([CHL#] [varchar] (100) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,[CHCENT] [numeric](2, 0) NOT NULL ,[CHYYMM] [numeric](4, 0) NOT NULL ,[CHDAY] [numeric](2, 0) NOT NULL ,[CHTC] [char] (2) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL) ON [PRIMARY]GOCREATE VIEW dbo.vwTransactionsASSELECT CONVERT(datetime, dbo.udf_AddDashes(REPLICATE('0', 2 -LEN(CHCENT)) + CONVERT(varchar, CHCENT) + REPLICATE('0', 4 -LEN(CHYYMM))+ CONVERT(varchar, CHYYMM) + REPLICATE('0', 2 -LEN(CHDAY)) + CONVERT(varchar, CHDAY)), 20) AS TransactionDate,CHL# AS AssetNumber,CHTC AS TransactionCodeFROM dbo.PTRANSWHERE (CHCENT <> 0) AND (CHTC <> 'RA')*** Sent via Developersdex http://www.developersdex.com ***Don't just participate in USENET...get rewarded for it!
please explain the differences btween this logical & phisicall operations that we can see therir graphical icons in execution plan tab in Management Studio
We have an SSAS instance where when we run the query "select * from $system.discover_traces" the creation time in the resultset shows a different time from when we actually started the trace.
for example if we have create the trace at 3.30pm it shows 7.35 pm in the Sql server management studio resultset when we run the query "select * from $system.discover_traces".
We have 2 servers when you try to change something in a transfer for sql to a text file, it crashes and kicks you out of enterprise manager. I have seen this before. MS recommends applying sp4 or MS03-031: Cumulative Security Patch for SQL Server (815495) This is on a cluster. Has anyone seen this before
When we migrated from SQL 6.5 to 7.0 our users that had DBO privileges moved fine. When we went in and added a new user and tried to give them the same priviledges as the old user, the user looks different and does not have the same priviliges. When the user tries to run the SETUSER stored procedure it tell the user that was newly setup that they do not have the rights to perform the operation. Any help with be greatly appreciated.
We are network admins at a college, with no database experience at all. We use an Altiris product which uses SQL to maintain a database. Our database is OK, but the transaction log has grown to 24 Gb and has caused a slowdown. When we try to back up the database in preparation for shrinking it to the recommended 100 Mb, the server seems to start the backup but crashes (restarts) after a few minutes. Has the situation got out of hand i.e. with files so big, is our server never going to be able to work with it? Or are we missing something obvious?
Any information on resolving the situation gratefully received, thanks in advance.
I am using the DTS wizard to import tables from an AS/400. Some of the tables in the job are quite large and Sql Server either hangs up or completely crashes. My current configuration is WIN NT, SP4.0 SQL Server 7.0 no Service pack. Any suggestions?
I've jumped over from the sister site xtremevbtalk.com to ask the question:
Has anyone ever seen an issue where when installing MSDE, during the installation the pc reboots of its own accord?
After the MDAC is installed as part of the installation the pc reboots and upon boot up, MSDE is not in the program files directory. Instead it's sitting in the C: root. This occurs for a straight MSDE install or with an Instancename install.
There does exist a Microsoft SQL Server folder in the Program Files but it is incomplete. It's missing the Binn folder. Also, there is no reference to MSDE in the Add/Remove programs tool but ther MSDE service does show up in the Services. However I cannot start these as they are pointing to the correct location.
To date, I have tried removing the instance and installation from the registry. I have turned off all AntiVirus software. I have ensured I am using an Admin user profile. I have tried a blank sa passowrd for the installation. all of this is to no avail.
I am seriously stuck with this now and I am in dire need of a resolution so if anybody has any ideas or has seen this one before, I love some help.
I can open a single connection to the database engine successfully but if I try to open another connection ('New Query' or 'query with current connection') Management Studio just goes away without any errors.
I am utilizing a remote desktop connection to the server but if I open a connection from my desktop through Management Studio I can establish multiple connections (database engine, query, etc...) with no problems. There are no errors in the sql logs, event viewer or windows log.
Has anyone seen this? Any suggestions would be appreciated.
My application uses sqldmo to retrieve the list of sql servers in thenetwork, it works fine in some machines, but it is crashing theapplication in others, no error and no exception, it shuts down theapplication. It fails in the following line:SQLDMO.NameList sqlServers = sqlApp.ListAvailableSQLServers();any ideas?thanksmusachy
I was looking to improve the performance of an ASP.NET application bycreating the an indexed view that could be used instead of some of theroot tables.What I didn't realize is that it would affect any future conenctionsto the root tables.This of course crashed the application on any type of insert, update,or delte from the root tables.Funny thing is when I removed the indexed view -- it didn't help.I tried flipping the offending options to the opposite of way theywere set on the database and the errors wouldn't go away.I ended up restoring the database from before my mess up to fix it.I was hoping that the SQL experts out there might shed some light onmy problem before I try again.
Currently we have SQL Server running on a single RAID5 array.The data and the logs are all written to this array. We don'thave huge volume of activity, but it is growing. Most activityis from our website that interacts a lot with the database.We have read that it is a good idea to separate the data filesfrom the log files, having each on separate disks (or in thecase of RAID, separate arrays). So, we are considering addinga separate SCSI hard drive, or maybe a RAID 1 system, and havesql server log to that instead.My question is, what happens if that secondary drive or arraycompletely fails. Let's say it melts. Assuming the OS doesn'tcrash (Windows 2003 Server), what will SQL Server 2000 do whenthe drive stops working and it is trying to write its datalogging to it? Will it continue to function and write alertevents? Will it shutdown? If it shuts down, how do we alter itsconfiguration to tell it to use another drive for the logs?Also, what kind of throughput would we need to be doing to seeany kind of benefit to making this change? It is easier tojustify the expense of another disk or RAID setup if it isactually going to matter. ;-)Thanks all!Thomas
I'm using SQL 2005 Reporting services on Windows 2003 server, my development machine is Windows XP Pro. Attempting to report from a Progress 10.0B database with the DataDirect 4.2 SQL92 driver.
A simple static query executes brilliantly (i.e. SELECT Col1 FROM Tab1 WHERE Col1 = 200) When I change the named parameter to an unnamed (i.e. SELECT Col1 FROM Tab1 WHERE Col1 = ?), then execute the query I'm prompted for the parameter value, I enter a valid value, then receive the error: "Attempted to read or write protected memory. this is often an indication that other memory is corrupt." Then VS crashes. obviously this is bothersome.
An ODBC trace shows the SQL statement (SELECT Col1 FROM Tab1 WHERE Col1 = ?), note: the parameter value I entered is not in the trace. Should it be?
I have created a calculated data field for one of my data set. I use it for a table in my report. But when I try to preview it, visual studio crashes and I get the following error message.
"An error occured during local report processing. An internal error occured on the report server.see the error log for more details."
I have not installd servers on my machine(only the sql tools). So I can not see error logs either.