SharePoint List: pass URL param to the SQL where clause - sql-server

I have added a SQL database as external content type and created a SharePoint list based on that. I saw that while configuring it, there is an option to set a filter. I want to filter records based on the URL parameter which the list receives. I tried setting up a column_name = parameter filter, but how do I pass the query string parameter from the URL to this filter parameter?
For example, if I have 100 records for Basketball players, and the URL is list.aspx?team=pacers I want the list to load only the 10 pacers records from the SQL database. I don't want to load all the records and then filter the list using UI.
Thanks!

You should know about Data Source Filters
When you create an external content type filter, which is known as a
Data Source Filter, the filter operation occurs within the SQL Server
database. This is important when you are working with lots of data
because you can offload processing from SharePoint products to the
external database and gain performance improvements. After you create
the external list, you can use the Data Source Filter by creating a
view that specifies different filter values in the Data Source Filter
section of the List View settings page.
Read more, How to: Create external content types for SQL Server in SharePoint 2013

Related

unable to load XML data using Copy data activity

I am unable to load the XML data using copy data activity in sql server DB, but am able to achieve this with data flows using flatten hierarchy , while mapping the corresponding array is not coming properly in copy data even pipeline success also only partial data is loading in DB.
and auto creation of table is also not allowing while doing copy activity for XML file , has to create table script first and load the data ...
as we are using SHIR this activity should be done in using copy data activity.
Use the collection reference in mapping tab of copy activity to unroll by and extract the data. I repro'd this using copy activity with sample nested XML data.
img1: source dataset preview.
In mapping tab, Select Import schemas
Toggle on the Advanced editor
Give the json path of the array from which data needs to be iterated and extracted.
img:2 Mapping settings.
When pipeline is run, data is copied successfully to database.
img:3 sink data after copying.
Reference : MS document on hierarchical source to tabular sink.

How to link the Tag Items to TestCaseId in Team Foundation Server 2017?

We are trying to create a report to link the Tag Items to their TestCaseIds.
However, the tables in the TFSWarehouse are empty. How would we link these sets of data.
It was very interesting - I did a search on every field on every table in the TFS database and came to know the Tags were actually embedded in XML in the rows. This is a very unique way of placing data, as the XML rows could be readily 'read' by a browser. However, this was very difficult to SELECT and perform JOINS on data.

How to capture datasource name when using Azure Search indexer

I have a multi-tenant index in azure search and I want to populate it with several indexers, each uploading data from one specific tenant.
I want the search to be filtered by a field "tenantid". Each database that an indexer uses as a data source has the "tenantid" as it's name, but there is no function or option I found that enables adding a custom field mapping the name of the database to a field in the search results.
The naive solution to the problem is to add a field in each document in the DB containing the field "tenantid", but I would rather take this info from the database name and reduce my object size.
Any ideas? Thanks a lot.
There's currently no such field mapping function available. Please add this suggestion on Azure Search UserVoice.
To workaround, instead of adding the database name to each document, you can just include it by specifying a datasource query as follows:
SELECT c.id, c._ts, 'my_database' AS database FROM collection c WHERE c._ts >= #HighWaterMark

User Interface to analaze date of a conventional rdbms

Currently we create Jasper PDF Reports from a single simple database table for our customers. This has been achieved programmatically. It's static. If the user wishes to change the query, he/she creates a change request, which we cannot deliver before the end of the next sprint (SCRUM).
The tool/library should be straight forward (e.g. convention over configuration) and employable from within a JavaEE container. And, open source.
Is there a dynamic tool that allows or customers to create the simple queries/reports themselves without knowing SQL? Means, they should be able to see the table and then create a query from it, execute and print (we could use Jasper Reports for the last one).
E.g. Select only data from year 2014, aggregate them by customer group and select columns x,y and z.
All of these criterias and query structure may change though, thus not just the value like year 2014.
Questions:
1) Is there a tool that presents the data in some kind of SAP-cube or something similar where the user could select the structure and attributes?
2) Can that tool save template queries (queries that the user has invoked before)?
thanks
With BIRT you could use parameters in the report... for example have one report that shows the whole data set or data cube (or at least a bit of all of the fields). Then you could add JavaScript to the report (or do all of the presentation in JavaScript for that matter), that shows the parameters a user can select from. These parameter values can then either be sent to a new report or could update the existing report. Parameters can be put into database queries too.
If that was exposed in JavaScript on a web page you could save the parameter values to an array and store them in the browser or server.

SSRS Drop Down List Values

We have a report in SSRS that has drop down list parameters that are fed by a shared datasource and query.
If I use ReportViewer to view the report these work as expected.
However, I'm also using the SSRS web service to pull out the parameters and the available values. In this instance when drop downs are moved from a manually entered list to a query the available values list is empty.
I'm assuming the problem is because the web services simply gropes the RDL file and does not execute the queries attached to the parameters.
My question is, is there any way to have it do this or to get the available values?
After reading MSDN it seems the answer is to call GetReportParameters() and set ForRendering to true:
If ForRendering has a value of false, the parameter meta data returned represents the parameter data that is currently associated with the specified report. If any parameters values are based on a query and you are interested in returning the query-based parameters valid values list, you need to set ForRendering to true, In addition, for query based parameters, you need to ensure that you have passed in all of the credential information required to return the query parameters.

Resources