Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to do SQL aggregate query on xml file in CR for VS2005

Status
Not open for further replies.

auhe

Programmer
Aug 23, 2005
1
US
I have an .xml file with schema file .xsd look like this:

Table:
number_of_subjects
birth_day
birth_month
birth_year

All the data are stored in the .xml file.

In my project, I need to generate a report to show how many duplicate entries in each birthdate bin (e.g. 120 occupied birth date bins have 1 entry; 31 have 2 entries; 4 have 3 entries...).

Thus, in the crystal report, I need to show the results of an SQL like:

SELECT COUNT(number_of_subjects) AS 'entries', number_of_subject AS 'bin_size"
FROM Table
GROUP BY number_of_subjects

My problem is how to write this query in the crystal report? I also tried to do the query in the dataset when loading the xml file; but it seems dataset can only do "select", however, i need an "aggregation" query. Can anyone help me? Thanks!!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top