Latest

  • Experiments of 2021-10
    Experiments: DAX, Pwsh, VS Code
  • Run DAX in Your Browser: SQL-BI.com has a DAX Web App | What’s New
    Dax Web App ( From sqlbi.com )
  • Word Wrapping Text in Power Query
    Word wrapping text using List.Accumulate and Occurrence.Last
  • Power Query Custom Functions – Cheat Sheet
    Declaring optional parameters in custom functions, combine multiple Web.Contents queries, without refresh errors. Using Html.Table with custom CSS Selectors
  • Big List of Cheat sheets and References
    Web Technologies, Specs, Programming, and Configuration
  • Creating a Discord Webhook in a few lines of PowerShell
    Discord Web Hooks are easier than you’d think. It uses a regular `HTTP` web request . Step1: Creating your webhook url Go to: Server Settings -> Integrations -> View WebhooksThen click create webhook. Step2: Invoke-RestMethod Success! Docs There are optional webhook arguments to customize the output: https://discord.com/developers/docs/resources/webhook#execute-webhook Comparison with curl I tried making curl easier […]
  • Improving ‘diff’ readability on Windows | Tip
    The output of diff -q path1 path2 is pretty verbose. This function Converts full paths to relative Differences are red. Missing ‘diff’ ? If git is installed, you may need to update your %PATH% environment variable. Stand-Alone function Compare-Directory This is an isolated version of <a href="https://github.com/ninmonkey/Ninmonkey.Console">Ninmonkey.Console: Compare-Directory</a> . I removed all dependencies except coloring […]
  • Easy way to cache results on the Command Line | Power Shell Tip
    Sometimes you’ll need to run a command with the same input with different logic. This can be a hassle using a slow command like Get-ADUser or Get-ChildItem on a lot of files like ~ (Home) with -Depth / -Recurse PowerShell 7.0+ Powershell 7 added the Ternary Operator, and several operators for handling $null values. All […]
  • Web.Contents: Using Dynamic and Duplicate key names in a Query
    Power BI Discord asked the question:> How do you use duplicate keys, and dynamic urls with <a href="https://docs.microsoft.com/en-us/powerquery-m/web-contents">Web.Contents</a> ? (They were using a web API that required duplicate keys) After I wrote this, Chris Webb found an easier solution. Requirements You can’t use a regular record because keys must be distinct. Query = [ Key1 […]
  • Preserving Types When using “Add Custom Column” in Power Query
    Why doesn’t the original [Num] * 2 work? Powerquery does not know what type will be returned by your function. That’s because each is by definition a function that returns type any See More see the each expression in the Lexical Grammar Docs on Power Query each functions
  • PowerShell : Prefixing lines with the Pipe operator |
    It’s cleaner to read, and makes it easier to insert, delete, or toggle comments on the console.
  • Reusable Calculated Properties in PowerShell
    The function Label is from the module: github.com/Ninmonkey.Console
  • Which Power Query Functions exist in Power BI but not Excel?
    The final number of missing identifiers* Generating the list using #shared To get a list of all identifiers (functions, variables, constants) I use the variable named #shared . Create a new blank query, then paste this I copy using Copy Entire List, then storing the results into a PowerShell variable. I Repeat the same with […]
  • Generating Random Numbers in SQL
    To generate random integers from min to max, including min and max Example: To create a random integer between 5 and 10
  • Learning PowerShell
    Getting started with PowerShell Main Language Keywords and Grammar including control flow about Operators Flow Control about_ScriptBlocks (anonymous functions) Grammar switch statements functions Important Topics, Language quirks For( ;; ) vs ForEach vs ForEach-Object about_ForEach ( control loop) about_For ( control loop) ForEach-Object ( Note: this is a command, not a control loop ) It’s […]
  • Using Case-Sensitive Regular expressions in PowerShell – Tips
    Searching for Parameters using case-insensitive regular expressions
  • Tip: Controlling a Column’s “Summarize By” Type in Power BI
    The Model view allows you to set a global default “Summarize By” type for every column.You still have the ability to override the aggregation type per-visual in Report view
  • Searching Constants Defined in Power Query
    Searching Power Query Language Functions and Constants Functions Constants
  • Power BI Updates – 2020-08-17
    Guy In a Cube: July roundup and PBI Desktop patch notes
  • Resources to learn Power Query
    High quality Tutorials, tools, and blog posts for Power Query