Azure Log Analytics - expanding a property - azure-log-analytics

I'm fairly new to using log analytics and not very familiar with the KQL language yet for queries.
I'm trying to do a query that will get the objectID value out of what appears to be a multi-valued property from the query. When I do a standard search to list the results in a table one of the columns is Properties, and the objectID is within that property column.
Not sure how to go about doing this so the results just show the objectID.

It would have helped to see your initial kusto query included in the question.
Nevertheless, you can use the project operator of KQL to extract the ObjectId as:
T
| ..<the rest of your query>..
| project Properties.ObjectId
where T is the table you are trying to query.
Here are some resources for you to get started with Kusto Query Language:
Getting started with Kusto
Write queries for Azure Data Explorer
Kusto Query Language (KQL) from Scratch

Related

How to using character functions like "like" in Microsoft Azure Table Storage Query Editor?

I have a table with a lot of data that I don't need, but I have to save that, however to do my job i need only some data.
so, to limit the amount of data that my query will return I have to use a filter to not get some files like the strings .js, .css, .log etc.
I'm using the "Microsoft Azure Explorer - Azure Table Storage - Query Editor" to do this, but I don't know how to use a function like SQL function "like" to filter that strings.
follow a example of data that i don't need in my return:
lg.folha.views.demonstrativodemedias.editar.min.css
27042018_144634_536_6A2FAE_AMB..xml
is it possible to filter that files using only the query builder options?
Query Builder Options
Query builder documentation: https://learn.microsoft.com/en-us/rest/api/storageservices/Querying-Tables-and-Entities?redirectedfrom=MSDN#Anchor_2
Fro now azure table doesn't support wildcard query. You could get it from here:Filtering on String Properties.
Note that the Table service does not support wildcard queries.
So you have to use eq, ne, gt, ge, lt, le these operators.
You could use property ge 'test' and RowKey lt 'test~' to get query entities whose property starts with test.
So, the Azure Table service doesn't support the function like, so I did an application in C# to do this.
doing that I solved two problems:
1 - The like function - I created a function to exclud the worong files.
2 - the excel line limit - Excel have a limit of 1.048.576 and some of my stracts return more than this, so a did a function to split the list in N Excel's File.

How to get list of DataTables metadata used in SSAS DSV?

I was wondering if there's a simple way to extract a list of all the tables description from the Data Source View at SSAS? I've been so far been playing around with this simple DMV-query to get the cube metadata:
SELECT * FROM $system.dbschema_tables
WHERE TABLE_TYPE = 'TABLE'
Which returns me a complete list of the tables but it's completely blank at DESCRIPTION despite the fact that I written in several of the DataTables Description field. Am I perhaps using the wrong rowset?
There is a workaround for the case if you are able to do it semi-manually:
You generates XMLA script for every SSAS Cube in the SSMS
Uses following XPATH query to collect the tables/views used in DSV of the cube: /Create/ObjectDefinition/Database/Cubes/Cube/Annotations/Annotation[]/Value/dds/ddscontrol[]/layoutobject/ddsxmlobj[not(boolean(./property[#name="Virtual"]))]/property[#name="LogicalObject"]/#value
P.S you can use websites like http://xpather.com to play around with the query on your XMLA
P.P.S result is returned in following format: <SchemaName>_<TableName>

How do I query a specific range of Firebase's analytics table using Data Studio's date parameters?

I've been reading up on how to query a wildcard table in BigQuery, but Data Studio doesn't seem to recognize the _TABLE_SUFFIX keyword.
Google Data Studio on using parameters
Google BigQuery docs on querying wildcard tables
I'm trying to use the recently added date parameters for a custom query in Data Studio. The goal is to prevent the custom query from scanning all partitions to save time.
When using the following query:
SELECT
*
FROM
`project-name.analytics_196324132.events_*`
WHERE
_TABLE_SUFFIX BETWEEN DS_START_DATE AND DS_END_DATE
I receive the following error:
Unrecognized name: _TABLE_SUFFIX
I expected the suffix keyword to be recognized so that the custom query is more efficient. But I get this error message. Does Data Studio not yet support this? Or is there another way?
It could be possible that you are setting the query in the wrong place. I created a DataSource from a Custom Query and the wildcard worked. The query I tested was the following, similar to yours since _TABLE_SUFFIX is a wildcard that is available in standardSQL in BigQuery:
select
*
from
`training_project.training_dataset.table1_*`
where
_TABLE_SUFFIX BETWEEN '20190625' AND '20190626'
As per your comments you are trying to add a query in the formula field of a custom parameter, however the formula field only accepts basic math operations, functions, and branching logic.
The workaround I can see is to build a select query and use it as a Custom Query in the Data Source definition so that the query can calculate any extra fields in advance (steps 5,6 and 7 from this tutorial).

When querying MongoDB using DBeaver, what's the right syntax for filtering by date?

I recently discovered that DBeaver can connect to MongoDB. My next discovery was that DBeaver expects SQL-like queries instead of the JavaScript-like queries I use with the mongo command line client. I've been unable to find any good documentation on the syntax I should be using, so I've been learning by trial and error. I need some help filtering query results by date.
I have a collection named tasks. Each object in the collection has a startedAt attribute that holds a timestamp.
This query gives me lots of results using the command line client: db.tasks.find({startedAt:{$gt:ISODate("2017-03-03")}});
I'm guessing the syntax in DBeaver should be something like this: select * from tasks where startedAt > '2017-03-03';
But, I'm doing something wrong because I don't get any results in DBeaver unless I drop the where clause. What's the right way?

MDX Using Member_Key

I'm trying to write a query which uses order in the Pentaho Schema Workbench program.
A simple query I pulled from Saiku analysis's GUI runs without issue.
Trying to add in an order yields the message "No function matches signature '.Member_Key'"
How would I got about debugging this? All the examples I see online for ordering data use CurrentMember and Member_Key so I'm a little lost.
These are the properties:
https://msdn.microsoft.com/en-us/library/ms145528.aspx?f=255&MSPPError=-2147217396
Try MEMBER_VALUE instead of the key.
Also try without the underscore as MEMBERVALUE
I found this page online which shows how to access intrinsic properties through Mondrian MDX.
Instead of [DimTime.CalendarYearMonth].CurrentMember.MEMBER_KEY you write [DimTime.CalendarYearMonth].CurrentMember.Properties("MEMBER_KEY")