Monday 20 July 2015

Who is in SQL?

Who is in SQL? 

SQL Server Management Studio >> New Query >> exec sp_who2

 

This will list the users logged into specific databases, especially useful if you need to force kill the sessions. 

New Query >> Kill 'spid' 

eg. Kill 11
 Andy

Turn On Trace Flag 4616 Dynamics NAV

Turn On Trace Flag 4616 Dynamics NAV

SQL Server Mangement Studio >> New Query >> master

DBCC TRACEON(4616,-1) 

Andy

Inventory Valuation - Slow Report FIX (NAV 2009/R2)

Inventory Valuation - Slow Report FIX


Microsoft released a hotfix for the Inventory Valuation report 1001 for NAV 2009 / R2 to decrease the length of time the report takes to run. This is especially important for big databases. 

Hope this helps! 

Download


Andy 

Wednesday 17 June 2015

Departments Menu Glitch - NAV 2009 / R2

Departments Menu Glitch - Assign Users 

In Navision 2009 / R2 (Classic) you are able to hide departments from your users, however somtimes this can glitch. I've witnessed this issue a few times whereby the you disable / enable a department for a user but nothing happens.

The quick fix is to delete the user completely from NAV.

Tools >> Security >> Windows/Database Logins >> Copy all the permissions >> Delete the User >> Synchronize >> Re-Add the user >> Paste the logins back in >> Synchronize.

As to why this happens, I have no idea. I think the 'User Menu Level' gets corrupted.


 

 

Delete All Users from NAV 2015

Delete All Users from NAV 2015 - SQL

Note: This same script can be used on NAV 2013/NAV 2013 R2
Sometimes we will need to delete all of our users from a NAV 2015 database as we may inadvertantly lock ourselves out or experiences glitches with user accounts. A quick way to delete all users from NAV 2015 is to do the following: 
1. Open SQL Server Management Studio. 
2. New Query (select the database we want to remove all the users from). 
3. Use the query below >> Hit Execute

delete
from
[dbo].[User]
delete
from
[dbo].[Access Control]
delete
from
[dbo].[User Property]

delete
from
[dbo].[Page Data Personalization]
delete from
[dbo].[User Default Style Sheet]
delete from
[dbo].[User Metadata]
delete from
[dbo].[User Personalization]

Monday 8 June 2015

NAS Manual Install


NAS Service Install

(NAV Application Server)

"C:\Program Files (x86)\Microsoft Dynamics NAV\60\Application Server\nassql.exe" appservername="Application Server", NETTYPE=TCP, servername="SQL-SERVER", database="Cronus 2009 R2", company="CRONUS Ltd.", nettype=tcp, startupparameter="JOBQUEUE", objectcache=40000, installasservice

The configuration for this can be ammended in the registry if you dont have the MMC snap in installed. 

HKEY_LOCAL_MACHINE/SYSTEM/CurrentConotrolSet/Services