Hi:
Thanks for the answers, I have not used StackOverflow before so I was suprised by the number of answers and the speed of them - its fantastic.
I have not been through the answers properly yet, but thought I should add some information to the problem specification. See the image below.
I can't post an image in this because i don't ...
SELECT AVG(data) AS data, dateReg
FROM table
GROUP BY YEAR(dateReg), MONTH(dateReg), DAY(dateReg) ORDER BY dateReg
the Above Data Returns
1.75, 21 Jan 2010
9.45, 22 Jan 2010
3.96, 23 Jan 2010
2.68, 30 Jan 2010
Its missing dates from the 24th to 29th, Can we do it so the return value is:
1.75, 21 Jan 2010
9.45, 22 Jan 2010
3.96, 2...
Hello All,
I need to group the value based on some attribute and populate it.
below mentioned is i/p xml and if you see there are 4 rows for Users and for id 2,4 Division is same i.e. HR
while generating actual o/p I need to group by Division ... Any help ???
I/P XML
<Users>
<User id="2" name="ABC" Division="HR"/>
<User id="3" n...
Hi,
I'm something of a WPF noob so please take it easy on me ;-)
I am trying to create a grouped DataGrid (WPF toolkit version).
I have successfully created the data source, the DataGrid itself, the required CollectionViewSource and the Style for the group header (which uses an expander).
I want to group by a property called 'Assign...
I have a table that holds products, another that holds variations and a third that hold product variations (many products can have many variations..both ways). I want to display (group by) each product and show the variations.
what i've read is just looping thru and comparing id's to see which record you are on, if a new one then adjus...
Now with Formtastic I have plain select:
= f.input :category, :as => :select, :include_blank => false, :collection => subcategories
Here I show only children categories. I use acts_as_tree plugin for parent-child relationship. I would like to show parent categories as well.
Formtastic generated select should look like this one:
<sel...
Hi...
I'm using iReport 3.7. I have a report with two subreports (order details and some selling statistics), and a grouping by seller.
One subreport is located in the Detail band of the group, and the other one is in the group footer.
What's really odd is that no matter how long the report is, when I export it to PDF it's always one ...
I have an array of strings, not many (maybe a few hundreds) but often long (a few hundred chars).
Those string are, generally, nonsense and different one from the other.. but in a group of those string, maybe 5 out of 300, there's a great similarity. In fact they are the same string, what differs is formatting, punctuation and a few wor...
Hi,
I have a Flex AdvancedDataGrid which is fed XML like this:
<documents>
<document>
<name>Jake</name>
<skills>
<skill>Flex</skill>
<skill>Domino</skill>
<skill>ASP.NET</skill>
</skills>
<document>
<document>
<name>Trevor</name>
<skills>
<skill>Flex</skill>
<skill>C++</skill>
<skill>ASP.NET</sk...
I am trying to use a DataGrid with hidden group row headers (so that there is a sort boundary). My style simply sets the visibility to collapsed (and I also am setting the SublevelIndent to 0 during the LoadingGroup event). Initial display is exactly what I want, but the data grid is sorted the appearance is unstyled, and the default ...
I have the following XML file:
<Promotions>
<Promotion>
<Category>Arts & Entertainment</Category>
<Client>Client Five</Client>
<Title>Get your Free 2</Title>
</Promotion>
<Promotion>
<Category>Arts & Entertainment</Category>
<Client>Client 5</Client>
<Title>Get your Free 4</Title>
</Promotion>
<...
I'm trying to add hierarchy to some grotty extruded typesetting XML. I can't seem to manage grouping several kinds of groups in the same parent element at once.
What I have (simplified, obviously):
<article>
<h1>A section title here</h1>
<p>A paragraph.</p>
<p>Another paragraph.</p>
<bl>Bulleted list item.</bl>
<bl>Another bu...
I develop an open-source Objective-C framework, and I use Doxygen to generate the documentation (http://dysart.cs.byu.edu/CHDataStructures). Overall, Doxygen does a nice job, but I have a perennial annoyance that I can't figure out for the life of me.
I use the \name command and Member Groups to group methods by task (these Apple docs s...
So in this grotty extruded typesetting product, I sometimes see links and email addresses that have been split apart. Example:
<p>Here is some random text with an email address
<Link>example</Link><Link>@example.com</Link> and here
is more random text with a url
<Link>http://www.</Link><Link>example.com</Link> near ...
This article elaborates how to select N records each group:
http://www.xaprb.com/blog/2006/12/07/how-to-select-the-firstleastmax-row-per-group-in-sql/
The best solution for this kind of job is:
set @num := 0, @type := '';
select type, variety, price,
@num := if(@type = type, @num + 1, 1) as row_number,
@type := type as du...
How can I yield multiple items at a time from an iterable object?
For example, with a sequence of arbitrary length, how can I iterate through the items in the sequence, in groups of X consecutive items per iteration?
(Question inspired by an answer which used this technique.)
...
I'm creating a WPF TimeCard app using the MVVM design pattern, and I'm trying to display the sum (total) hours the user has clocked in grouped by each day. I have a ListView with all of the TimeCard data broken into groups using the following XAML:
<ListView.GroupStyle>
<GroupStyle ContainerStyle="{StaticResource GroupItemStyle}">
...
I have some data that has various attributes and I want to hierarchically group that data. For example:
public class Data
{
public string A { get; set; }
public string B { get; set; }
public string C { get; set; }
}
I would want this grouped as:
A1
- B1
- C1
- C2
- C3
- ...
- B2
- ...
A2
- B1
- ......
Good day, I have a question I'm struggling with a lot, hope somebody already found a clever solution to this (I use MySQL).
I have table like this:
Table `log`
----------
id
inserted
message
user_id
My goal is to select last inserted record for user and make this fast. Log table is huge (around 900k records),
so my first approach was...
Hi, im trying to extract the most common YEAR from an array of DateTime objects using LINQ.
can someone help me? With the following its telling me i need to implement IComparable..
DateTime modeDate = (from c in dates
group c by c.Year into g
select g).Max(...