Power BI Import & Direct Query - sql

I'm looking for a solution to show both the Import & Direct Query data in the same visual within PBI.
The idea is to have data within the last 30 mins provided via the direct query function and data older than 30 mins fed into the visual via direct query. If I'm completely off please do say!
Ultimately the data is coming from one SQL table but is split into two views, > 30 mins ago, <= 30 mins.
I have tried combining within Query Editor & also DAX Union, however, both the times it appears to convert and import the table, then only refreshing the data every 30 mins. Unfortunately, the dataset is rather large, and live visibility is the ultimate goal.

Related

Oracle SQL Plus - Query to fetch data in a specific point in time

I have a situation where I have to pull data from Oracle database at different point in time during a day but there is a condition with this.
For Example, after running the query in the morning at 11 AM, the query fetched 2 records.
When I re-run the same query at 2 PM, the query should return the records excluding the ones which it had fetched in the morning 11 AM execution.
I am playing around with createdinfo.time and timestamps but I am not able to get the results in a single query.
I don't know even if it is possible to use a single query and get the data filtered as mentioned above or I have to use 2 different queries here for 2 different time intervals.
Any suggestions are appreciated.

Filters on power query don't scale on cubes

I'm trying to import data from a SSAS Cube using PowerQuery. My problem is that when I try to filter it by year column and import it, it always gets the whole cube... In my need is like 30-40k rows from this year but it always try to get 2 milions rows and going on ~~400 rows/sec it takes quite long and ends with a timeout. Any advice on how to do it?

Select Data between current time - 15 mins and current time in SQL

I am looking to pull data between two time periods at only 15 to 30 mins apart. I want to be able to rerun the code multiple times to constantly update the data I had already pulled. I know there is a function for current system time but I am unable to use it effectively in SQL developer.
I have tried using the function CURRENT_TIMESTAMP but could not get it to work effectively.
Currently i am using the following code and just pulling over a broad time frame, but i would like to shrink that down to 15 to 30 minute intervals that could be used to continue to pull updated data.
I expect to be able to pull current data within 15 to 30 minute segments of time.

SSRS - Report doesn't loads via Report Builder, while it does via SQL

this is my first question here.
I struggled days and days trying to find a solution everywhere with no success.
Basically I have a standard stored procedure pulling out a report dataset in a few seconds (5-6 seconds).
It aggregates (GROUPING BY and SUMMING) 23000 rows.
Indeed, my final dataset comes out with 4 rows and 33 columns executing, as said, in 5-6 seconds.
Unfortunately, while trying to load it via ReportBuilder, it loads endlessly (querying SQL Server, the StoredProcedure remains stuck in a RUNNING status forever).
Everything on ReportBuilder (DB Accesses, Dataset, Parameters, Matrix....) is right configured: I was indeed able to load it until I added a few additional (4) fields.
The SQL dataset is basically something like:
PARAMETERS DECLARATION
SELECT
FIELDS
FROM
(SELECT
FIELD A
SUMS
FROM
TABLE
JOIN TABLES
WHERE
PARAMETERS MATCHING
GROUP BY A
) AS B
ORDER BY FIELD
An "external layer" SELECT was needed to make some calculations on some FIELDS, also in some cases using some PARAMETERS.
That's it.
I use to work with huge datasets, sometimes pulling out 30,000 rows with 110 fields, but if something loads via SQL it also does always via ReportBuilder: this is the very first time it behaves in this different way.
So I'm asking if there are some strange SSRS/ReportBuilder limitations I never faced in my experience.
Any help would be really really appreciated!
Thanks in advance to everyone who'll spend time :)

Business Objects (webi) stuck forever on retrieving data for specific dates

I am very new to BO webintelligence.
I am doing a very simple query, retrieve Sales Amount for dates between 2012 and 2013. Just for this simple query when I run it, my BO crashes or gets stuck on "please wait" window. Why is this happening? If I select like 3 or 4 days like between Jan 1st 2012 and Jan 4th 2012, it runs fine. Is there anything from my end that I am doing wrong? This is in production mode.
I also wanted to point out that I have tried limiting my data set for specific region etc.
Too many unknowns to successfully assist. I presume this is webi 3.1.x or 4.1.x and I presume that the Sales Amount is a measure and that your query includes a date which does not include a time component. If you only have these two objects in your results pane and have the region in your conditions then pulling something like [Date] and sum([Sales Amt]) should not take long to execute. As previous poster suggests, try to execute the sql in a tool like SQL*Developer or Management Studio or however the source database / OLAP is stored.
Even though you've limited the data to a "region" this may be too much data. Try selecting a smaller result set of 100 rows or changing the option for "retrieve duplicate rows" on the query panel.
If possible, post the query from your report using generic object names?