EIS dataloads on ASO - missing data during dataloads
We build are building an ASO application with duplicate member names. The member load works fine, but when I load the data, I am missing amounts so some measures are out of balance. In trouble shooting the data, I found if I load just the Agent (level 0) amounts balanced, so I changed the filters to:
1. loaded the Branch for the agent (next level in Heirarchy)- number still balanced
2. loaded the Mgmt Office for the agent (next level in Heirarchy)- number still balanced
3. loaded the Region for the agent (next level in Heirarchy)- number still balanced
But when I load all, I am out of balance. So I created 8 filters in EIS, and loaded the data in 8 steps. All the measures balance when I load in in 8 parts. Has anyone run into this issue?
Running on Windows 2003 Server 16 Gb RAM, 4 processors.
Stats from:
Essbase Input-level data size 10016
Dimension 13
Attrib Dim 3
Measures 32
Largest Dimension 16333 members 12842 stored
All other Dimension <50 members <50 stored
(4 Dim <10 members, 4 Dim bwtween 10-20 members, 3 Dim between 33-34 members, 1 Dim with 44 members)
Number of input cells 862292
Rows from SQL 264519 (4 months of data)
I am loading all the data for that filter and below, so the:
a. first load for just a single agent and check the data.
b. Second load was for the branch with that agent and all other agents in that branch
c. Third was for the Mgmt Office with the same agent and all other agents and Branch in that Mgmt Office
4. Fouth load was for the region with the same agent and all other agents, Branches, and Mgmt Offices in the Region.
Each of those data loads were ok, but when I loaded the Countrywide data (All 8 regions) in one single dataload then I had problems with balancing.
Agent Heirarchy:
CW
Region
Mgmt Office
Branch
Agents
Similar Messages
-
Missing data during calculation
Hi guys,
I have problem in calculation:
ELSEIF(@ISUDA("Produkt","PRD_TAB"))
IF("Minimalny stan zapasów (tys. tabletek)" < 0 OR "Minimalny stan zapasów (tys. tabletek)" == #Missing)
"Minimalny stan zapasów (tys. tabletek)" = 0;
ENDIF
IF("Seria minimalna (tys. tabletek)" <= 0 OR "Seria minimalna (tys. tabletek)" == #Missing)
"Seria minimalna (tys. tabletek)" = 1;
ENDIF
"Stan zapasów BO (tys. tabletek)" = "Stan zapasów BO (tys. tabletek)"->"BegBalance";
"Rozchód sprzedaż (tys. tabletek)" = "Ilość produkcji tech dla PPR";
/*"Zapotrzebowanie produkcyjne (tys. tabletek)";
IF(@REMAINDER(("Zapotrzebowanie produkcyjne (tys. tabletek)" + "Minimalny stan zapasów (tys. tabletek)")/"Seria minimalna (tys. tabletek)") == 0)
"Plan produkcji magazyn (tys.tabletek)" = "Zapotrzebowanie produkcyjne (tys. tabletek)" + "Minimalny stan zapasów (tys. tabletek)";
ELSE
"Plan produkcji magazyn (tys.tabletek)" = "Seria minimalna (tys. tabletek)" * (1 + @TRUNCATE(("Zapotrzebowanie produkcyjne (tys. tabletek)" + "Minimalny stan zapasów (tys. tabletek)")/"Seria minimalna (tys. tabletek)"));
ENDIF
IF((-1) * "Zapotrzebowanie produkcyjne (tys. tabletek)" >= "Minimalny stan zapasów (tys. tabletek)")
"Plan produkcji magazyn (tys.tabletek)" = #Missing;
ENDIF;
"Stan zapasów na koniec okresu (tys. tabletek)";
"Ilość produkcji tech dla PPR" = "Plan produkcji magazyn (tys.tabletek)";*/
ELSEIF (...)
Sorry for the polish lang, everything is a name of an account.
As you can see part of the code is commeneted. And this is a problem. If I uncomment anything calculation do not work and i lose data. After I run calculation every account value is set to #Missing.
Even two I set in two if's at the beginning.
When it is commented like that everything works fine.
Does anyone see any errors in this code fragment?
Best regardshello
i can't really figure out your diagram. However, you may wanna try create probes to those expected outputs and debug your program. This helps in some cases!
try it. hope others may provide you better solutions
regards
ian
Ian F
Since LabVIEW 5.1... 7.1.1... 2009, 2010
依恩与LabVIEW
LVVILIB.blogspot.com -
Hi folks,
We are with BW 3.x. One of the Info Sources (2LIS_11_VAITM) which has sales orders information is fed from SAP R/3 through IDocs, it uses delta machanism. One day we had an issue due to password (user ALEREMOTE), the dataload to BW failed due to this. Once we reset the password, subsequent jobs picked up the data from the next day. We need to bring in data for the day the job failed.
I have read through this forum and 'Full Repair Request' seemed to be the option. I tried this using Full Repair, it didnot pull any data eventhough I specified the missing sales order nmbers in Scheduler - selection criteria. Please suggest how to trigger the missing data to be sent to BW.
FYI, IDocs in BD87 in source system, the corresponding IDocs have status -03 : Data passed to port OK.
Thank you in advance for all your help.
Sid
Edited by: Sid on Oct 23, 2009 3:12 PMHi,
Deleting setup table will not affect the delta anyway. You can do it in either way by pulling delta or later you can pull delta. Even if there is was postings those will be captured in current delta.
You can delta and refill the setup table.
Regards
Akhan -
Update of BP General Data during creation of BP
Hi,
I am currently using BADI ADDRESS_CHECK to perform an external check in a 3rd party application using XI to check if the customer name/address is flagged as a "denied party".
This works fine and returns the correct response if the check finds a denied party.
However, if this is the case ie. a denied party I want this to set some BP data accordingly during the same BP maintenance.
The data I need to set is as follows:
1. BP central block (general data)
2. BP status needs to be set
I have located function module BUP_MEMORY_BUT000_FILL that I am calling with a BP structure with the necessary block set to 'X' but it does not seem to do anything.
Can anyone provide details on how to call this function module to set BP general data during a create or a change of a BP as I must be missing something.
Also, can anyone tell me what the equivalent function module is for BP status data ?
Any help is greatly appreciated.
Cheers
Colin.HI
You cud use the following BAPI's for BP general data
BUPA_CENTRAL_CHANGE
Have a look at the function group:BUBA_4 in package :BUPA
For status you could use the following
CRM_BUPA_FRG0050_CHANGE
CRM_BUPA_FRG0050_Create
CRM_BUPA_FRG0050_GET_DETAIL
CRM_BUPA_FRG0050_SAVE_COMMIT
Regards
Jay. -
ORA-01173: data dictionary indicates missing data file from system tablespa
Hello
My Database is 11gR1 and Linux is the OS. Thought of posting it as a new thread as things have changed a lot.
2 of my database file were lost due to hardware failure. (the datafile do not belong to SYSTEM TABLESPACE) and and the second was datafile for undo tablespace.
I created control files with command not mentioning the lost datafiles:
CREATE CONTROLFILE REUSE DATABASE "BSSGLB" NORESETLOGS NOARCHIVELOG
MAXLOGFILES 32
MAXLOGMEMBERS 5
MAXDATAFILES 600
MAXINSTANCES 10
MAXLOGHISTORY 1168
LOGFILE
GROUP 1 '/DB/app/oracle/oradata/bssglb/redo01.log' SIZE 500M,
GROUP 2 '/DB/app/oracle/oradata/bssglb/redo02.log' SIZE 500M,
GROUP 3 '/DB/app/oracle/oradata/bssglb/redo03.log' SIZE 500M
-- STANDBY LOGFILE
DATAFILE
'/DB/app/oracle/oradata/bssglb/system01.dbf',
'/DB/app/oracle/oradata/bssglb/sysaux01.dbf',
'/DB/app/oracle/oradata/bssglb/users01.dbf',
'/DB/app/oracle/oradata/bssglb/bss01.dbf',
'/var/oracle/oradata/bssglb/bss02',
'/var/oracle/oradata/bssglb/system02.dbf'
CHARACTER SET US7ASCII
I have all the files mentioned in the datafile section of the above command.
But somehow when i try to open the DB, first it asks for the media recover. When i recover database then it disconnects database saying:
ERROR at line 1:
ORA-01092: ORACLE instance terminated. Disconnection forced
Process ID: 4768
Session ID: 170 Serial number: 5
Contents of the alert log file are:
Beginning crash recovery of 1 threads
parallel recovery started with 3 processes
Started redo scan
Completed redo scan
1 redo blocks read, 0 data blocks need recovery
Started redo application at
Thread 1: logseq 7, block 2, scn 20356182450
Recovery of Online Redo Log: Thread 1 Group 1 Seq 7 Reading mem 0
Mem# 0: /DB/app/oracle/oradata/bssglb/redo01.log
Completed redo application
Completed crash recovery at
Thread 1: logseq 7, block 3, scn 20356202453
0 data blocks read, 0 data blocks written, 1 redo blocks read
Sun Feb 20 08:16:23 2011
Thread 1 advanced to log sequence 8
Thread 1 opened at log sequence 8
Current log# 2 seq# 8 mem# 0: /DB/app/oracle/oradata/bssglb/redo02.log
Successful open of redo thread 1
MTTR advisory is disabled because FAST_START_MTTR_TARGET is not set
Sun Feb 20 08:16:23 2011
SMON: enabling cache recovery
Errors in file /Oracle/app/oracle/diag/rdbms/bssglb/bssglb/trace/bssglb_ora_4550.trc:
ORA-01173: data dictionary indicates missing data file from system tablespace
Error 1173 happened during db open, shutting down database
USER (ospid: 4550): terminating the instance due to error 1173
Sun Feb 20 08:16:25 2011
Instance terminated by USER, pid = 4550
ORA-1092 signalled during: alter database open...
ORA-1092 : opiodr aborting process unknown ospid (4550_182910338848)
Sun Feb 20 08:16:26 2011
ORA-1092 : opitsk aborting process
Guys please help me out of this situation.
Regards, ImranSTOP opening new threads for ongoing solution to SAME problem
Re: I have copy of data files! How to install and add these files to database!
Re: Failure of network storage!
Re: I have copy of data files! How to install and add these files to database!
Handle: misterimran
Email: misterimran
Status Level: Newbie
Registered: Jan 15, 2002
Total Posts: 1,109
Total Questions: 130 (115 unresolved)
so many questions & so few answers!
Edited by: sb92075 on Feb 19, 2011 7:49 PM -
How to recover missing data from PCL4 cluster
Hello experts,
Is there any way to recover missing data from PCL4 cluster ?
We recently found that some data related to W2 production run for past years was missing in the PCL4 cluster. Tables T5UXX & T5UXY has entries with the filing dates but certain data is missing in the cluster related to those table entries.
Would there be any specific reason for such a data loss ?
Has anyone come across this issue earlier and found resolution on the same ?
Any feedback is appreciated.
Thanks,
Dipesh.When you delete PCL4 entries for production runs, the corresponding
control information in tables T5UXX and T5UXY also will be deleted. A
control number may be used for more than one Form number (in Tax
Reporter control tables). Therefore, if a control number that is
assigned to the Form number to be deleted was also assigned to other
form numbers, then this control number information from T5UXY will not
be deleted. These details will be displayed in the program results.
However, if all Form numbers that were assigned to this particular
control number were deleted, then the control information in table T5UXY
for the control number will be deleted automatically as the last
dependent Form number is deleted."
Following we have two questions:
o Was PCL4 deleted?
o Did the W2 generate without errors?
Basically if the PCL4 data is corrupted, then we have 2 options to
rebuild the PCL4 Cluster:
1. Delete the existing PCL4 & rerun the production run with the same
As of date.
2. Overwrite the production results without deleting PCL4 data but with
different As of Date.
If the Employee data is not changed after your
actual production run then overwriting the results will not cause any
difference in the PCL4 data.
Secondly, if you dont want PDF spools or magmedia layouts to be
generated during overwriting of production run, then kindly uncheck
the following on the PU19 screen, so that only PCL4 data is rebuild :
1. Uncheck Employee Copy
2. Uncheck Authority Copy
3. Uncheck Magnetic table"
Edited by: Johan Peersman on Mar 25, 2010 4:14 PM
Edited by: Johan Peersman on Mar 25, 2010 4:15 PM -
Mysterious missing data - advice please!
Hi Everyone,
I'm having an issue with my oracle 10g database that I hope you can please help with!
Once of my users added data to the organisation table between 3pm and 4pm today.
The autoincrement number changed from 750 to 765 during this time.
After the user logged in and out of the app the data was all completely gone. No errors, nothing.
The autoincrement number remains at 765 though (if you try to add a new record).
For every minute between 3pm and 4pm I ran the following:
select id, org_name from organisation as of timestamp timestamp '2011-05-24 15:00:00' WHERE id > '749';
The result did not change at all between these times (or just prior or just after). There was never a time when there were higher id's than '750'.
I then tried to:
EXECUTE DBMS_LOGMNR.ADD_LOGFILE(logfilename=>'*****',options=>DBMS_LOGMNR.NEW);
for all the redo log files and all the flash recovery log files...
but when I tried to run:
EXECUTE DBMS_LOGMNR.START_LOGMNR(options=>DBMS_LOGMNR.DICT_FROM_ONLINE_CATALOG, STARTTIME => to_date('24-05-2011 15:00:00', 'DD-MM-YYYY HH24:MI:SS'), ENDTIME => to_date('24-05-2011 16:00:00', 'DD-MM-YYYY HH24:MI:SS'));
I just get the error:
ERROR at line 1:
ORA-01291: missing logfile
ORA-06512: at "SYS.DBMS_LOGMNR", line 58
ORA-06512: at line 1
How can I track down the missing data?
Thanks!!!user11150264 wrote:
The user changes were made via an application so they should have been committed.Err, not necessarily - have you actually checked the application code or tried to recreate this? -
Missing Data in 0FI_GL_4 delta loads.
Hello All,
We successfully loaded the 0FI_GL_4 related ODS upto 02/06. We turned on delta loads for the same from 03/06. The data validation team has discoved that there is missing data in 03 and 04. I plan on resetting the delta queue in R3 and reinitialize a full load until april. Here are my questions
1) Are there any specific steps i would need to follow?
2) Are their any other better alternatives then reinitializing with the full load.
Thanks in advance.
KiranInitialization Concept :
I will explain this with an example.
You have 5 company codes (CCs) (1000, 2000, 3000, 4000, 5000) in your R/3 source system.
But your client wants reporting in BW only for 3 Company codes (CCs) (1000, 2000, 3000).
In that case, there is no point in bringing the data for other 2 CCs.
So during Initialization, you give the inputs as,
CC = 1000, 2000, 3000 and do a Initialization (With or Without Data transfer)
So henceforth, when Delta is pulled, any changes corresponding to CCs 1000, 2000, 3000 only will be captured.
Eventhough there are changes in 4000 & 5000, they will not be captured in the Delta.
Hope I answered your Question.
Regards,
Balaji V -
Help needed with missing data problem in CRVS2010
We recently upgraded the reporting engine in our product to use Crystal Reports for Visual Studio 2010 (previously engine was CR9). Our quote report, which has numerous subreports and lots of conditional formatting, started losing data when a quote took more than a single page to be printed. We knew the SQL results included the data, but the report was not printing those lines at all or sometimes printing a partial line. In addition, the running total on the report would exclude the lines that were being missed on the next page. In one example submitted by a customer, 3 lines were skipped between pages.
I think I have identified two potential issues that document the possibility of data not being included in the report.
The first potential issue is an issue with the "suppress blank section" option being checked. This issue is supposedly fixed with ADAPT01483793, being released someday with service pack 2 for CRVS2010.
The second potential issue is using shared variables. This issue is supposedly fixed with ADAPT01484308, also targeted for SP2.
Our quote report does not explicitly use shared variables with any of the subreports, but it does have several subreports, each in its own section that has the "supress blank section" option checked. We have other reports that use this feature, as well, and they are not exhibiting the problem.
One different thing about the quote report is that it has a section with multiple suppression options selected. The section has a conditional suppression formula, which controls whether the section is included at all within the report. The section also has the suppress blank section option selected. There are multiple fields within the report that are each conditionally suppressed. In theory, the section's suppress formula could evaluate to true, yet all of the fields within the section are suppressed (due to null values), and then the "suppress blank section" option would kick in.
The missing data only seems to happen when the section is not being suppressed, and at least one of the fields is being included in the report. If I clear the "suppress blank section" check box, and change the section formula to also include the rules applied to the fields in the section, the missing data problem seems to be resolved.
Is this related to ADAPT01483793? Will it be fixed in service pack 2?
If more details are needed, I would be happy to provide a sample report with stored data.Hi Don,
Have a look at the Record Selection formula in CR Designer ( stand alone ) and when exported to RPT format opening that report in the Designer also.
There's been a few issues with => logic in the record selection formula. It could be you are running into this problem. Look for NOT inserted into your selection formula.
Oh and SP2 is coming out shortly so it may resolve the issue. But if you want you could purchase a support, or if you have a support contract then create a case in SMP and get a rep to work with you to debug the issue.
If you have not try the Trial Version of CR 2011, put it on a VM-ware image or Test PC so you don't corrupt anything for production and have a look at and test it in that designer also. If you purchase a case and it is a bug then you'll get a credit back for the case.
Don
Edited by: Don Williams on Oct 26, 2011 7:40 AM -
Insert old missing data from one table to another(databaase trigger)
Hello,
i want to do two things
1)I want to insert old missing data from one table to another through a database trigger but it can't be executed that way i don't know what should i do in case of replacing old data in table_1 into table_2
2)what should i use :NEW. OR :OLD. instead.
3) what should i do if i have records exising between the two dates
i want to surpress the existing records.
the following code is what i have but no effect occured.
CREATE OR REPLACE TRIGGER ATTENDANCEE_FOLLOWS
AFTER INSERT ON ACCESSLOG
REFERENCING NEW AS NEW OLD AS OLD
FOR EACH ROW
DECLARE
V_COUNT NUMBER(2);
V_TIME_OUT DATE;
V_DATE_IN DATE;
V_DATE_OUT DATE;
V_TIME_IN DATE;
V_ATT_FLAG VARCHAR2(3);
V_EMP_ID NUMBER(11);
CURSOR EMP_FOLLOWS IS
SELECT EMPLOYEEID , LOGDATE , LOGTIME , INOUT
FROM ACCESSLOG
WHERE LOGDATE
BETWEEN TO_DATE('18/12/2008','dd/mm/rrrr')
AND TO_DATE('19/12/2008','dd/mm/rrrr');
BEGIN
FOR EMP IN EMP_FOLLOWS LOOP
SELECT COUNT(*)
INTO V_COUNT
FROM EMP_ATTENDANCEE
WHERE EMP_ID = EMP.EMPLOYEEID
AND DATE_IN = EMP.LOGDATE
AND ATT_FLAG = 'I';
IF V_COUNT = 0 THEN
INSERT INTO EMP_ATTENDANCEE (EMP_ID, DATE_IN ,DATE_OUT
,TIME_IN ,TIME_OUT,ATT_FLAG)
VALUES (TO_NUMBER(TO_CHAR(:NEW.employeeid,99999)),
TO_DATE(:NEW.LOGDATE,'dd/mm/rrrr'), -- DATE_IN
NULL,
TO_DATE(:NEW.LOGTIME,'HH24:MI:SS'), -- TIME_IN
NULL ,'I');
ELSIF V_COUNT > 0 THEN
UPDATE EMP_ATTENDANCEE
SET DATE_OUT = TO_DATE(:NEW.LOGDATE,'dd/mm/rrrr'), -- DATE_OUT,
TIME_OUT = TO_DATE(:NEW.LOGTIME,'HH24:MI:SS'), -- TIME_OUT
ATT_FLAG = 'O'
WHERE EMP_ID = TO_NUMBER(TO_CHAR(:NEW.employeeid,99999))
AND DATE_IN <= (SELECT MAX (DATE_IN )
FROM EMP_ATTENDANCEE
WHERE EMP_ID = TO_NUMBER(TO_CHAR(:NEW.employeeid,99999))
AND DATE_OUT IS NULL
AND TIME_OUT IS NULL )
AND DATE_OUT IS NULL
AND TIME_OUT IS NULL ;
END IF;
END LOOP;
EXCEPTION
WHEN OTHERS THEN RAISE;
END ATTENDANCEE_FOLLOWS ;
Regards,
Abdetu..INSERT INTO SALES_MASTER
( NO
, Name
, PINCODE )
SELECT SALESMANNO
, SALESMANNAME
, PINCODE
FROM SALESMAN_MASTER;Regards,
Christian Balz -
Missing Data from Legacy System
Hello All,
My client went live end of January this year. They had a month of transaction data in their legacy system which they did not bring into SAP. Since this is their first year on SAP and recently implemented Extended Withhold Tax one month data is missing; when they run the 1099s at the end of the year they are going to be reported incorrectly.
How can we bring over that missing data from legacy system over to SAP without having to clear those invoices in SAP?
Thank You In AdvanceHi Shashi,
Have a look : <a href="http://www.box.net/shared/9tda040za6">Transferring Data with DB Connect</a>
<a href="http://sapbwneelam.blogspot.com">More Docs...</a>
Hope it Helps
Srini -
How can I connect dots across missing data points in a line chart?
Hi all!
I have a table in Numbers that I update every few days with a new value for the current date (in this case body metrics like weight, etc.), which looks something like this:
Column 1 Column 2 Column 3
Aug 16, 2011 87.1 15.4
Aug 17, 2011 86.6
Aug 18, 2011 86.1
Aug 19, 2011
Aug 20, 2011 85.7 14.6
Aug 21, 2011 85.3
Every once in a while there will be a missing value for a given date (because I didn't take a reading on that day). When I plot each column against the date on a line chart, there is a gap where there are missing data points. The line does not connect "across" missing data points. Is there a way to make the line connect across missing data points?
Thanks for any help. This thing has been driving me nuts!Leave your nuts in peace.
Don't use line charts but scatter charts.
These ones are able to do the trick.
Of course to do that you must study a bit of Numbers User Guide.
In column D of the Main table, the formula is :
=IF(ISBLANK($B),99999,ROW())
In column E of the Main table, the formula is :
=IF(ISBLANK($C),99999,ROW())
Now I describe the table charter.
In column A, the formula is :
=IFERROR(DAY(OFFSET(Main :: $A$1,SMALL(Main :: $D,ROW())-1,0)),"")
In column B,the formula is :
=IFERROR(OFFSET(Main :: $A$1,SMALL(Main :: $D,ROW())-1,1),"")
In column C, the formula is :
=IFERROR(DAY(OFFSET(Main :: $A$1,SMALL(Main :: $E,ROW())-1,0)),"")
In column D, the formula is :
=IFERROR(OFFSET(Main :: $A$1,SMALL(Main :: $E,ROW())-1,2),"")
In this table, select the range A1 … D5
and ask for a Scatter chart.
You will get what you need.
I asked that points are joined by curves
I just edited the parameters of Xaxis and Yaxis to get a cleaner look.
I repeat one more time that knowing what is written in the User Guides is useful to be able to solve problems with no obvious answer.
Yvan KOENIG (VALLAURIS, France) samedi 27 août 2011 15:59:20
iMac 21”5, i7, 2.8 GHz, 4 Gbytes, 1 Tbytes, mac OS X 10.6.8 and 10.7.0
My iDisk is : <http://public.me.com/koenigyvan>
Please : Search for questions similar to your own before submitting them to the community
To be the AW6 successor, iWork MUST integrate a TRUE DB, not a list organizer ! -
SMS Transferring/downloading/backup : Is there a way to download/port the missing data/SMS to one iPhone without overwriting the new SMS on the newer iPhone? Here is my dilemma. My iPhone quit working and I couldn’t get it fixed as quickly as I needed to. I bought a used iPhone and started using it normally and downloaded the backup from itunes/icloud. There was a large gap in data where the first iPhone didn’t backup when I thought it had. I have SMS data on both phonesnow and I need them for a court hearing. I have since had the other iPhone repaired and working perfectly. Will downloading a backup wipe out the newer SMS data? I am nervous because I can’t lose the information or my case mey be compromised. Any “Real Help” including programs that work to accomplish this would be very helpful. Thank You in advance…
No, direct access to manipulating the phone's filesystem is not permitted for 3rd party apps in the iOS. It can't be done without hacking the phone, which you certainly don't want to do. The messages can be combined and viewed on your computer, but not on a single phone.
-
How to Get Missing Dates for Each Support Ticket In My Query?
Hello -
I'm really baffled as to how to get missing dates for each support ticket in my query. I did a search for this and found several CTE's however they only provide ways to find missing dates in a date table rather than missing dates for another column
in a table. Let me explain a bit further here -
I have a query which has a list of support tickets for the month of January. Each support ticket is supposed to be updated daily by a support rep, however that isn't happening so the business wants to know for each ticket which dates have NOT been
updated. So, for example, I might have support ticket 44BS which was updated on 2014-01-01, 2014-01-05, 2014-01-07. Each time the ticket is updated a new row is inserted into the table. I need a query which will return the missing dates per
each support ticket.
I should also add that I DO NOT have any sort of admin nor write permissions to the database...none at all. My team has tried and they won't give 'em. So proposing a function or storable solution will not work. I'm stuck with doing everything
in a query.
I'll try and provide some sample data as an example -
CREATE TABLE #Tickets
TicketNo VARCHAR(4)
,DateUpdated DATE
INSERT INTO #Tickets VALUES ('44BS', '2014-01-01')
INSERT INTO #Tickets VALUES ('44BS', '2014-01-05')
INSERT INTO #Tickets VALUES ('44BS', '2014-01-07')
INSERT INTO #Tickets VALUES ('32VT', '2014-01-03')
INSERT INTO #Tickets VALUES ('32VT', '2014-01-09')
INSERT INTO #Tickets VALUES ('32VT', '2014-01-11')
So for ticket 44BS, I need to return the missing dates between January 1st and January 5th, again between January 5th and January 7th. A set-based solution would be best.
I'm sure this is easier than i'm making it. However, after playing around for a couple of hours my head hurts and I need sleep. If anyone can help, you'd be a job-saver :)
Thanks!!CREATE TABLE #Tickets (
TicketNo VARCHAR(4)
,DateUpdated DATETIME
GO
INSERT INTO #Tickets
VALUES (
'44BS'
,'2014-01-01'
INSERT INTO #Tickets
VALUES (
'44BS'
,'2014-01-05'
INSERT INTO #Tickets
VALUES (
'44BS'
,'2014-01-07'
INSERT INTO #Tickets
VALUES (
'32VT'
,'2014-01-03'
INSERT INTO #Tickets
VALUES (
'32VT'
,'2014-01-09'
INSERT INTO #Tickets
VALUES (
'32VT'
,'2014-01-11'
GO
GO
SELECT *
FROM #Tickets
GO
GO
CREATE TABLE #tempDist (
NRow INT
,TicketNo VARCHAR(4)
,MinDate DATETIME
,MaxDate DATETIME
GO
CREATE TABLE #tempUnUserdDate (
TicketNo VARCHAR(4)
,MissDate DATETIME
GO
INSERT INTO #tempDist
SELECT Row_Number() OVER (
ORDER BY TicketNo
) AS NROw
,TicketNo
,Min(DateUpdated) AS MinDate
,MAx(DateUpdated) AS MaxDate
FROM #Tickets
GROUP BY TicketNo
SELECT *
FROM #tempDist
GO
-- Get the number of rows in the looping table
DECLARE @RowCount INT
SET @RowCount = (
SELECT COUNT(TicketNo)
FROM #tempDist
-- Declare an iterator
DECLARE @I INT
-- Initialize the iterator
SET @I = 1
-- Loop through the rows of a table @myTable
WHILE (@I <= @RowCount)
BEGIN
-- Declare variables to hold the data which we get after looping each record
DECLARE @MyDate DATETIME
DECLARE @TicketNo VARCHAR(50)
,@MinDate DATETIME
,@MaxDate DATETIME
-- Get the data from table and set to variables
SELECT @TicketNo = TicketNo
,@MinDate = MinDate
,@MaxDate = MaxDate
FROM #tempDist
WHERE NRow = @I
SET @MyDate = @MinDate
WHILE @MaxDate > @MyDate
BEGIN
IF NOT EXISTS (
SELECT *
FROM #Tickets
WHERE TicketNo = @TicketNo
AND DateUpdated = @MyDate
BEGIN
INSERT INTO #tempUnUserdDate
VALUES (
@TicketNo
,@MyDate
END
SET @MyDate = dateadd(d, 1, @MyDate)
END
SET @I = @I + 1
END
GO
SELECT *
FROM #tempUnUserdDate
GO
GO
DROP TABLE #tickets
GO
DROP TABLE #tempDist
GO
DROP TABLE #tempUnUserdDate
Thanks,
Shridhar J Joshi
<If the post was helpful mark as 'Helpful' and if the post answered your query, mark as 'Answered'> -
SSRS 2008 R2 - Missing Data when Exporting to Excel or CSV (Row Count is 500)
Hey Folks,
When exporting SSRS 2008 R2 report to an csv or excel file not all the rows are being exported. Any suggestions on why this is occurring. The number of rows is less then 500 and it seems to be a pretty straight forward export. Any help is
greatly appreciated. Inherited this and not sure if this would be configuration issues or something else. It is happening on a number of reports.
Thanks.Hi Humbly,
According to your description, when you export report into CSV or Excel format, some rows are missing.
In your scenario, since you are missing data “rows” in your exported file, we are guessing if you have any visibility setting like toggle which hide those records. It’s possible that you have set toggle or visibility in your report. After exporting
Excel/CSV, some data might not appear properly. In SSRS 2008 R2, it has reported this kind of issue about data missing after exporting. However, those scenarios are not exactly same as your issue. It mostly turns out be conflict between data and “layout render”
and related to DataElementOutput property. DataElementOutput property controls export behavior, it indicates which report item data should appear in Excel/CSV render. For more information, please refer to this article: Reporting Services:
Why aren’t all my report columns exporting to CSV and/or XML?.
As we tested in our environment(SSRS 2008 R2), no matter what we export into CSV or Excel, we get same results as in BIDS . So I would like to know your report design structure. If possible, please provide some screenshots about results in BIDS and Excel/CSV
render extension results. It may help us find out the root cause of your issue. Thank you.
Best regards,
Qiuyun Yu
Maybe you are looking for
-
Z22 and 6.2 software issues
I have a Z22 and downloaded the latest software update - 6.2. I am using Windows Vista. At first it wouldn't download, after several tries, it completed the download. I was initially able to sync my Z22 and the computer, then it would lock up the com
-
How to make screen field enable when table control gives an error
Hi, I had a scneario like when table control data wrong then one parameter of the screen should be enabled for the input, i knew that screen-name will not work since it will have always table control fields only when table control gives an error.
-
Time Machine 1 iMac, 1 Macbook and one external drive
This must be a very simple question as I cannot find anyone else that seems to have this problem. I have a Macbook that is just a few months old and a very new iMac each running Leopard. I have an external drive connected via Firewire 800 to the iMac
-
VSS extension for JDev 10.1.3.3
Hi, I am a BPEL developer and have tried install/configure VSS ext for JDev. (Help --> Check for updates --> Source Safe ext). But it seems to be supporting a limited operations only. Like there is no recursive check in/out etc. It adds only the .jpr
-
Encrypted Windows Word Document will not open with Word for Macintosh
I cannot open a password protected/encrypted word document which was created by Word 2007/2010 for Windows even though I have the password. I have searched the internet and there does seem to be an issue whereby Macintosh Word does not support some o