Aggregate( PeriodsToDate ( [Date].[Fiscal].[Fiscal Year] ,[Date].[Fiscal].CurrentMember )
- PeriodsToDate ( [Date].[Calendar].[Calendar Year] ,[Date].[Calendar].CurrentMember ) ,
CREATE TABLE [dbo].[OlapQueryLog] | |
( | |
[MSOLAP_Database] NVARCHAR(255) NULL, | |
[MSOLAP_Path] NVARCHAR(400) NULL, | |
[MSOLAP_User] NVARCHAR(255) NULL, | |
[Dataset] NVARCHAR(4000) NULL, | |
[StartTime] DATETIME NULL, | |
[Duration] BIGINT NULL | |
) |
$url = 'https://api.github.com/repos/simsbulkimport/simsbulkimport/releases' | |
$apiKey = '{{REMOVED}}' | |
$header = @{"Authorization"="token "+ $apiKey} | |
$content = @{tag_name="v1.0.0";target_commitish="master";name="v1.0.0";body="Description of the release";draft=$false;prerelease=$false} | ConvertTo-Json | |
$r = Invoke-WebRequest -Uri $url -Method POST -Headers $header -Body $content | |
Write-Host $r.Content | ConvertFrom-Json |
--USE [msdb] | |
--GO | |
--DECLARE @schedule_id int | |
--EXEC msdb.dbo.sp_add_jobschedule @job_id=N'd00849dd-5001-4284-bd9e-bffce3ae0b98', @name=N'One-Time', | |
-- @enabled=1, | |
-- @freq_type=1, | |
-- @freq_interval=1, | |
-- @freq_subday_type=0, | |
-- @freq_subday_interval=0, | |
-- @freq_relative_interval=0, |
$dtsFiles = Get-ChildItem "C:\GIT\BusinessIntelligence\" -Filter *.dts -Recurse | |
Foreach($dtsFile in $dtsFiles) | |
{ | |
Write-Host $dtsFile.FullName | |
$dtsContents = Get-Content $dtsFile.FullName | |
$dtsContents = $dtsContents -replace "SEQC_", "(SEQC) " | |
$dtsContents = $dtsContents -replace "SEQC - ", "(SEQC) " | |
$dtsContents = $dtsContents -replace "DFT_", "(DFT) " |
$url = "https://api.github.com" | |
$header = @{"ACCEPT"="application/json";"User-Agent"="SIMSBulkImport"} | |
$r = Invoke-WebRequest -Uri $url/repos/SIMSBulkImport/SIMSBulkImport/releases/latest -Method GET -Headers $header | |
$content = $r.Content | ConvertFrom-Json | |
Write-Host $content.name |
$projDir = "C:\Prjs\SIMSBulkImport\*" | |
$sbiFiles = Get-ChildItem -File $projDir -Recurse -Exclude *.dll, *.pdb, *.cache | |
Foreach($sbiFile in $sbiFiles) | |
{ | |
$sbiContents = Get-Content $sbiFile.FullName | Select-String "Matt40k" -quiet | |
if ($sbiContents) { | |
Write-Host $sbiFile.FullName | |
} |
# Capita installer url \ password | |
$url = [Environment]::GetEnvironmentVariable("sims_url") | |
$password = [Environment]::GetEnvironmentVariable("sims_pwd") | |
# Get SIMS Application installation directory | |
$simsAppDir = [Environment]::GetEnvironmentVariable("SIMSDOTNETDIRECTORY") | |
Write-Host 'SIMS Application Directory: '$simsAppDir | |
New-Item -ItemType Directory -Force -Path C:\TEMP | |
$tmpDir = "C:\TEMP" |
<?xml version="1.0" encoding="utf-8"?> | |
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | |
<ItemGroup> | |
<SqlCmdVariable Include="ODS"> | |
<Value>ODS</Value> | |
</SqlCmdVariable> | |
<SqlCmdVariable Include="Staging"> | |
<Value>Staging</Value> | |
</SqlCmdVariable> | |
</ItemGroup> |
Aggregate( PeriodsToDate ( [Date].[Fiscal].[Fiscal Year] ,[Date].[Fiscal].CurrentMember )