The query runs fine and I get data. I am stuck on this one specific piece syntax-wise:
WHERE
(CASE
WHEN {?SOURCE} =1 THEN SOURCE='BRANCH' ELSE Y.SOURCE<> '' END) AND .....
I want to have the user select if they want to see 'branch data only' or 'all sources' (which would need to...
...X.LYTD_START AND
TRUNC(K1.Dec_Complete_TS) <= X.YTD_END)
THEN K0.Loan_Financed_Amt ELSE 0 END DEC_DOLLAR_AMT,
/*CASE
WHEN
TO_NUMBER(REPLACE(P.APPLICATION_STATUS_CODE,'Not classified at this level', '999')) = 6
AND (TRUNC(K1.Funding_Complete_TS) >=...
They're physically in the same location, so 'distance' shouldnt be a huge challenge.
The golden rule on B is that data is one day old. Data updates occur at night while A (production) is relatively quiet.
All transformations are using A data and writing to B2.
The issue really popped in my...
First off, let me be very clear: I am working with a new dataset and am trying to understand why something 'is' the way it IS...and our DBA team is not too keen on answering questions of this nature.
Background:
Source environment (A)
DW environment (B) - data direct from A (B1) and...
1. I cannot get my hands on the explain plan - all I have to work with is the following from the dba:
" I ran explain plans on both versions (without the sums/with the sums), and neither had any full table scans - indexes were being used for every single table reference."
2. The performance...
The DBA ran the query this am under her rights and said that the query is NOT doing a full table scan. She says theres just something wrong with my query, too much going on in it. I'm stuck. Ideas?
I am really puzzled because the first SUM being done works, but adding any additional ones makes it impossible.
I can execute the query in TOAD but cannot see the explain plan. I'm being told it is my query, not the db. GRR!!!
Any other ideas on how to get around it?
...SOURCE,
SR_RCL,
SR_RCL_GRP,
RCL_TEAM_LEAD_GRP,
COUNT(APPLICATION_NBR) AS APPS,
STORE_NAME,
REGION_NAME,
MARKET_NAME,
SUM(REQ_DAY1_IN) REQ_DAY1_IN,
/*
SUM(REQ_YTD_IN) REQ_YTD_IN, ************************ADDING ANY OF THESE SUMS AFTER THE FIRST ONE CAUSES A PROBLEM****************...
We'd like to be able to search for data elements across multiple universes at a time instead of having to open each one and do a separate search to find things.
Is this possible?
NOTE:
Of course, after posting I found a way to fix my problem and am posting it here for sharing.
The way to get rid of the hyphen at the end of the string is by manipulating the second PATINDEX, like so:
PatIndex('%[^0-9.]%'
The full statement is shown below.
Select
appnumber,
TB24...
I found the link and it's GREAT, but I have a spin for ya:
I copied and pasted it and it worked great, with one exception: when there is a hyphen at the end of the string it is not removing it.
Here is what I used for the SQL:
Select
appnumber,
TB24,
len(tb24) as lenTB24...
I'm using XI, backend is SQL and I'm using a command to get around some performance issues.
We need to have a 13 month rolling view of the $ amts and # of units side by side for each month.
I suspect in order to put the two side by side, I'm going to have to use a manual crosstab, but I'd LOVE...
You can line up the objects inside of the report to the grid, and make them all the same size (one right under another).
That will help clean the majority of the output up.
The value of the slice is 0.0 - it doesnt show on the pie, and it doesnt show in the recordset at all (checked the raw data!) but the darn legend seems to want to insist it be there.
...has 6 slices (pie chart) - but the 8 records are all in 4 of the slices, the other two slices dont appear.
BUT - all 6 show on the legend, as if it's thinking that there are records that *should* be in the 7th and 8th pie chart.
Why would a grouping show in a legend and not on a report graphic?
Sure thing.
Above that select statement is this:
/****************************Start Member Characteristics ***************************/
SELECT
DISTINCT
MemberCharacteristic
, Result
INTO
Member_Characteristics
FROM
(SELECT
'Total Number of Eligible Members' AS...
...-366, @i_dAAOD) AND
RecType.StartDate <= DATEADD(DAY, -1, @i_dAAOD)
)
AND
RecType.NDC IS NULL
) AS member_char
/****************************End Member Characteristics ***************************/
--Output the Final Tables for reporting
SELECT
--DISTINCT...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.