Einträge von AZConAdmin

Datenreihenfolge über Zeilen hinweg prüfen

Anforderung: Prüfen, ob ein Wert (VK) einer geringeren Auflage teurer ist als einer höheren Auflage. [‘X 01 Test’:{‘v3’}]=N:DIMIX (‘D Auflage P010’,!D Auflage P010); [‘X 01 Test’:{‘v4’}]=N:DB (‘x 01 Test’,ATTRS(‘D Auflage P010′,!D Auflage P010 ,’vor’) , !D Format P010, ‘VK’ ); [‘X 01 Test’:{‘v6’}]=N:IF(DB (‘x 01 Test’, !D Auflage P010, !D Format P010, ‘v4’ )<>0, DB […]

SSIS DB Abfrage Laufzeit

SELECT TOP 10 [statistics_id]       ,[execution_id]       ,[executable_id]       ,[execution_path]       ,[start_time]       ,[end_time]       ,[execution_duration]  ,[execution_duration]/60000 As Delta       ,[execution_result]       ,[execution_value]   FROM [SSISDB].[catalog].[executable_statistics]     where year(start_time) = 2023    — and execution_path like ‘%orderitem%’  and […]

TM1 Drillthrough ODBC

Umsetzung nur im Architect:    1. Drillprozess erstellen mit SQL Statement:  z.B. SELECT          [KostenstellenNr]  ,[KostenartenNr]  ,[CCMonat] AS Periode       ,[LinkedKreditorNr] AS KreditorNr       ,[BelegNr]       ,[Belegart]       ,[Belegdatum]       ,[Buchungstext1]        ,[Buchungstext2]          ,[KredString]     […]

Abfrage der SSID DB im SQL Server

SELECT TOP 10 [statistics_id]         ,[execution_id]         ,[executable_id]         ,[execution_path]         ,[start_time]         ,[end_time]         ,[execution_duration]  ,[execution_duration]/60000 As Delta         ,[execution_result]         ,[execution_value]     FROM [SSISDB].[catalog].[executable_statistics]     where year(start_time) […]

ID oder Nr aus String ausschneiden

SUBSTRING(referenceText, PATINDEX(‘%[0-9]%’, referenceText), PATINDEX(‘%[0-9][^0-9]%’, referenceText + ‘t’) – PATINDEX(‘%[0-9]%’,                      referenceText) + 1) AS Kostenstelle,

delete old files ab älter x Tage

forfiles -p “C:ExporteCognosDonBoscoMission” -s -m *.pdf -d -30 -c “cmd /c del @PATH” forfiles -p “C:ExporteCognosDonBoscoMission” -s -m *.xml -d -30 -c “cmd /c del @PATH” forfiles -p “C:ExporteCognosDonBoscoMission” -s -m *.mht -d -30 -c “cmd /c del @PATH”

delete und copy file

del “D:DBV DatenAZNTransfer*.txt” xcopy  \Dbm-svssvsImportAZNKunden_Verlag_*.txt   “D:DBV DatenAZNTransfer” xcopy  \Dbm-svssvsImportAZNTest.txt   “D:DBV DatenAZNTransfer”

Defragmentierung von Indexen

SELECT  –DB_ID(‘Live_Staging’) DB_NAME(database_id) ,* –SELECT stats.index_id as id, name, avg_fragmentation_in_percent FROM sys.dm_db_index_physical_stats (DB_ID(N’Live_DWH ‘), NULL, NULL, NULL, NULL) AS stats     JOIN sys.indexes AS indx ON stats.object_id = indx.object_id       AND stats.index_id = indx.index_id AND name IS NOT NULL where database_id =6   –where name = ‘idx_customerCredit_customer_endamount’     –where name = […]