TableModel with SORT and GROUP BY functions solution.
Hello all,
I'd like to represent an EnvelopeTableModel. This class is developed to incapsulate another TableModel and allow user to reorder and group data without changing original values and orders.
It allows to perform multi column sortings and grouping and
supports following group functions: EMPTY, COUNT, MIN, MAX, SUM, AVG.
Here you can download the library, demo version and documentation.
http://zaval.org/products/swing/
It would be great to know all your opinions.
With best regards
Stanislav Lapitsky
About 1) and 3).
These suggestions are almost the same. These features will change GUI component but i want to improve TableModel instead of JTable.
Using the model user can use JTable for data representation.
Of course I can improve JTable component and add multiline row/column headers with ability to reorder/group data from component and a lot of another widgets but it isn't my goal.
About 2) What do you mean "crosstab"?
Thanks for your 2-cents :-).
With best regards
Stas
Similar Messages
-
Cannot get wanted data with MAX and GROUP BY function
Hi
All
I have a table like below:
COLUMN TYPE
USER_ID VARCHAR2 (10 Byte)
PROCESS_ID VARCHAR2 (30 Byte)
END_TIME DATE(STAMP)
TO_LOC VARCHAR2 (12 Byte)
TO_LOC_TYPE VARCHAR2 (15 Byte)
FROM_LOC VARCHAR2 (12 Byte)
ITEM_ID VARCHAR2 (25 Byte)
CASES NUMBER (12,4)
LMS_UDA1 VARCHAR2 (250 Byte)
ZONE VARCHAR2 (2 Byte)
I only want get one record with all columns, only have one clause MAX(END_TIME)
But the other column have difference value.
when i use MAX(END_TIME) and GROUP BY USER_ID,PROCESS_ID,CASES,....
the sql didnot give one record,
It give many records
Please help me on this
Regards
SavenHi, Saven,
Sorry, it's unclear what you want.
Whenever you have a question, post a little sample data (CREATE TABLE and INSERT statements, relevant columns only) for all the tables involved, and the results you want from that data.
Explain, using specific examples, how you get those results from that data.
If you can show your proiblem using commonly available tables, like those in the scott or hr schamas, then you don't have to post any sample data: just the results and the explanation.
Always say what version of Oracle you're using.
See the forum FAQ {message:id=9360002}
Are you trying to see all data related to the highest (that is, latest) end_time?
I think you want something like this, that finds all the ionformation about the employee with the latest hiredate:
WITH got_r_num AS
SELECT emp.*
, ROW_NUMBER () OVER (ORDER BY hiredate DESC NULLS LAST)
AS r_num
FROM scott.emp
SELECT * -- Or list all columns except r_num
FROM got_r_num
WHERE r_num = 1
;What do you want in case of a tie, that is, if 2 or more rows have the same latest end_time? You may need to add tie-breaking expressions to the analytic ORDER BY clause, and/or use RANK instead of ROW_NUMEBR -
Using member sorting and grouping with two reports sharing rows
Hi!
I have a problem with one report and I need some help or advise here.
I have two dimensions with dynamic expansion in rows (PRODUCT, MATERIAL), and I use the option Member Sorting and Grouping at Member selector to obtain the total amount of PRODUCT group by PARENTH1:
PRODUCT MATERIAL AMOUNT
TOTAL PROD_A-X 100
PROD_A_A MAT1 22
PROD_A_B MAT1 50
PROD_A_A MAT2 28
TOTAL PROD_B-X 120
PROD_B_A MAT1 30
PROD_B_A MAT2 50
PROD_B_B MAT2 40
This works fine if I only have one report, but I need to create another one sharing the row and page axis with the Default Report, when I do that the option Member Sorting and Grouping doesn't work. I really need to have two reports with shared rows and also the summation by PARENTH1, how can I do that?
Thank you very muchHi!
I have a problem with one report and I need some help or advise here.
I have two dimensions with dynamic expansion in rows (PRODUCT, MATERIAL), and I use the option Member Sorting and Grouping at Member selector to obtain the total amount of PRODUCT group by PARENTH1:
PRODUCT MATERIAL AMOUNT
TOTAL PROD_A-X 100
PROD_A_A MAT1 22
PROD_A_B MAT1 50
PROD_A_A MAT2 28
TOTAL PROD_B-X 120
PROD_B_A MAT1 30
PROD_B_A MAT2 50
PROD_B_B MAT2 40
This works fine if I only have one report, but I need to create another one sharing the row and page axis with the Default Report, when I do that the option Member Sorting and Grouping doesn't work. I really need to have two reports with shared rows and also the summation by PARENTH1, how can I do that?
Thank you very much -
Sorting and Grouping -Two months in this query
Hi All,
many thanks for jeneesh
i am doing project for construction company, i face this problem in grouping points according to relation between these points the
Relation is from 1 to 100. If the point between this rang that mean there is relation between these points.
this question already solve but the results not correct when the table has more data.
SQL - sorting and grouping.
from jeneesh and many thanks for him.
This example for more clarifications
for example i have these points
id location percentage comments
1 loc 1,2 20% that mean point 1 and 2 close to each other by 20%
2 loc 1,3 40% that mean point 1 and 3 close to each other byy 40%
3 Loc 8,6 25% that mean point 8 and 6 close to each other by 25%
4 Loc 6,10 20%
5 LOC 11,10 10 %
6 LOC 15,14 0%Also , we can see the relation between these points as follwoing
- points 1,2,3 in one group why becuase 1,2 has relation and 1,3 has relation that mean 1,3 also has hidden relation.
- Points 6,8,10,11 in second group there are relations between them .
- but no relation between 1 or 2 or 3 with any point of 6,8,9,10,11
- as well as no relation between 15, 14 that mean 14 in third group and 15 in fourth group.
whati need?
to group the points that has relation according to percentage value ascending
The most important part is to group the points. SO , the below query the gropuing is not correct.
I have the follwoing table with data
drop table temp_value;
create table temp_value(id number(10),location varchar2(20), percentage number(9));
insert into temp_value values (1,'LOC 1,2',10);
insert into temp_value values (2,'LOC 1,3',0);
insert into temp_value values (3,'LOC 1,4',0);
insert into temp_value values (4,'LOC 1,5',0);
insert into temp_value values (5,'LOC 1,6',0);
insert into temp_value values (6,'LOC 2,3',0);
insert into temp_value values(7,'LOC 2,4',0);
insert into temp_value values (8,'LOC 2,5',30);
insert into temp_value values (9,'LOC 2,6',0);
insert into temp_value values (10,'LOC 3,4',0);
insert into temp_value values (11,'LOC 3,5',0);
insert into temp_value values (12,'LOC 4,5',40);
insert into temp_value values (13,'LOC 4,6',0);
insert into temp_value values (14,'LOC 6,7',40);
insert into temp_value values (15,'LOC 7,2',0);
insert into temp_value values (16,'LOC 8,2',60);
insert into temp_value values (17,'LOC 8,3',0);
insert into temp_value values (18,'LOC 3,1',0);
insert into temp_value values (19,'LOC 9,6',30);
insert into temp_value values (20,'LOC 11,2',0);
insert into temp_value values (22,'LOC 12,3',10);
insert into temp_value values (23,'LOC 19,3',0);
insert into temp_value values (24,'LOC 17,3',0);
insert into temp_value values (24,'LOC 20,3',0);when i used this query , the results is not correct
with t as
(select percentage,loc1,loc2,sum(case when percentage = 0 then 1
when loc1 in (l1,l2) then 0
when loc2 in (l1,l2) then 0
when l1 is null and l2 is null then 0
else 1
end) over(order by rn) sm
from ( select id,location,percentage,
regexp_substr(location,'\d+',1,1) LOC1,
regexp_substr(location,'\d+',1,2) LOC2,
lag(regexp_substr(location,'\d+',1,1))
over(order by percentage desc) l1,
lag(regexp_substr(location,'\d+',1,2))
over(order by percentage desc) l2,
row_number() over(order by percentage desc) rn
from temp_value
order by percentage desc
select loc,min(sm)+1 grp
from(
select loc,rownum rn,sm
from(
select percentage,decode(rn,1,loc1,loc2) loc,sm
from t a,
(select 1 rn from dual union all
select 2 from dual ) b
order by percentage desc,decode(rn,1,loc1,loc2) asc
group by loc
order by min(sm),min(rn);the results
SQL> /
LOC GRP
2 1
8 1
6 2
7 2
4 3
5 3
9 4
1 5
12 6
3 6
11 13
LOC GRP
19 14
17 15
20 22
14 rows selected.SQL>
but the correct is
Location group No
2 1
8 1
4 1
5 1
1 1
6 2
7 2
9 2
12 3
3 3
19 4
17 5
20 6many thanks in advance.
Edited by: Ayham on Nov 30, 2012 3:07 AMThanks,
i want the sorting for each group DESC not all groups to gather
when i used your query i get
SQL> with connects as (
2 select distinct
3 loc1
4 ,loc2
5 ,dense_rank() over (order by connect_by_root(loc1)) grp
6 from temp_value
7 start with
8 percentage != 0
9 connect by nocycle
10 (prior loc2 = loc1
11 or
12 prior loc1 = loc2
13 or
14 prior loc1 = loc1
15 or
16 prior loc2 = loc2)
17 and
18 percentage != 0
19 )
20 , got_grp AS
21 (
22 select
23 loc
24 ,dense_rank() over (order by grp) grp
25 from (
26 select
27 loc
28 ,max(grp) keep (dense_rank first order by grp) grp
29 from (
30 select
31 loc1 loc
32 ,grp
33 from connects
34 union
35 select
36 loc2
37 ,grp
38 from connects
39 )
40 group by
41 loc
42 )
43 )
44 SELECT loc
45 , grp
46 FROM got_grp
47 ORDER BY COUNT (*) OVER (PARTITION BY grp) DESC
48 , grp
49 , loc
50 ;The output is
LOC GRP
1 1
2 1
4 1
5 1
8 1
6 3
7 3
9 3
12 2
3 2
10 rows selected.but i want it like this
Loc Grp
2 1
8 1
4 1
5 1
1 1
12 2
3 2
6 3
7 3
9 3So , the sorting for each group Separate based on the percentage column.
many thanks
Edited by: Ayham on Nov 30, 2012 9:43 AM -
Since I upgrade my iphone 3gs to ios 5.1, I have several problems with network and wi-fi, any solution? (No jailbreak)
Most of the time the iphone cannot reach any network and when it can, there is no data transfer, I can only make calls and sms.Skizofrenias wrote:
Since I upgrade my iphone 3gs to ios 5.1, I have several problems with network and wi-fi, any solution? (No jailbreak)
Most of the time the iphone cannot reach any network and when it can, there is no data transfer, I can only make calls and sms.
iOS: Troubleshooting Wi-Fi networks and connections
iOS: Wi-Fi or Bluetooth settings grayed out or dim -
Hard currency is not valuated in FAGL_FC_VAL along with local and group currency
Hi All,
I have the below system settings for FOREX revaluation. The revaluation is not happening for Hard currency along with local and group currency. The test data and other settings seams to be fine as the below mentioned workaround works perfectly for hard currency revaluation.
I would like to take your expert feedback on this issue to confirm whether this is how SAP works or its an issue with FAGL_FC_VAL program.
System Settings:
Currencies in company code
local currency group currency hard currency
10 30 40
USD USD UYU
FOREX settings:
Work around found:
Define two Valuation area, say
1. Valuation Area: A1 which will have currency type 10 and 30.
2. Valuation Area: A2 which will have only the currency type 40.
3. Run FAGL_FC_VAL twice for these area.
Issue with this work around:
1. The valuation area is assigned to one accounting principle (which is in turn assigned to a specific ledger).
2. Thus, if I have different accounting FOREX process to be followed in different ledgers (say IFRS ledger, Local Ledger, Tax ledger) then I need to create 2 valuation area (as per above workaround) for each ledgers and run FAGL_FC_VAL for each of these valuation areas.
Thanks & Regards
Nikhil KothariHi Experts,
Any views on the above issue?
Thanks & Regards
Nikhil Kothari -
Logs are generating with owner and group as 'root'
Hi,
In our newly installed and configured Oracle application server(10.1.3.5), the logs are generating with owner and group as 'root'.
Location: $ORACLE_HOME/Apache/Apache/logs
-rw-r----- 1 root root 6700 Apr 3 02:03 access_log.1364947200
-rw-r----- 1 root root 430 Apr 3 02:04 error_log.1364947200
We have configured it on port 80. For this the '.apachectl' ownership and permissions are changed as below:
-rwsr-s--- 1 root dba 1703780 Jul 21 2009 .apachectl
Kindly let me know what are the changes to be made, for the logs to be generated with the group as 'dba' instead of 'root'.
Thanks.
Edited by: 985284 on Apr 3, 2013 3:14 AM
Edited by: 985284 on Apr 3, 2013 4:22 AMOk - that is quit weird then. If you want to run the HTTP Server on a privileged port, you basically change the ownership of the .apachectl executable :
cd ORACLE_HOME/Apache/Apache/bin
chown root .apachectl
chmod 6750 .apachectlas per [url http://docs.oracle.com/cd/B25221_05/core.1013/b25209/ports.htm#CIHJEEJH]documentation.
Your user and group directive should be set to :
User oracle
Group dbaUpon starting, the http server would start as root and then switch the effective userid of the process from root to oracle. In the process list (ps -ef | grep httpd), you should see oracle.
Do you have the same configuration and what do you see in the process list? -
Sorting and Grouping by multi-value Choice columns - any options?
I found out the hard way that SharePoint doesn't support sorting or grouping lists by Choice columns that are set to "Allow Multiple Values." I'm stunned by this missing capability, and my project has come to a complete halt without it. It's like Microsoft only implemented hafl the feature -- you can put data in, but then you can't do anything with it. You can't even use the column in a formula in another column, so you can't parse it.
I'm not posting just to gripe though. Does anyone have any suggestions for alternatives? What do you do when you need to let people make multiple selections, and then you want to sort or group by those values? Are there any add-on products that allow this? At this point my only option seems to be to not allow multiple choices, but that's taking away a rather significant feature.
Thanks for any ideas,
SteveHi Paul,
Thank you for the reply and the additional questions. For my situation I want to use the multi-value choice to indicate a "belongs to" relationship, as in "this item belongs to projectA, projectB, and project C. Because there are more than 10 projects, I didn't want to create a separate Yes/No checkbox for each one.
For viewing the information, I'm looking primarily for a "group by" function. So if an item belongs to projectA, projectB, and projectC, it would appear three times, once under the grouping for each project. What I don't want is for a row that only belongs to projectA to be grouped separately from a row that belongs to both projectA and projectB. I want to see all the rows that belong to projectA grouped together, regardless of whether they also belong to other projects.
I'll look into using a grid control, but if you have any other suggestions I'll certainly listen.
Steve -
Sorting and Grouping in Projects View
In Projects view, when either of two of the three grouping options is selected, there are two sorts in effect: the groups themselves are sorted, and the contents of each group are sorted. These sorts are handled differently, depending on the grouping selected and the sort order selected.
(It appears that there is a bit of the old Apple voodoo in here. The results are arbitrary , but they seem to have been carefully chosen to meet most users expectations. That is to say -- and this is an Apple programming trait -- the arbitrariness is faithful to the expected users' needs, not to logic.)
There are four sorts available, and three groupings
Sorts:
. Name
. Date -- Oldest First
. Date -- Newest First
. Library
Groupings:
. Ungrouped
. Group by year
. Group by folder
So that's twelve possible ways to display Projects in Projects view.
Let's look at a few of them. I'm going to refer to the groups as "Year groups" or "Folder groups" and to the contents of the groups as "Projects". So there is sorting of the groups, and sorting of the contents of the groups (same as "within the group"). These I'll refer to as "Groups sorting" and "Projects sorting".
Sort: Date -- Newest First
Grouping: Group by Year
Result: Year groups are sorted in the same order as Projects. Projects which span multiple years are put in multi-year groups. Projects with the same spans are grouped together.
Sort: Date -- Oldest First
Grouping: Group by Year
Results are as expected; a reversal of the "Newest First" sort, but with the same groups: Year groups are sorted in the same order as Projects. Projects which span multiple years are put in multi-year groups. Projects with the same spans are grouped together.
Sort: Name
Grouping: Group by Year
Result: Year groups are sorted by year, oldest first. Projects which span multiple years are put in multi-year groups. Projects with the same spans are grouped together. Projects are sorted alphabetically, descending.
Sort: Library
Grouping: Group by year
Result: Year groups are sorted by year, oldest first. Projects which span multiple years are put in multi-year groups. Projects with the same spans are grouped together. Projects are listed in the order they occur in the Library structure shown on the Library tab of the Inspector. (Note that this last is literal: a Project named "Aardvark Close-ups" if it's in a Folder named "Zoography" will be listed after all the projects in "Yellow Paintings" and all the Projects in "X-rays, thoracic" if those Projects are in alphabetical order by Folder name in the Library. You can see all the Projects in your Library listed on the Library tab of the Inspector by "{Option}+clicking" the disclosure triangle next to "PROJECTS & ALBUMS" twice.)
Sort: Date - Newest First
Grouping: Group by folder
Result: Folder groups are sorted alphabetically by name, descending. Projects are sorted by date, newest first. Clicking a Folder's name in the Project viewer drills down to show the sub-Folders and Projects in the clicked Folder.
Sort: Date - Oldest First
Grouping: Group by folder
Result: Folder groups are sorted alphabetically by name, descending. Projects are sorted by date, oldest first. Clicking a Folder's name in the Project viewer drills down to show the sub-Folders and Projects in the clicked Folder (where, again, Folder groups are sorted alpha-name, descending, and Projects are sorted alpha-name, descending).
Sort: Name
Grouping: Group by folder
Result: Folder groups are sorted alphabetically by name, descending. Projects are sorted alphabetically by name, descending. Clicking a Folder's name in the Project viewer drills down to show the sub-Folders and Projects in the clicked Folder (where, again, Folder groups are sorted alpha-name, descending, and Projects are sorted alpha-name, descending).
Sort: Library
Grouping: Group by folder
Result: Folder groups are sorted alphabetically by name, descending. Projects are listed in the order they occur in the Library structure shown on the Library tab of the Inspector (see note above). Clicking a Folder's name in the Project viewer drills down to show the sub-Folders and Projects in the clicked Folder (where, again, Folder groups are sorted alpha-name, descending, and Projects are listed in the order they appear in the Library).
Ernie [asked:|http://discussions.apple.com/thread.jspa?threadID=2816124&tstart=0]
+I see those icons but note that those projects in folders will be in different sections arranged alpha, and then date within. Am I correct on that?+
The answer is, it depends.
If "Group by year" is selected, the Groups-sorting will always be by date, regardless of the sort order specified. The Groups-sorting order will follow whatever is specified for the Projects sort order (or default to "oldest first").
If "Group by folder" is selected, the Groups-sorting will always be alphabetical, descending, regardless of the sort order specified. (So if you use Projects view, take care in naming your Folders. Use prefixes if needed to force a desired alpha sort.)
If "Ungrouped" is selected, there are no Groups and perforce no Groups-sorting.
That's all I have to say on this topic (today).
Message was edited by: Kirby KriegerIn Projects view, when either of two of the three grouping options is selected, there are two sorts in effect: the groups themselves are sorted, and the contents of each group are sorted. These sorts are handled differently, depending on the grouping selected and the sort order selected.
(It appears that there is a bit of the old Apple voodoo in here. The results are arbitrary , but they seem to have been carefully chosen to meet most users expectations. That is to say -- and this is an Apple programming trait -- the arbitrariness is faithful to the expected users' needs, not to logic.)
There are four sorts available, and three groupings
Sorts:
. Name
. Date -- Oldest First
. Date -- Newest First
. Library
Groupings:
. Ungrouped
. Group by year
. Group by folder
So that's twelve possible ways to display Projects in Projects view.
Let's look at a few of them. I'm going to refer to the groups as "Year groups" or "Folder groups" and to the contents of the groups as "Projects". So there is sorting of the groups, and sorting of the contents of the groups (same as "within the group"). These I'll refer to as "Groups sorting" and "Projects sorting".
Sort: Date -- Newest First
Grouping: Group by Year
Result: Year groups are sorted in the same order as Projects. Projects which span multiple years are put in multi-year groups. Projects with the same spans are grouped together.
Sort: Date -- Oldest First
Grouping: Group by Year
Results are as expected; a reversal of the "Newest First" sort, but with the same groups: Year groups are sorted in the same order as Projects. Projects which span multiple years are put in multi-year groups. Projects with the same spans are grouped together.
Sort: Name
Grouping: Group by Year
Result: Year groups are sorted by year, oldest first. Projects which span multiple years are put in multi-year groups. Projects with the same spans are grouped together. Projects are sorted alphabetically, descending.
Sort: Library
Grouping: Group by year
Result: Year groups are sorted by year, oldest first. Projects which span multiple years are put in multi-year groups. Projects with the same spans are grouped together. Projects are listed in the order they occur in the Library structure shown on the Library tab of the Inspector. (Note that this last is literal: a Project named "Aardvark Close-ups" if it's in a Folder named "Zoography" will be listed after all the projects in "Yellow Paintings" and all the Projects in "X-rays, thoracic" if those Projects are in alphabetical order by Folder name in the Library. You can see all the Projects in your Library listed on the Library tab of the Inspector by "{Option}+clicking" the disclosure triangle next to "PROJECTS & ALBUMS" twice.)
Sort: Date - Newest First
Grouping: Group by folder
Result: Folder groups are sorted alphabetically by name, descending. Projects are sorted by date, newest first. Clicking a Folder's name in the Project viewer drills down to show the sub-Folders and Projects in the clicked Folder.
Sort: Date - Oldest First
Grouping: Group by folder
Result: Folder groups are sorted alphabetically by name, descending. Projects are sorted by date, oldest first. Clicking a Folder's name in the Project viewer drills down to show the sub-Folders and Projects in the clicked Folder (where, again, Folder groups are sorted alpha-name, descending, and Projects are sorted alpha-name, descending).
Sort: Name
Grouping: Group by folder
Result: Folder groups are sorted alphabetically by name, descending. Projects are sorted alphabetically by name, descending. Clicking a Folder's name in the Project viewer drills down to show the sub-Folders and Projects in the clicked Folder (where, again, Folder groups are sorted alpha-name, descending, and Projects are sorted alpha-name, descending).
Sort: Library
Grouping: Group by folder
Result: Folder groups are sorted alphabetically by name, descending. Projects are listed in the order they occur in the Library structure shown on the Library tab of the Inspector (see note above). Clicking a Folder's name in the Project viewer drills down to show the sub-Folders and Projects in the clicked Folder (where, again, Folder groups are sorted alpha-name, descending, and Projects are listed in the order they appear in the Library).
Ernie [asked:|http://discussions.apple.com/thread.jspa?threadID=2816124&tstart=0]
+I see those icons but note that those projects in folders will be in different sections arranged alpha, and then date within. Am I correct on that?+
The answer is, it depends.
If "Group by year" is selected, the Groups-sorting will always be by date, regardless of the sort order specified. The Groups-sorting order will follow whatever is specified for the Projects sort order (or default to "oldest first").
If "Group by folder" is selected, the Groups-sorting will always be alphabetical, descending, regardless of the sort order specified. (So if you use Projects view, take care in naming your Folders. Use prefixes if needed to force a desired alpha sort.)
If "Ungrouped" is selected, there are no Groups and perforce no Groups-sorting.
That's all I have to say on this topic (today).
Message was edited by: Kirby Krieger -
WEB UI account creation with role and grouping
Hi All,
I can create account in SalesPro->Account Management-> Account - New
I don't have an option of selecting BP Role or Grouping for number range...
Should i be using any other WEBUI Role in order to create Account with an option of BP Role and Grouping
Thanks
AmishHello there,
The BP Role which will be used and even the number ranges are generally not used for Web UI usage. Instead we provide different configurations of the same Account Creation view based on the Component Usage and three different keys.
The functionality you are looking for can be achieved by creating different configurations.
To create different configurations of the same view in Web UI please search on the below link :
[http://wiki.sdn.sap.com/wiki/display/CRM/CRMWebClientUIFramework|http://wiki.sdn.sap.com/wiki/display/CRM/CRMWebClientUIFramework]
Please reply if this helps.
Best regards,
Vinamra. -
Problem with 'sort and filter' feature of embed codes in Excel Online Web App
So my question has to do with the Excel Online feature where you can share a spreadsheet and embed it in a website with the option of allowing users to sort and filter the data. (The option is under the "Interaction" heading.)
One of the options if you look closely is "Let people sort and filter" which is not checked off. In the embed code you can see "AllowInteractivity=False". The problem is that when I check "Let people sort and filter"
the embed code changes completely - going from:
<iframe width="700" height="900" frameborder="0" scrolling="no" src="https://onedrive.live.com/embed?cid=dontworryaboutitEDFD383&resid=6BAA9620AEDFD383%21107&authkey=AFj3X8xq2U3IfDE&em=2&wdAllowInteractivity=False&Item='Sheet1'!A1%3AI32"></iframe>
to:
<iframe width="700" height="900" frameborder="0" scrolling="no" src="https://onedrive.live.com/embed?cid=dontworryaboutitEDFD383&resid=6BAA9620AEDFD383%21107&authkey=AFj3X8xq2U3IfDE&em=2&Item='Sheet1'!A1%3AI32"></iframe>
If I manually change 'false' to 'true' that doesn't do the trick so I'm not sure what to try next.
Any thoughts?Hi,
We support Office for Windows in the current forum, since this question is about Office Online, I suggest you post the question in Office Online forum:
http://community.office365.com/en-us/f/default.aspx
The reason why we recommend posting appropriately is you will get the most qualified pool of respondents, and other partners who read the forums regularly can either share their knowledge or learn from your interaction with us. Thank you for your understanding.
George Zhao
TechNet Community Support
It's recommended to download and install
Configuration Analyzer Tool (OffCAT), which is developed by Microsoft Support teams. Once the tool is installed, you can run it at any time to scan for hundreds of known issues in Office
programs. -
SQL Server SUM of Multiple rows with where and group by
I have a table Transaction that looks something like the following :
TransactionID
Currency
Credit
Debit
1 USD
500 0
2 Afcu
6000 0
3 INR
0 200
4 Pfc
7000 0
5 AUD
0 200
6 INR
7000 0
7 USD
1000 0
I write query like this
select SUM(credit)-SUM(Debit)as [Balance] ,Source from Transaction group by Source
and it came like
Balance
Source
1500 USD
6000 Afcu
6800 INR
7000 Pfc
-200 AUD
But I also want to add Afcu , Pfc with
USD and want output like
Balance
Source
14500 USD
6800 INR
-200 AUD
Any Idea?Here is how you can do it, but you
DECLARE @TransTable TABLE
(TransactionID INT IDENTITY(1,1),
Currency varchar(10),
Credit DECIMAL,
Debit DECIMAL)
INSERT INTO @TransTable VALUES
('USD',500,0),('Afcu',6000,0),('INR',0,200),('Pfc',7000,0),('AUD',0,200),
('INR',7000,0),('USD',1000,0)
SELECT Currency, SUM(credit)-SUM(Debit)as [Balance]
FROM @TransTable
WHERE Currency NOT IN ('Afcu', 'pfc','USD')
GROUP BY Currency
UNION
SELECT 'USD', SUM(credit)-SUM(Debit)as [Balance]
FROM @TransTable
WHERE Currency IN ('Afcu', 'pfc','USD')
SQL fiddler example
Output:
Hope this will help
Glad to help! Please remember to accept the answer if you found it helpful. It will be useful for future readers having same issue.
My Profile on Microsoft ASP.NET forum -
Swatches CS3 - Sorting and grouping possible?
Hello,
a simple question. Is it possible to sort or group swatches?
If the answer is yes, how do I do it?
Thanks,
MattYou can select and drag them up and down the panel.
k -
Problem with sorting and filtering of table
Hello,
using VC 7.1 SP5 I have created [this|http://img232.imageshack.us/img232/2460/screenshotsr0.png] model. The webservice returns a collection of structured elements. The table is meant to display values of top-level attributes. This works as expected.
However, the table cannot be sorted or filtered. What is the reason for this? How can I fix that?
I tried to store the result of the web service in a data bridge. That did not succeed.
Best regards
AlexanderHi Natty,
How are you trying to sort it?
I want to be able to sort the table by clicking on the table column headers. Furthermore, I want be able to filter the table by using the built-in table feature. However, table sorting and filtering seem to be disabled for this particular table, whereas other tables in my model provide the desired features.
Best regards
Alexander -
Hello,
Anyone know if there is a way to do something like this?
Original XML:
<item>
<word>word1</word><num>10</num><num2>9</num2>
</item>
<item>
<word>word2</word><num>5</num><num2>3</num2>
</item>
<item>
<word>word1</word><num>7</num><num2>6</num2>
</item>
I want to do something like group on <word> and sort accending on sum(<num>), min(<num2>) and end up with this:
<item>
<word>word1</word><num>17</num><num2>6</num2>
</item>
<item>
<word>word2</word><num>5</num><num2>3</num2>
</item>
Is this possible?
thanks,
chad.Here's a start. See Chapter 9 of my book for a complete explanation of how to exploit XSLT keys like database functional indexes to make grouping operations like this be fast in XSLT. It takes a bit to wrap your mind around why and how it works and the book has figures that help illustrate this.
<!-- chad.xml -->
<list>
<item>
<word>word1</word><num>10</num><num2>9</num2>
</item>
<item>
<word>word2</word><num>5</num><num2>3</num2>
</item>
<item>
<word>word1</word><num>7</num><num2>6</num2>
</item>
</list>
<!-- chad.xsl -->
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xsl:key name="g" match="item" use="word"/>
<xsl:output indent="yes"/>
<xsl:template match="/">
<list>
<xsl:for-each select="list/item[generate-id(.)=generate-id(key('g',word)[1])]">
<xsl:sort data-type="number" select="sum(key('g',word)/num)"/>
<xsl:variable name="items-with-same-word" select="key('g',word)"/>
<item>
<word><xsl:value-of select="word"/></word>
<num><xsl:value-of select="sum($items-with-same-word/num)"/></num>
<num2><xsl:value-of select="sum($items-with-same-word/num2)"/></num2>
</item>
</xsl:for-each>
</list>
</xsl:template>
</xsl:stylesheet>This produces the output:
<list>
<item>
<word>word2</word>
<num>5</num>
<num2>3</num2>
</item>
<item>
<word>word1</word>
<num>17</num>
<num2>15</num2>
</item>
</list>
Maybe you are looking for
-
Calculation of Coverage Amount
Hi All, I am new to configuring benefits, can anyone of you guide me how to configure the calculation of the coverage amount if i want to calculate it based on a fraction of the annual salary. Also I would like to know where do we configure the assig
-
Table field set as "Initial" is not acceptinf duplicate entries
Hi all, I have inserted a custom include structure(which has only one field and is made as Initial) into a standard field. Then values inserted using INSERT <table> FROM TABLE <Internal table> ACCEPTING DUPLICATE KEYS. But if the internal table conta
-
Can't get FCP X through "macappstore"
FCP "Buy Now" buttons link to http://itunes.com/mac/finalcutpro which forwards to http://search.itunes.apple.com/WebObjects/MZContentLink.woa/wa/link?path=mac%2ff inalcutpro after which Firefox (or Safari) "doesn't know how to open this address, beca
-
Issue while updating(Changing) quantity on line at quick sales order form
Hi, I am facing a issue while changing quantity ordered on the order line in quick sales order form. (R12.1.3) Although the same logic works exactly as required in 11.5.9. There is a custom logic, post booking line status is Awaiting Shipping. Now wh
-
Notifications app introduced in Asha 311?
After updating Asha 311 to firmware v.5.92, i found a new notifications app present in the menu which claims to show up recent notifications. Sounds exciting. But, after using the phone for 5-6 days, I found that it doesn't do anything. It never gath