Profile cover photo
Profile photo
Isura Silva
About
Isura's posts

Post has attachment
Use SQL to read XML data - Example
There are a few ways to read XML data using SQL and following example demonstrate how to read a simple XML file in tabular format. 1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41 DECL...

Post has attachment
Dynamic Management Views for SSAS
Analysis Services (SSAS) Dynamic Management Views (DMV) are query structures that expose information about local server operations and server health. The query structure is an interface to schema row sets that return metadata and monitoring information abou...

Post has attachment
PowerShell - Get System information
Get PowerShell Information $Host Get Computer System Information 1
2
3
4
5 # Useful Computer System Info. Get-WmiObject -Class Win32_ComputerSystem -ComputerName . | `
SELECT PSComputerName, BootupState, Status, Domain, UserName, Manufacturer, `
Nu...

Post has attachment
MDX - Parsing a value from one dim to another
Following query pass year 2016 value from [Period] dimension to [Exchange Rate] Dim. WITH  member YearX as  NONEMPTY( [Period].[Operational Year - Semester - Quarter - Month].[Year].&[2016] , [Measures].[Targets - EdoxabanNetSalesTargets]).item(0).Propertie...

Post has attachment
Powershell, and Infile search
Find a keyword within multiple files in a folder. Cls $PATH = "D:\DSUK\Daiitchi Sankyo Activity Instance\Warehouse\Data\Staging\Veeva Activity\WE_00DA0000000Ci0mMAC_123\" $FILES = Get-ChildItem -Path $path  # -Name user.csv* Foreach ($FILE IN $FILES ) { Get...

Post has attachment
Identify and disconnect / log off remote RDP sessions
Run QWINSTA to extract the RDP session information QWINSTA /SERVER:servername If the session exists, read the username and session ID. To disconnect user      TSDISCON /SERVER:servername sessionID To log-off user / kill the session     RWINSTA /SERVER:serve...

Post has attachment
Function to Get Folder Sizes in Powershell
Following Powershell function can be used to get the sizes of given folders. Folder names hould be given within double quotes seperated by commas.    1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17   function Get-FolderSize { param ( $FolderPaths = $null ...

Post has attachment
Connect to a SFTP site using Windows Powershell
This post explains how to access  a SFTP server using Windows Powershell commands. There are many file transfer utilities which can be used for this purpose. Here, I use WinSCP  in order to access SFTP server from windows powershell. 1. WinSCP PowerShell Wr...

Post has attachment
Working with System date + SSAS + MDX
The purpose of following MDX query is to create the CompleteDataMonthFlag flag which can be used to identify the latest month with complete data. For example, if we receive data with granularity less than a month (i.e. weekly or daily), we could use this fl...

Post has attachment
Backup and Restore Multiple Databases and Cubes
SSAS Cubes 1. List all the cube names in a MS
Analysis Server instance. Open a MDX / DAX query window and
run followoing DMVquery .     SELECT * FROM
$system.dbschema_catalogs     ORDER BY [catalog_name] ASC 2. Backup multiple databases in a MS
Analysis Ser...
Wait while more posts are being loaded