
The dynamic lock pool does not acquire more than 60 percent of the memory allocated to the Database Engine. However, if allocating that memory would cause paging at the operating system level (for example, if another application is running on the same computer as an instance of SQL Server and using that memory), more lock space is not allocated. Generally, if more memory is required for the lock pool than is available in the Database Engine memory pool, and more computer memory is available (the max server memory threshold has not been reached), the Database Engine allocates memory dynamically to satisfy the request for locks. As the lock pool is exhausted, additional memory is acquired for the pool. When the server is started with locks set to 0, the lock manager acquires sufficient memory from the Database Engine for an initial pool of 2,500 lock structures. This option is an advanced option and should be changed only by an experienced database administrator or certified SQL Server professional. Avoid using this feature in new development work, and plan to modify applications that currently use this feature.įollow Up: After you configure the locks option IF (EVENTDATA().This feature will be removed in a future version of Microsoft SQL Server. CREATE TRIGGER LimitUseDesignerForView ON DATABASE You can limit your users by using limitation on DDL_EXTENDED_PROPERTY_EVENTS DDL trigger. I suggest that you don't limit your user by APP_NAME() because user maybe use tools application in order to use view designer such as EMS and etc. You can also get list of sql server views that use designer by following query: SELECT DISTINCT OBJECT_NAME(ep.major_id) RAISERROR ('Use query in order to alter your view',16, 1) You can crate DDL Trigger for ALTER_VIEW in order to check APP_Name() and limit your user to use query instead of designer. The application name of sql server when you use query for alter your view, is Microsoft SQL Server Management Studio - Query and application name of sql server when you use designer for alter your view is Microsoft SQL Server Management Studio. The only other option I can think of would be to search the Connect site for bugs that prevent the designer from opening (I vaguely remember one with nested comment syntax) but even if you find one you are at risk that they will be fixed in a future service pack. The AppName used by management studio is configurable anyway so this could also be circumvented. RAISERROR ('Please don''t use the designer to ALTER views',16, 1)īut this will not fire until they attempt to save and your co workers might be highly annoyed. IF APP_NAME() = 'Microsoft SQL Server Management Studio' The default program_name strings I see for the designer vs a query window are "Microsoft SQL Server Management Studio" and "Microsoft SQL Server Management Studio - Query" so you could use.


Also the above has the risk of changing the execution plan in a negative way too.Īnother approach might be to create a DDL trigger. SQL text cannot be represented in the grid pane and diagram pane.Īnd these panes are blank but the SQL pane still appears and contains the reformatted SQL for editing. No there isn't a robust way of doing this.Īdding constructs that the designer does not support but that do not change the semantics might be one possibility WHERE (1 = (SELECT ROW_NUMBER() OVER (ORDER BY it doesn't really work.
