JasperReports: Report with xml subreport xPath - xpath

I have a master report that call a sub report when a group change.
I pass two XML Documents that are the different datasource for the master and the sub report.
The subreport is printing , but every subreport lose the 2 first records of the data.
I think is a wrong xPath expression, but i try several solution but no one works for me.
The snippet of master's report jrxml file:
<queryString language="xPath"><![CDATA[riepilogo-ec/dettagli/dettaglio]]></queryString>
<group name="GiroGroup" isStartNewColumn="false" isStartNewPage="false"
isReprintHeaderOnEachPage="true" keepTogether="true">
<groupExpression>
<![CDATA[$F{giro}]]>
</groupExpression>
<groupFooter>
<band height="20" isSplitAllowed="false">
<subreport>
<reportElement isPrintRepeatedValues="true" x="0" y="0" width="507" height="10"
isRemoveLineWhenBlank="true" backcolor="#ffcc99"> </reportElement>
<subreportParameter name="REPORT_DATA_SOURCE">
<subreportParameterExpression>
<![CDATA[new net.sf.jasperreports.engine.data.JRXmlDataSource( $P{subTotale}).dataSource("totali/totale[#giro=" + $F{giro}+ "]/tot-cau")]]>
<!--<![CDATA[new net.sf.jasperreports.engine.data.JRXmlDataSource( $P{subTotale})]]>-->
<!--<![CDATA[new net.sf.jasperreports.engine.data.JRXmlDataSource( $P{subTotale}).subDataSource("/totali/totale[#giro=1]")]]>-->
</subreportParameterExpression>
</subreportParameter>
<subreportParameter name="XML_DATE_PATTERN">
<subreportParameterExpression>$P{XML_DATE_PATTERN}</subreportParameterExpression>
</subreportParameter>
<subreportParameter name="XML_NUMBER_PATTERN">
<subreportParameterExpression>$P{XML_NUMBER_PATTERN}</subreportParameterExpression>
</subreportParameter>
<subreportParameter name="XML_LOCALE">
<subreportParameterExpression>$P{XML_LOCALE}</subreportParameterExpression>
</subreportParameter>
<subreportParameter name="XML_TIME_ZONE">
<subreportParameterExpression>$P{XML_TIME_ZONE}</subreportParameterExpression>
</subreportParameter>
<subreportParameter name="pageNumberMaster">
<subreportParameterExpression>$V{PAGE_NUMBER}</subreportParameterExpression>
</subreportParameter>
<subreportParameter name="giro">
<subreportParameterExpression>$F{giro}</subreportParameterExpression>
</subreportParameter>
<subreportExpression class="net.sf.jasperreports.engine.JasperReport"
>$P{subReport}</subreportExpression>
</subreport>
</band>
</groupFooter>
</group>
Sub report query:
<queryString language="xPath"><![CDATA[totali/totale/tot-cau]]></queryString>
Master data:
<dettagli>
<dettaglio>
<giro>1</giro>
<cod-riv>1</cod-riv>
<check-digit>G</check-digit>
<desc-riv>FUSARO GIANCARLO</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>1.162,44 </forniture>
<addebiti/>
<rese>461,46 </rese>
<accrediti/>
<saldo-contabile/>
<saldo-ec>700,98 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>2</cod-riv>
<check-digit>H</check-digit>
<desc-riv>BENINI LAURA</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>785,16 </forniture>
<addebiti/>
<rese>250,92 </rese>
<accrediti/>
<saldo-contabile/>
<saldo-ec>534,24 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>4</cod-riv>
<check-digit>J</check-digit>
<desc-riv>CAMPOLONGO FLAVIO</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>7.472,82 </forniture>
<addebiti/>
<rese>443,84 </rese>
<accrediti/>
<saldo-contabile/>
<saldo-ec>7.028,98 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>5</cod-riv>
<check-digit>K</check-digit>
<desc-riv>LA COMETA S.N.C.</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>877,32 </forniture>
<addebiti/>
<rese>29,48 </rese>
<accrediti/>
<saldo-contabile>302,40 </saldo-contabile>
<saldo-ec>847,84 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>68</cod-riv>
<check-digit>V</check-digit>
<desc-riv>BENINI DAVIDE</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>1.073,16 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile>1.507,56 </saldo-contabile>
<saldo-ec>1.073,16 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>101</cod-riv>
<check-digit>C</check-digit>
<desc-riv>AMBROSI CARLA</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>1.127,34 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile>1.276,80 </saldo-contabile>
<saldo-ec>1.127,34 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>110</cod-riv>
<check-digit>L</check-digit>
<desc-riv>JANA HAVRLANTOVA</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>579,06 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile/>
<saldo-ec>579,06 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>228</cod-riv>
<check-digit>Z</check-digit>
<desc-riv>PIZZINI ARTURO</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>985,50 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile/>
<saldo-ec>985,50 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>252</cod-riv>
<check-digit>X</check-digit>
<desc-riv>PERINA ROBERTO</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>5.099,76 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile>1.347,36 </saldo-contabile>
<saldo-ec>5.099,76 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>279</cod-riv>
<check-digit>Y</check-digit>
<desc-riv>FASOLI GIUSEPPE</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>611,10 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile/>
<saldo-ec>611,10 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>256</cod-riv>
<check-digit>B</check-digit>
<desc-riv>MIGLIORINI VITTORINA</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>1.077,66 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile/>
<saldo-ec>1.077,66 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>309</cod-riv>
<check-digit>C</check-digit>
<desc-riv>CASTIONI SERGIO</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>8.302,44 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile>447,30 </saldo-contabile>
<saldo-ec>8.302,44 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>310</cod-riv>
<check-digit>D</check-digit>
<desc-riv>EDICOLA MANCALACQUA SNC</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>716,40 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile/>
<saldo-ec>716,40 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>332</cod-riv>
<check-digit>Z</check-digit>
<desc-riv>VILLABONI ANNA MARIA</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>571,68 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile/>
<saldo-ec>571,68 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>376</cod-riv>
<check-digit>R</check-digit>
<desc-riv>ZARAMELLA NADIA</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>581,94 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile/>
<saldo-ec>581,94 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>404</cod-riv>
<check-digit>T</check-digit>
<desc-riv>CASTIONI GIORGIO</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>1.508,94 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile/>
<saldo-ec>1.508,94 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>405</cod-riv>
<check-digit>U</check-digit>
<desc-riv>CARTOLERIA AMBROSI DANIEL</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>1.029,42 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile/>
<saldo-ec>1.029,42 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>395</cod-riv>
<check-digit>K</check-digit>
<desc-riv>EDERLE MIRELLA</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>304,20 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile>178,80 </saldo-contabile>
<saldo-ec>304,20 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>486</cod-riv>
<check-digit>X</check-digit>
<desc-riv>RAGUSO ANTONIO</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>545,40 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile/>
<saldo-ec>545,40 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>558</cod-riv>
<check-digit>R</check-digit>
<desc-riv>TROIANI SAS</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>3.741,66 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile/>
<saldo-ec>3.741,66 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>514</cod-riv>
<check-digit>Z</check-digit>
<desc-riv>IL PUNTO DI COPPINI M.</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>959,22 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile>1.194,48 </saldo-contabile>
<saldo-ec>959,22 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>515</cod-riv>
<check-digit>A</check-digit>
<desc-riv>GIOACHINI LAURA</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>5.450,30 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile/>
<saldo-ec>5.450,30 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>624</cod-riv>
<check-digit>F</check-digit>
<desc-riv>GDO PRESS S.R.L.</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>190,08 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile/>
<saldo-ec>190,08 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>700</cod-riv>
<check-digit>D</check-digit>
<desc-riv>MACH 2 AUTOGR.SCAL.NORD</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>1.118,52 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile/>
<saldo-ec>1.118,52 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>701</cod-riv>
<check-digit>E</check-digit>
<desc-riv>MACH 2 AUTOGR.SCAL.SUD</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>1.118,52 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile/>
<saldo-ec>1.118,52 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>1</giro>
<cod-riv>814</cod-riv>
<check-digit>N</check-digit>
<desc-riv>MACH DUE C/O IL SOLE SOMM</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>785,16 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile/>
<saldo-ec>785,16 </saldo-ec>
</dettaglio>
<dettaglio>
<giro>2</giro>
<cod-riv>259</cod-riv>
<check-digit>E</check-digit>
<desc-riv>EL GIORNALAR</desc-riv>
<riporto/>
<versamenti-acconti/>
<riporto/>
<forniture>1.051,20 </forniture>
<addebiti/>
<rese/>
<accrediti/>
<saldo-contabile/>
<saldo-ec>1.051,20 </saldo-ec>
</dettaglio>
</dettagli>
SubReport data:
<totali>
<totale giro="1">
<tot-cau>
<cod-cau-tot>5</cod-cau-tot>
<tipo-cau-tot>10</tipo-cau-tot>
<desc-cau-tot>Resa Periodici Esteri</desc-cau-tot>
<importo-cau>9,74 </importo-cau>
</tot-cau>
<tot-cau>
<cod-cau-tot>201</cod-cau-tot>
<tipo-cau-tot>1</tipo-cau-tot>
<desc-cau-tot>NS.FATTURA 20%</desc-cau-tot>
<importo-cau>6.254,70 </importo-cau>
</tot-cau>
<tot-cau>
<cod-cau-tot>52</cod-cau-tot>
<tipo-cau-tot>10</tipo-cau-tot>
<desc-cau-tot>Fornitura Periodici esteri</desc-cau-tot>
<importo-cau>15,10-</importo-cau>
</tot-cau>
<tot-cau>
<cod-cau-tot>11</cod-cau-tot>
<tipo-cau-tot>10</tipo-cau-tot>
<desc-cau-tot>RESA X CESS.ATTIVITA'</desc-cau-tot>
<importo-cau>79,18 </importo-cau>
</tot-cau>
<tot-cau>
<cod-cau-tot>38</cod-cau-tot>
<tipo-cau-tot>10</tipo-cau-tot>
<desc-cau-tot>Diff. resa quotidiani</desc-cau-tot>
<importo-cau>169,32 </importo-cau>
</tot-cau>
<tot-cau>
<cod-cau-tot>76</cod-cau-tot>
<tipo-cau-tot>10</tipo-cau-tot>
<desc-cau-tot>Add.lavorazione extra</desc-cau-tot>
<importo-cau>0,00 </importo-cau>
</tot-cau>
<tot-cau>
<cod-cau-tot>54</cod-cau-tot>
<tipo-cau-tot>10</tipo-cau-tot>
<desc-cau-tot>Fornitura Quot./Illus.</desc-cau-tot>
<importo-cau>30,54 </importo-cau>
</tot-cau>
<tot-cau>
<cod-cau-tot>2</cod-cau-tot>
<tipo-cau-tot>10</tipo-cau-tot>
<desc-cau-tot>Resa Quotidiani</desc-cau-tot>
<importo-cau>28,26 </importo-cau>
</tot-cau>
<tot-cau>
<cod-cau-tot>1</cod-cau-tot>
<tipo-cau-tot>10</tipo-cau-tot>
<desc-cau-tot>Versamento</desc-cau-tot>
<importo-cau>23.319,64 </importo-cau>
</tot-cau>
<tot-cau>
<cod-cau-tot>8</cod-cau-tot>
<tipo-cau-tot>10</tipo-cau-tot>
<desc-cau-tot>Integrazione resa periodici</desc-cau-tot>
<importo-cau>210,16 </importo-cau>
</tot-cau>
<tot-cau>
<cod-cau-tot>3</cod-cau-tot>
<tipo-cau-tot>10</tipo-cau-tot>
<desc-cau-tot>Resa PERIODICI</desc-cau-tot>
<importo-cau>353,72 </importo-cau>
</tot-cau>
<tot-cau>
<cod-cau-tot>46</cod-cau-tot>
<tipo-cau-tot>10</tipo-cau-tot>
<desc-cau-tot>Versamento RID</desc-cau-tot>
<importo-cau>19.439,04 </importo-cau>
</tot-cau>
<tot-cau>
<cod-cau-tot>4</cod-cau-tot>
<tipo-cau-tot>10</tipo-cau-tot>
<desc-cau-tot>Resa Periodici esteri</desc-cau-tot>
<importo-cau>332,32 </importo-cau>
</tot-cau>
<tot-cau>
<cod-cau-tot>41</cod-cau-tot>
<tipo-cau-tot>10</tipo-cau-tot>
<desc-cau-tot>ACCREDITO RESA FUORI BOLLA</desc-cau-tot>
<importo-cau>3,00 </importo-cau>
</tot-cau>
<tot-cau>
<cod-cau-tot>51</cod-cau-tot>
<tipo-cau-tot>10</tipo-cau-tot>
<desc-cau-tot>Fornitura PERIODICI</desc-cau-tot>
<importo-cau>26.464,00 </importo-cau>
</tot-cau>
<tot-cau>
<cod-cau-tot>108</cod-cau-tot>
<tipo-cau-tot>10</tipo-cau-tot>
<desc-cau-tot>Insoluto RID</desc-cau-tot>
<importo-cau>200,00 </importo-cau>
</tot-cau>
<tot-cau>
<cod-cau-tot>50</cod-cau-tot>
<tipo-cau-tot>10</tipo-cau-tot>
<desc-cau-tot>Fornitura Quotidiani</desc-cau-tot>
<importo-cau>90,10 </importo-cau>
</tot-cau>
<tot-cau>
<cod-cau-tot>86</cod-cau-tot>
<tipo-cau-tot>10</tipo-cau-tot>
<desc-cau-tot>ADDEBITO CONTO DEPOSITO</desc-cau-tot>
<importo-cau>21.205,66 </importo-cau>
</tot-cau>
</totale>
<totale giro="2">
<tot-cau>
<cod-cau-tot>201</cod-cau-tot>
<tipo-cau-tot>1</tipo-cau-tot>
<desc-cau-tot>NS.FATTURA 20%</desc-cau-tot>
<importo-cau>2.539,80 </importo-cau>
</tot-cau>
<tot-cau>
<cod-cau-tot>51</cod-cau-tot>
<tipo-cau-tot>10</tipo-cau-tot>
<desc-cau-tot>Fornitura PERIODICI</desc-cau-tot>
<importo-cau>27.180,72 </importo-cau>
</tot-cau>
<tot-cau>
<cod-cau-tot>1</cod-cau-tot>
<tipo-cau-tot>10</tipo-cau-tot>
<desc-cau-tot>Versamento</desc-cau-tot>
<importo-cau>7.196,26 </importo-cau>
</tot-cau>
</totale>
</totali>
I see thath if i put subreport in the summary it works, so is a problem of the group footer, any idea?
I try to debug Jasperreport library, and i see when xPathExecuter.selectNodeList(document,selectExpression) is called
it return the right number of node but the first node in the list is not the first node in the xml file thath rappresent the xPath expression.
How i can get the nodes in the right order?

Related

UPDATED - How do I get an avg in a range of year

I have 2 tables attendance and people.
I need to get the AVG of attendance by range of year.
To do that I need get the column people.DT_NASCIMENTO_FUNDACAO (DATE) and attendance.DT_SOLICITACAO_ATENDIMENTO (DATE).
The result this query should be something like:
-------------------------
| 0 - 18 | 19 - 23| ... |
-------------------------
| 0.2 | 0.8 | ... |
-------------------------
where 0.2 and 0.8 is a decimal representation of fraction of attendance by range of year.
people have CD_PESSOA PK and attendance have NU_USUARIO LIKE FK.
______ ____________
|PEOPLE| 1 ------------------> N | ATTENDANCE |
------- ------------
I created a code that count the numbers of time that a range of year happen:
SELECT
SUM(CASE
WHEN EXTRACT(YEAR FROM TO_DATE(P.DT_NASCIMENTO_FUNDACAO))
BETWEEN EXTRACT(YEAR FROM TO_DATE(G.DT_SOLICITACAO_ATENDIMENTO)) - 18
AND EXTRACT(YEAR FROM TO_DATE(G.DT_SOLICITACAO_ATENDIMENTO))
THEN 1 ELSE 0 END) AS "0 - 18",
SUM(CASE
WHEN EXTRACT(YEAR FROM TO_DATE(P.DT_NASCIMENTO_FUNDACAO))
BETWEEN EXTRACT(YEAR FROM TO_DATE(G.DT_SOLICITACAO_ATENDIMENTO)) - 23
AND EXTRACT(YEAR FROM TO_DATE(G.DT_SOLICITACAO_ATENDIMENTO)) - 19
THEN 1 ELSE 0 END) AS "19 - 23"
FROM ATTENDANCE G JOIN PEOPLE P
ON (G.NU_USUARIO = P.CD_PESSOA)
WHERE EXTRACT(YEAR FROM TO_DATE(G.DT_SOLICITACAO_ATENDIMENTO)) >= EXTRACT(YEAR FROM SYSDATE) - 1
AND EXTRACT(YEAR FROM TO_DATE(G.DT_SOLICITACAO_ATENDIMENTO)) <= EXTRACT(YEAR FROM SYSDATE);
As result I have:
Now, I need change this result to show me the percentual representation. How can I do that?
Here in this link I crate the sql file to create the tables and insert sample data(50 people and 2000 attendances).
Here we have some 50 sample data about born and 1000 attendance date.
people.DT_NASCIMENTO_FUNDACAO
01-07-2010
15-09-2014
10-07-1970
26-01-1989
02-05-1982
09-05-2009
25-08-2006
02-12-2013
08-04-2008
11-01-1962
01-05-1980
11-11-1993
15-07-2013
03-03-1990
09-10-2013
31-12-2008
25-07-2015
16-06-1972
03-11-1985
03-11-2006
19-03-1955
03-01-1974
08-01-2015
13-11-2003
07-01-1989
22-01-2007
30-11-1999
04-12-1970
24-05-1983
25-04-2012
11-11-1988
16-09-1980
21-05-1989
01-06-2011
14-09-1973
16-10-2015
10-02-2000
30-10-2004
27-02-1965
30-01-2015
23-05-1993
07-01-1987
04-03-1998
22-10-2011
17-12-1999
19-02-1955
21-07-1961
attendance.DT_SOLICITACAO_ATENDIMENTO
18-09-2020
21-09-2020
18-09-2020
18-09-2020
18-09-2020
18-09-2020
30-09-2020
30-09-2020
30-09-2020
14-09-2020
23-09-2020
18-09-2020
18-09-2020
18-09-2020
18-09-2020
08-09-2020
08-09-2020
08-09-2020
08-09-2020
08-09-2020
08-09-2020
08-09-2020
08-09-2020
18-09-2020
21-09-2020
21-09-2020
04-09-2020
04-09-2020
04-09-2020
04-09-2020
04-09-2020
08-09-2020
08-09-2020
08-09-2020
09-09-2020
25-08-2020
25-08-2020
25-08-2020
25-08-2020
01-09-2020
01-09-2020
01-09-2020
01-09-2020
01-09-2020
01-09-2020
01-09-2020
01-09-2020
01-09-2020
08-09-2020
17-09-2020
08-09-2020
08-09-2020
08-09-2020
17-09-2020
08-09-2020
08-09-2020
08-09-2020
08-09-2020
08-09-2020
08-09-2020
08-09-2020
08-09-2020
08-09-2020
08-09-2020
08-09-2020
21-09-2020
13-10-2020
04-09-2020
18-09-2020
18-09-2020
18-09-2020
18-09-2020
18-09-2020
18-09-2020
18-09-2020
18-09-2020
18-09-2020
18-09-2020
21-09-2020
21-09-2020
21-09-2020
18-09-2020
23-09-2020
18-09-2020
23-09-2020
18-09-2020
18-09-2020
18-09-2020
18-09-2020
18-09-2020
21-09-2020
21-09-2020
28-09-2020
28-09-2020
28-09-2020
28-09-2020
28-09-2020
28-09-2020
28-09-2020
29-09-2020
28-09-2020
28-09-2020
28-09-2020
28-09-2020
28-09-2020
28-09-2020
28-09-2020
28-09-2020
28-09-2020
28-09-2020
28-09-2020
28-09-2020
25-09-2020
25-09-2020
25-09-2020
25-09-2020
28-09-2020
24-09-2020
16-09-2020
16-09-2020
16-09-2020
16-09-2020
16-09-2020
16-09-2020
16-09-2020
16-09-2020
16-09-2020
16-09-2020
16-09-2020
16-09-2020
16-09-2020
16-09-2020
16-09-2020
16-09-2020
18-09-2020
03-08-2019
03-08-2019
03-08-2019
03-08-2019
02-08-2019
02-08-2019
02-08-2019
02-08-2019
09-08-2019
09-08-2019
09-08-2019
09-08-2019
09-08-2019
09-08-2019
09-08-2019
09-08-2019
09-08-2019
09-08-2019
09-08-2019
09-08-2019
09-08-2019
09-08-2019
09-08-2019
09-08-2019
09-08-2019
22-08-2019
22-08-2019
22-08-2019
22-08-2019
22-08-2019
22-08-2019
22-08-2019
22-08-2019
22-08-2019
22-08-2019
22-08-2019
22-08-2019
22-08-2019
22-08-2019
23-08-2019
23-08-2019
23-08-2019
23-08-2019
23-08-2019
23-08-2019
23-08-2019
23-08-2019
23-08-2019
23-08-2019
23-08-2019
23-08-2019
23-08-2019
23-08-2019
23-08-2019
23-08-2019
30-08-2019
30-08-2019
30-08-2019
30-08-2019
30-08-2019
30-08-2019
30-08-2019
30-08-2019
30-08-2019
30-08-2019
30-08-2019
30-08-2019
30-08-2019
30-08-2019
30-08-2019
30-08-2019
30-08-2019
30-08-2019
30-08-2019
30-08-2019
30-08-2019
30-08-2019
30-08-2019
27-08-2019
27-08-2019
27-08-2019
27-08-2019
27-08-2019
27-08-2019
27-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
27-08-2019
27-08-2019
27-08-2019
27-08-2019
27-08-2019
27-08-2019
27-08-2019
27-08-2019
27-08-2019
27-08-2019
27-08-2019
27-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
21-08-2019
09-08-2019
06-08-2019
17-07-2019
17-10-2020
17-10-2020
18-10-2020
19-10-2020
19-10-2020
19-10-2020
19-10-2020
19-10-2020
31-10-2020
31-10-2020
31-10-2020
31-10-2020
31-10-2020
31-10-2020
31-10-2020
31-10-2020
24-10-2020
24-10-2020
24-10-2020
24-10-2020
24-10-2020
24-10-2020
24-10-2020
24-10-2020
24-10-2020
24-10-2020
24-10-2020
24-10-2020
26-10-2020
26-10-2020
26-10-2020
26-10-2020
26-10-2020
26-10-2020
26-10-2020
26-10-2020
26-10-2020
26-10-2020
29-10-2020
29-10-2020
26-10-2020
26-10-2020
26-10-2020
26-10-2020
28-10-2020
28-10-2020
10-10-2020
10-10-2020
10-10-2020
10-10-2020
08-10-2020
08-10-2020
08-10-2020
08-10-2020
11-10-2020
11-10-2020
13-10-2020
13-10-2020
14-10-2020
14-10-2020
17-10-2020
17-10-2020
17-10-2020
16-10-2020
18-10-2020
18-10-2020
04-10-2020
04-10-2020
13-10-2020
13-10-2020
13-10-2020
09-10-2020
13-10-2020
09-10-2020
14-10-2020
14-10-2020
01-10-2020
01-10-2020
01-10-2020
01-10-2020
01-10-2020
01-10-2020
01-10-2020
01-10-2020
01-10-2020
01-10-2020
01-10-2020
01-10-2020
01-10-2020
01-10-2020
01-10-2020
01-10-2020
01-10-2020
01-10-2020
01-10-2020
01-10-2020
01-10-2020
01-10-2020
26-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
27-10-2020
07-10-2020
12-10-2020
10-10-2020
16-10-2020
16-10-2020
15-10-2020
10-09-2020
10-09-2020
10-09-2020
09-03-2020
09-03-2020
11-09-2020
11-09-2020
11-09-2020
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
19-06-2019
19-06-2019
19-06-2019
19-06-2019
19-06-2019
19-06-2019
19-06-2019
19-06-2019
19-06-2019
20-06-2019
20-06-2019
20-06-2019
20-06-2019
20-06-2019
20-06-2019
28-06-2019
28-06-2019
28-06-2019
28-06-2019
28-06-2019
28-06-2019
28-06-2019
28-06-2019
28-06-2019
28-06-2019
28-06-2019
28-06-2019
28-06-2019
28-06-2019
28-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
03-06-2019
03-06-2019
26-06-2019
26-06-2019
26-06-2019
26-06-2019
26-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
27-06-2019
14-06-2019
14-06-2019
29-06-2019
29-06-2019
29-06-2019
29-06-2019
29-06-2019
29-06-2019
29-06-2019
29-06-2019
29-06-2019
29-06-2019
29-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
30-06-2019
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
21-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
11-08-2021
11-08-2021
11-08-2021
11-08-2021
11-08-2021
11-08-2021
11-08-2021
11-08-2021
11-08-2021
11-08-2021
11-08-2021
11-08-2021
12-08-2021
12-08-2021
12-08-2021
12-08-2021
12-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
18-08-2021
18-08-2021
20-08-2021
20-08-2021
20-08-2021
20-08-2021
20-08-2021
20-08-2021
20-08-2021
20-08-2021
20-08-2021
20-08-2021
20-08-2021
20-08-2021
20-08-2021
20-08-2021
20-08-2021
20-08-2021
20-08-2021
20-08-2021
19-08-2021
19-08-2021
19-08-2021
18-08-2021
18-08-2021
18-08-2021
18-08-2021
18-08-2021
18-08-2021
18-08-2021
18-08-2021
18-08-2021
18-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
19-08-2021
30-11-2019
30-11-2019
30-11-2019
30-11-2019
30-11-2019
30-11-2019
11-11-2019
30-11-2019
27-11-2019
06-11-2019
06-11-2019
06-11-2019
06-11-2019
06-11-2019
06-11-2019
06-11-2019
07-11-2019
07-11-2019
07-11-2019
07-11-2019
07-11-2019
07-11-2019
07-11-2019
08-11-2019
08-11-2019
08-11-2019
08-11-2019
08-11-2019
08-11-2019
08-11-2019
08-11-2019
08-11-2019
11-11-2019
11-11-2019
12-11-2019
12-11-2019
12-11-2019
12-11-2019
30-10-2019
07-11-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
10-12-2019
28-11-2019
28-11-2019
28-11-2019
28-11-2019
28-11-2019
28-11-2019
28-11-2019
04-11-2019
04-11-2019
04-11-2019
04-11-2019
04-11-2019
25-11-2019
25-11-2019
25-11-2019
25-11-2019
25-11-2019
25-11-2019
25-11-2019
25-11-2019
26-11-2019
27-11-2019
27-11-2019
27-11-2019
27-11-2019
27-11-2019
27-11-2019
27-11-2019
27-11-2019
27-11-2019
27-11-2019
27-11-2019
27-11-2019
27-11-2019
27-11-2019
27-11-2019
28-11-2019
03-12-2019
06-11-2019
07-11-2019
07-11-2019
12-11-2019
26-11-2019
28-11-2019
11-11-2019
12-11-2019
12-11-2019
25-11-2019
02-12-2019
13-11-2019
28-11-2019
07-11-2019
07-11-2019
07-11-2019
01-11-2019
01-11-2019
01-11-2019
01-11-2019
01-11-2019
01-11-2019
04-11-2019
04-11-2019
07-11-2019
07-11-2019
25-11-2019
14-03-2019
14-03-2019
20-03-2019
20-03-2019
20-03-2019
20-03-2019
20-03-2019
20-03-2019
20-03-2019
20-03-2019
20-03-2019
18-03-2019
14-03-2019
14-03-2019
14-03-2019
14-03-2019
14-03-2019
14-03-2019
14-03-2019
18-03-2019
18-03-2019
18-03-2019
18-03-2019
14-03-2019
15-03-2019
15-03-2019
15-03-2019
15-03-2019
15-03-2019
15-03-2019
15-03-2019
15-03-2019
15-03-2019
15-03-2019
15-03-2019
15-03-2019
15-03-2019
15-03-2019
15-03-2019
15-03-2019
18-03-2019
01-03-2019
01-03-2019
01-03-2019
07-03-2019
07-03-2019
07-03-2019
07-03-2019
07-03-2019
07-03-2019
18-03-2019
18-03-2019
18-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
22-03-2019
14-03-2019
14-03-2019
14-03-2019
14-03-2019
14-03-2019
19-03-2019
15-01-2019
05-02-2019
20-03-2019
27-12-2018
13-02-2019
13-02-2019
13-02-2019
13-02-2019
29-01-2019
13-11-2018
22-03-2019
12-03-2019
13-02-2019
13-02-2019
17-01-2019
25-03-2019
21-03-2019
21-02-2019
26-03-2019
22-02-2019
22-02-2019
22-02-2019
22-02-2019
07-03-2019
07-03-2019
07-03-2019
07-03-2019
07-03-2019
25-03-2019
07-02-2019
07-02-2019
28-02-2019
28-02-2019
28-02-2019
28-02-2019
28-02-2019
28-02-2019
13-03-2019
13-03-2019
13-03-2019
13-03-2019
13-03-2019
13-03-2019
13-03-2019
13-03-2019
13-03-2019
13-03-2019
13-03-2019
13-03-2019
13-03-2019
13-03-2019
13-03-2019
13-03-2019
13-03-2019
05-07-2019
08-07-2019
08-07-2019
08-07-2019
08-07-2019
08-07-2019
08-07-2019
08-07-2019
08-07-2019
08-07-2019
08-07-2019
08-07-2019
08-07-2019
08-07-2019
08-07-2019
05-07-2019
05-07-2019
05-07-2019
05-07-2019
05-07-2019
05-07-2019
05-07-2019
05-07-2019
05-07-2019
05-07-2019
05-07-2019
11-07-2019
11-07-2019
12-07-2019
12-07-2019
12-07-2019
12-07-2019
12-07-2019
12-07-2019
12-07-2019
12-07-2019
12-07-2019
11-07-2019
11-07-2019
11-07-2019
09-07-2019
11-07-2019
11-07-2019
11-07-2019
11-07-2019
How can I do that?
To solve my problem was necessary a group operation on database, incluse to create 2 temporary tables.
The solution to my case was:
WITH TABLE_X AS (
SELECT P.CD_PESSOA, P.DT_NASCIMENTO_FUNDACAO, TO_DATE(SYSDATE) AS DATA_ATUAL, TO_DATE(G.DT_SOLICITACAO_ATENDIMENTO),
EXTRACT(YEAR FROM SYSDATE) - EXTRACT(YEAR FROM TO_DATE(P.DT_NASCIMENTO_FUNDACAO)) AS IDADE
FROM ATTENDANCE G JOIN PEOPLE P
ON (G.NU_USUARIO = P.CD_PESSOA)
WHERE EXTRACT(YEAR FROM TO_DATE(G.DT_SOLICITACAO_ATENDIMENTO)) >= EXTRACT(YEAR FROM SYSDATE) - 1
AND EXTRACT(YEAR FROM TO_DATE(G.DT_SOLICITACAO_ATENDIMENTO)) <= EXTRACT(YEAR FROM SYSDATE)
ORDER BY IDADE DESC
),
TABLE_Y AS (SELECT
SUM(CASE WHEN IDADE BETWEEN 0 AND 18 THEN 1 ELSE 0 END) AS "0-18",
SUM(CASE WHEN IDADE BETWEEN 19 AND 23 THEN 1 ELSE 0 END) AS "19-23",
SUM(CASE WHEN IDADE BETWEEN 24 AND 28 THEN 1 ELSE 0 END) AS "24-28",
SUM(CASE WHEN IDADE BETWEEN 29 AND 33 THEN 1 ELSE 0 END) AS "29-33",
SUM(CASE WHEN IDADE BETWEEN 34 AND 38 THEN 1 ELSE 0 END) AS "34-38",
SUM(CASE WHEN IDADE BETWEEN 39 AND 43 THEN 1 ELSE 0 END) AS "39-43",
SUM(CASE WHEN IDADE BETWEEN 44 AND 48 THEN 1 ELSE 0 END) AS "44-48",
SUM(CASE WHEN IDADE BETWEEN 49 AND 53 THEN 1 ELSE 0 END) AS "49-53",
SUM(CASE WHEN IDADE BETWEEN 54 AND 58 THEN 1 ELSE 0 END) AS "54-58",
SUM(CASE WHEN IDADE >= 59 THEN 1 ELSE 0 END) AS "59+",
SUM(CASE WHEN IDADE IS NULL THEN 1 ELSE 0 END) AS "VALORES_NULL",
COUNT(IDADE) AS TOTAL_IDADE
FROM TABLE_X
)
SELECT
ROUND(("0-18" / TOTAL_IDADE) * 100, 2) ||'%' AS "0-18",
ROUND(("19-23" / TOTAL_IDADE) * 100, 2) ||'%' AS "19-23",
ROUND(("24-28" / TOTAL_IDADE) * 100, 2) ||'%' AS "24-28",
ROUND(("29-33" / TOTAL_IDADE) * 100, 2) ||'%' AS "29-33",
ROUND(("34-38" / TOTAL_IDADE) * 100, 2) ||'%' AS "29-33",
ROUND(("39-43" / TOTAL_IDADE) * 100, 2) ||'%' AS "34-38",
ROUND(("44-48" / TOTAL_IDADE) * 100, 2) ||'%' AS "44-48",
ROUND(("49-53" / TOTAL_IDADE) * 100, 2) ||'%' AS "49-53",
ROUND(("54-58" / TOTAL_IDADE) * 100, 2) ||'%' AS "54-58",
ROUND(("59+" / TOTAL_IDADE) * 100, 2) ||'%' AS "59+"
FROM TABLE_Y
As result I had:

WordprocessingML parsing using XPath, XQuery or XPathNavigator

I am dealing with the word processing ML (Office Word file) using XPath expressions. Due to the nature of bookmarks placed in document, the starting of bookmark may be somewhere else and then the end. So they dont really follow any well formed XML hierarchy, so thats the challenge writing XPath expressions for such bookmarked content to read from document.xml file.
Can someone please help how to handle such unusual XML parsing using XPath? e.g. below table:
<w:p w:rsidR="003A3B76" w:rsidRDefault="003A3B76" w:rsidP="003A3B76">
<w:bookmarkStart w:id="3" w:name="Table3"/>
</w:p>
<w:tbl>
<w:tblPr>
<w:tblStyle w:val="TableGrid"/>
<w:tblW w:w="0" w:type="auto"/>
<w:tblLook w:val="04A0" w:firstRow="1" w:lastRow="0" w:firstColumn="1" w:lastColumn="0" w:noHBand="0" w:noVBand="1"/>
</w:tblPr>
<w:tblGrid>
<w:gridCol w:w="533"/>
<w:gridCol w:w="2148"/>
<w:gridCol w:w="986"/>
<w:gridCol w:w="865"/>
<w:gridCol w:w="4818"/>
</w:tblGrid>
<w:tr w:rsidR="003A3B76" w:rsidTr="005666D2">
<w:tc>
<w:tcPr>
<w:tcW w:w="533" w:type="dxa"/>
<w:shd w:val="clear" w:color="auto" w:fill="BFBFBF" w:themeFill="background1" w:themeFillShade="BF"/>
</w:tcPr>
<w:p w:rsidR="003A3B76" w:rsidRDefault="003A3B76" w:rsidP="005666D2">
<w:r>
<w:t>#</w:t>
</w:r>
</w:p>
</w:tc>
<w:tc>
<w:tcPr>
<w:tcW w:w="2148" w:type="dxa"/>
<w:shd w:val="clear" w:color="auto" w:fill="BFBFBF" w:themeFill="background1" w:themeFillShade="BF"/>
</w:tcPr>
<w:p w:rsidR="003A3B76" w:rsidRDefault="003A3B76" w:rsidP="005666D2">
<w:r>
<w:t>Name</w:t>
</w:r>
</w:p>
</w:tc>
<w:tc>
<w:tcPr>
<w:tcW w:w="986" w:type="dxa"/>
<w:shd w:val="clear" w:color="auto" w:fill="BFBFBF" w:themeFill="background1" w:themeFillShade="BF"/>
</w:tcPr>
<w:p w:rsidR="003A3B76" w:rsidRDefault="003A3B76" w:rsidP="005666D2">
<w:r>
<w:t>Age</w:t>
</w:r>
</w:p>
</w:tc>
<w:tc>
<w:tcPr>
<w:tcW w:w="865" w:type="dxa"/>
<w:shd w:val="clear" w:color="auto" w:fill="BFBFBF" w:themeFill="background1" w:themeFillShade="BF"/>
</w:tcPr>
<w:p w:rsidR="003A3B76" w:rsidRDefault="003A3B76" w:rsidP="005666D2">
<w:r>
<w:t>Weight</w:t>
</w:r>
</w:p>
</w:tc>
<w:tc>
<w:tcPr>
<w:tcW w:w="4818" w:type="dxa"/>
<w:shd w:val="clear" w:color="auto" w:fill="BFBFBF" w:themeFill="background1" w:themeFillShade="BF"/>
</w:tcPr>
<w:p w:rsidR="003A3B76" w:rsidRDefault="003A3B76" w:rsidP="005666D2">
<w:r>
<w:t>Will</w:t>
</w:r>
</w:p>
</w:tc>
</w:tr>
<w:tr w:rsidR="003A3B76" w:rsidTr="005666D2">
<w:tc>
<w:tcPr>
<w:tcW w:w="533" w:type="dxa"/>
</w:tcPr>
<w:p w:rsidR="003A3B76" w:rsidRDefault="003A3B76" w:rsidP="005666D2">
<w:r>
<w:t>2</w:t>
</w:r>
</w:p>
</w:tc>
<w:tc>
<w:tcPr>
<w:tcW w:w="2148" w:type="dxa"/>
</w:tcPr>
<w:p w:rsidR="003A3B76" w:rsidRDefault="003A3B76" w:rsidP="005666D2">
<w:r>
<w:t>Nagraj</w:t>
</w:r>
</w:p>
</w:tc>
<w:tc>
<w:tcPr>
<w:tcW w:w="986" w:type="dxa"/>
</w:tcPr>
<w:p w:rsidR="003A3B76" w:rsidRDefault="003A3B76" w:rsidP="005666D2">
<w:r>
<w:t>38</w:t>
</w:r>
</w:p>
</w:tc>
<w:tc>
<w:tcPr>
<w:tcW w:w="865" w:type="dxa"/>
</w:tcPr>
<w:p w:rsidR="003A3B76" w:rsidRDefault="003A3B76" w:rsidP="005666D2">
<w:r>
<w:t>150lb</w:t>
</w:r>
</w:p>
</w:tc>
<w:tc>
<w:tcPr>
<w:tcW w:w="4818" w:type="dxa"/>
</w:tcPr>
<w:p w:rsidR="003A3B76" w:rsidRDefault="003A3B76" w:rsidP="005666D2">
<w:r>
<w:t>Be real</w:t>
</w:r>
</w:p>
</w:tc>
</w:tr>
<w:bookmarkEnd w:id="3"/>
</w:tbl>
bookmarkEnd is ended here inside table, however not in <tr> or <tc>. and the bookmarkStart is started outside of table. That's the way scenario i have from my tagging. Please help with this. Writing a Xpath expression on this is getting complex, any help with XSLT is also welcome.

xsl:for-each-group positional grouping flat xml to hierarchical

I have a flat xml file that needs to be converted to hierarchical. I used the nested grouping idea from here xsl:for-each-group help needed. It's working for the most part except for a couple of issues:
1) The elements root1 and root2 are not showing up.
2) The location of element NFActy is incorrect. The first NFActy should be between the 2 Rot elements.
3) The Duty & NFActy elements are treated as one group for calculating the SequenceCount.
4) For Leg elements each set of Leg elements within one duty should be grouped for SequenceCount for leg elements.
Any help is really appreciated.
Thanks.
Input XML
<root>
<root1>1234</root1>
<root2>5678</root2>
<Schedule>
<a>line 1</a>
<b>line 2</b>
<c>line 3</c>
</Schedule>
<Rot>
<d>line 4</d>
<e>line 5</e>
<f>line 6</f>
<g>line 7</g>
</Rot>
<Duty>
<h>line 8</h>
<i>line 9</i>
<j>line 10</j>
<k>line 11</k>
<l>line 12</l>
</Duty>
<Leg>
<m>line 13</m>
<n>line 14</n>
<o>line 15</o>
</Leg>
<Leg>
<m>line 13</m>
<n>line 14</n>
<o>line 15</o>
</Leg>
<NFActy>
<d>line 214</d>
<e>line 215</e>
<f>line 216</f>
<g>line 217</g>
</NFActy>
<Rot>
<d>line 19</d>
<e>line 20</e>
<f>line 21</f>
<g>line 22</g>
</Rot>
<Duty>
<h>line 23</h>
<i>line 24</i>
<j>line 25</j>
<k>line 26</k>
<l>line 27</l>
</Duty>
<Leg>
<m>line 28</m>
<n>line 29</n>
<o>line 30</o>
</Leg>
<Leg>
<m>line 13</m>
<n>line 14</n>
<o>line 15</o>
</Leg>
<NFActy>
<d>line 224</d>
<e>line 225</e>
<f>line 226</f>
<g>line 227</g>
</NFActy>
Desired Output XML
<root>
<root1>1234</root1>
<root2>5678</root2>
<Schedule>
<a>line 1</a>
<b>line 2</b>
<c>line 3</c>
<Rot>
<d>line 4</d>
<e>line 5</e>
<f>line 6</f>
<g>line 7</g>
<Duty>
<SequenceCount>1</SequenceCount>
<h>line 8</h>
<i>line 9</i>
<j>line 10</j>
<k>line 11</k>
<l>line 12</l>
<Leg>
<SequenceCount>1</SequenceCount>
<m>line 13</m>
<n>line 14</n>
<o>line 15</o>
</Leg>
<Leg>
<SequenceCount>2</SequenceCount>
<m>line 13</m>
<n>line 14</n>
<o>line 15</o>
</Leg>
</Duty>
</Rot>
<NFActy>
<SequenceCount>2</SequenceCount>
<d>line 214</d>
<e>line 215</e>
<f>line 216</f>
<g>line 217</g>
</NFActy>
<Rot>
<d>line 19</d>
<e>line 20</e>
<f>line 21</f>
<g>line 22</g>
<Duty>
<SequenceCount>3</SequenceCount>
<h>line 23</h>
<i>line 24</i>
<j>line 25</j>
<k>line 26</k>
<l>line 27</l>
<Leg>
<SequenceCount>1</SequenceCount>
<m>line 28</m>
<n>line 29</n>
<o>line 30</o>
</Leg>
<Leg>
<SequenceCount>2</SequenceCount>
<m>line 13</m>
<n>line 14</n>
<o>line 15</o>
/Leg>
</Duty>
</Rot>
<NFActy>
<SequenceCount>4</SequenceCount>
<d>line 224</d>
<e>line 225</e>
<f>line 226</f>
<g>line 227</g>
</NFActy>
</Schedule>
My XSL
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:fn="fn" xmlns:xs="http://www.w3.org/2001/XMLSchema" version="2.0"
exclude-result-prefixes="xs fn">
<xsl:output indent="yes" />
<xsl:template match="/">
<xsl:for-each-group select="*" group-starting-with="root">
<root>
<xsl:for-each-group select="*" group-starting-with="*[name(.)='Schedule']">
<xsl:choose>
<xsl:when test="name(.)='Schedule'">
<Schedule>
<xsl:apply-templates />
<xsl:for-each-group select="current-group()" group-starting-with="*[name(.)='Rot']">
<xsl:choose>
<xsl:when test="name(.)='Rot'">
<Rot>
<xsl:apply-templates />
<xsl:for-each-group select="current-group()" group-starting-with="*[name(.)='Duty']">
<xsl:choose>
<xsl:when test="name(.)='Duty'">
<Duty>
<xsl:element name="SequenceCount"><xsl:number count="Duty|NFActy" level="any"/></xsl:element>
<xsl:apply-templates />
<xsl:for-each-group select="current-group()" group-starting-with="*[name(.)='Leg']">
<xsl:choose>
<xsl:when test="name(.)='Leg'">
<Leg>
<xsl:element name="SequenceCount"><xsl:number value="position() - 1"/></xsl:element>
<xsl:apply-templates />
</Leg>
</xsl:when>
</xsl:choose>
</xsl:for-each-group>
</Duty>
</xsl:when>
</xsl:choose>
</xsl:for-each-group>
</Rot>
</xsl:when>
</xsl:choose>
</xsl:for-each-group>
<xsl:for-each-group select="current-group()" group-starting-with="*[name(.)='NFActy']">
<xsl:choose>
<xsl:when test="name(.)='NFActy'">
<NFActy>
<xsl:element name="SequenceCount"><xsl:number count="Duty|NFActy" level="any"/></xsl:element>
<xsl:apply-templates />
</NFActy>
</xsl:when>
</xsl:choose>
</xsl:for-each-group>
</Schedule>
</xsl:when>
</xsl:choose>
</xsl:for-each-group>
</root>
</xsl:for-each-group>
</xsl:template>
<xsl:template match="node()">
<xsl:copy>
<xsl:apply-templates select="node()" />
</xsl:copy>
</xsl:template>
</xsl:stylesheet>
Here is my edit of your code, you need to make sure you process all elements at the same time and not as you had with sequential for-each-group.
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:xs="http://www.w3.org/2001/XMLSchema" version="2.0"
exclude-result-prefixes="xs">
<xsl:output indent="yes" />
<xsl:template match="root">
<xsl:copy>
<xsl:for-each-group select="*" group-starting-with="Schedule">
<xsl:choose>
<xsl:when test="self::Schedule">
<Schedule>
<xsl:apply-templates />
<xsl:for-each-group select="current-group() except ." group-starting-with="Rot | NFActy">
<xsl:choose>
<xsl:when test="self::Rot | self::NFActy">
<xsl:copy>
<xsl:if test="self::NFActy">
<SequenceCount><xsl:number count="Duty | NFActy" level="any"/></SequenceCount>
</xsl:if>
<xsl:apply-templates />
<xsl:for-each-group select="current-group() except ." group-starting-with="Duty">
<xsl:choose>
<xsl:when test="self::Duty">
<xsl:copy>
<SequenceCount><xsl:number count="Duty | NFActy" level="any"/></SequenceCount>
<xsl:apply-templates />
<xsl:for-each-group select="current-group() except ." group-starting-with="Leg">
<xsl:choose>
<xsl:when test="self::Leg">
<Leg>
<SequenceCount><xsl:number value="position()"/></SequenceCount>
<xsl:apply-templates />
</Leg>
</xsl:when>
</xsl:choose>
</xsl:for-each-group>
</xsl:copy>
</xsl:when>
</xsl:choose>
</xsl:for-each-group>
</xsl:copy>
</xsl:when>
</xsl:choose>
</xsl:for-each-group>
</Schedule>
</xsl:when>
<xsl:otherwise>
<xsl:apply-templates select="current-group()"/>
</xsl:otherwise>
</xsl:choose>
</xsl:for-each-group>
</xsl:copy>
</xsl:template>
<xsl:template match="node()">
<xsl:copy>
<xsl:apply-templates select="node()" />
</xsl:copy>
</xsl:template>
</xsl:stylesheet>
When I apply above stylesheet with Saxon 9.5 to the input
<root>
<root1>1234</root1>
<root2>5678</root2>
<Schedule>
<a>line 1</a>
<b>line 2</b>
<c>line 3</c>
</Schedule>
<Rot>
<d>line 4</d>
<e>line 5</e>
<f>line 6</f>
<g>line 7</g>
</Rot>
<Duty>
<h>line 8</h>
<i>line 9</i>
<j>line 10</j>
<k>line 11</k>
<l>line 12</l>
</Duty>
<Leg>
<m>line 13</m>
<n>line 14</n>
<o>line 15</o>
</Leg>
<Leg>
<m>line 13</m>
<n>line 14</n>
<o>line 15</o>
</Leg>
<NFActy>
<d>line 214</d>
<e>line 215</e>
<f>line 216</f>
<g>line 217</g>
</NFActy>
<Rot>
<d>line 19</d>
<e>line 20</e>
<f>line 21</f>
<g>line 22</g>
</Rot>
<Duty>
<h>line 23</h>
<i>line 24</i>
<j>line 25</j>
<k>line 26</k>
<l>line 27</l>
</Duty>
<Leg>
<m>line 28</m>
<n>line 29</n>
<o>line 30</o>
</Leg>
<Leg>
<m>line 13</m>
<n>line 14</n>
<o>line 15</o>
</Leg>
<NFActy>
<d>line 224</d>
<e>line 225</e>
<f>line 226</f>
<g>line 227</g>
</NFActy>
</root>
I get the result
<root>
<root1>1234</root1>
<root2>5678</root2>
<Schedule>
<a>line 1</a>
<b>line 2</b>
<c>line 3</c>
<Rot>
<d>line 4</d>
<e>line 5</e>
<f>line 6</f>
<g>line 7</g>
<Duty>
<SequenceCount>1</SequenceCount>
<h>line 8</h>
<i>line 9</i>
<j>line 10</j>
<k>line 11</k>
<l>line 12</l>
<Leg>
<SequenceCount>1</SequenceCount>
<m>line 13</m>
<n>line 14</n>
<o>line 15</o>
</Leg>
<Leg>
<SequenceCount>2</SequenceCount>
<m>line 13</m>
<n>line 14</n>
<o>line 15</o>
</Leg>
</Duty>
</Rot>
<NFActy>
<SequenceCount>2</SequenceCount>
<d>line 214</d>
<e>line 215</e>
<f>line 216</f>
<g>line 217</g>
</NFActy>
<Rot>
<d>line 19</d>
<e>line 20</e>
<f>line 21</f>
<g>line 22</g>
<Duty>
<SequenceCount>3</SequenceCount>
<h>line 23</h>
<i>line 24</i>
<j>line 25</j>
<k>line 26</k>
<l>line 27</l>
<Leg>
<SequenceCount>1</SequenceCount>
<m>line 28</m>
<n>line 29</n>
<o>line 30</o>
</Leg>
<Leg>
<SequenceCount>2</SequenceCount>
<m>line 13</m>
<n>line 14</n>
<o>line 15</o>
</Leg>
</Duty>
</Rot>
<NFActy>
<SequenceCount>4</SequenceCount>
<d>line 224</d>
<e>line 225</e>
<f>line 226</f>
<g>line 227</g>
</NFActy>
</Schedule>
</root>

Geoserver SLD styling issue with external graphics and attribute rules

I am creating a SLD for Geoserver wms layer. The SLD validates without error but the icons will not show in the map. I am using attribute based rules to compare strings to have the correct image show for the correct feature. Here is my code and thanks for any help!
<?xml version="1.0" encoding="ISO-8859-1"?>
<StyledLayerDescriptor version="1.0.0"
xsi:schemaLocation="http://www.opengis.net/sld StyledLayerDescriptor.xsd"
xmlns="http://www.opengis.net/sld"
xmlns:ogc="http://www.opengis.net/ogc"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<NamedLayer>
<Name>Upper Shore Image Points</Name>
<UserStyle>
<Title>Vendor Points</Title>
<FeatureTypeStyle>
<Rule>
<Name>Famers Market</Name>
<Title>All Farmers Markets</Title>
<ogc:Filter>
<ogc:PropertyIsLike wildCard="*" singleChar="." escape="!">
<ogc:PropertyName>type</ogc:PropertyName>
<ogc:Literal>farmers maket vendor</ogc:Literal>
</ogc:PropertyIsLike>
</ogc:Filter>
<PointSymbolizer>
<Graphic>
<ExternalGraphic>
<OnlineResource
xlink:type="simple"
xlink:href="Farmers Markets.jpg" />
<Format>image/jpeg</Format>
</ExternalGraphic>
<Size>32</Size>
</Graphic>
</PointSymbolizer>
</Rule>
<Rule>
<Name>Fruit and Vegetable</Name>
<Title>All Fruit and Vegetable</Title>
<ogc:Filter>
<ogc:PropertyIsLike wildCard="*" singleChar="." escape="!">
<ogc:PropertyName>type</ogc:PropertyName>
<ogc:Literal>Fruit and Vegetable Farm</ogc:Literal>
</ogc:PropertyIsLike>
</ogc:Filter>
<PointSymbolizer>
<Graphic>
<ExternalGraphic>
<OnlineResource
xlink:type="simple"
xlink:href="Fruit and Vegetable Farms.jpg" />
<Format>image/jpeg</Format>
</ExternalGraphic>
<Size>32</Size>
</Graphic>
</PointSymbolizer>
</Rule>
<Rule>
<Name>Horse Stable</Name>
<Title>All Horse Stables</Title>
<ogc:Filter>
<ogc:PropertyIsLike wildCard="*" singleChar="." escape="!">
<ogc:PropertyName>type</ogc:PropertyName>
<ogc:Literal>Horse Stable</ogc:Literal>
</ogc:PropertyIsLike>
</ogc:Filter>
<PointSymbolizer>
<Graphic>
<ExternalGraphic>
<OnlineResource
xlink:type="simple"
xlink:href="Horse Stable.jpg" />
<Format>image/jpeg</Format>
</ExternalGraphic>
<Size>32</Size>
</Graphic>
</PointSymbolizer>
</Rule>
<Rule>
<Name>Wool Products</Name>
<Title>All Wool Products</Title>
<ogc:Filter>
<ogc:PropertyIsLike wildCard="*" singleChar="." escape="!">
<ogc:PropertyName>type</ogc:PropertyName>
<ogc:Literal>Wool Products</ogc:Literal>
</ogc:PropertyIsLike>
</ogc:Filter>
<PointSymbolizer>
<Graphic>
<ExternalGraphic>
<OnlineResource
xlink:type="simple"
xlink:href="Wool Products.jpg" />
<Format>image/jpeg</Format>
</ExternalGraphic>
<Size>32</Size>
</Graphic>
</PointSymbolizer>
</Rule>
<Rule>
<Name>Restaurant</Name>
<Title>All Restaurants</Title>
<ogc:Filter>
<ogc:PropertyIsLike wildCard="*" singleChar="." escape="!">
<ogc:PropertyName>type</ogc:PropertyName>
<ogc:Literal>Restaurant</ogc:Literal>
</ogc:PropertyIsLike>
</ogc:Filter>
<PointSymbolizer>
<Graphic>
<ExternalGraphic>
<OnlineResource
xlink:type="simple"
xlink:href="Restaurant.jpg" />
<Format>image/jpeg</Format>
</ExternalGraphic>
<Size>32</Size>
</Graphic>
</PointSymbolizer>
</Rule>
<Rule>
<Name>Coffee Roasting</Name>
<Title>All Coffee Roasting</Title>
<ogc:Filter>
<ogc:PropertyIsLike wildCard="*" singleChar="." escape="!">
<ogc:PropertyName>type</ogc:PropertyName>
<ogc:Literal>Coffee Roasting</ogc:Literal>
</ogc:PropertyIsLike>
</ogc:Filter>
<PointSymbolizer>
<Graphic>
<ExternalGraphic>
<OnlineResource
xlink:type="simple"
xlink:href="Coffee Roasting.jpg" />
<Format>image/jpeg</Format>
</ExternalGraphic>
<Size>32</Size>
</Graphic>
</PointSymbolizer>
</Rule>
<Rule>
<Name>Charter Service</Name>
<Title>All Charter Services</Title>
<ogc:Filter>
<ogc:PropertyIsLike wildCard="*" singleChar="." escape="!">
<ogc:PropertyName>type</ogc:PropertyName>
<ogc:Literal>Charter Service</ogc:Literal>
</ogc:PropertyIsLike>
</ogc:Filter>
<PointSymbolizer>
<Graphic>
<ExternalGraphic>
<OnlineResource
xlink:type="simple"
xlink:href="Charter Service.jpg" />
<Format>image/jpeg</Format>
</ExternalGraphic>
<Size>32</Size>
</Graphic>
</PointSymbolizer>
</Rule>
<Rule>
<Name>Apiary</Name>
<Title>All Apiaries</Title>
<ogc:Filter>
<ogc:PropertyIsLike wildCard="*" singleChar="." escape="!">
<ogc:PropertyName>type</ogc:PropertyName>
<ogc:Literal>Apiary</ogc:Literal>
</ogc:PropertyIsLike>
</ogc:Filter>
<PointSymbolizer>
<Graphic>
<ExternalGraphic>
<OnlineResource
xlink:type="simple"
xlink:href="Apiary.jpg" />
<Format>image/jpeg</Format>
</ExternalGraphic>
<Size>32</Size>
</Graphic>
</PointSymbolizer>
</Rule>
<Rule>
<Name>Vineyard</Name>
<Title>All Vineyards</Title>
<ogc:Filter>
<ogc:PropertyIsLike wildCard="*" singleChar="." escape="!">
<ogc:PropertyName>type</ogc:PropertyName>
<ogc:Literal>Vineyard</ogc:Literal>
</ogc:PropertyIsLike>
</ogc:Filter>
<PointSymbolizer>
<Graphic>
<ExternalGraphic>
<OnlineResource
xlink:type="simple"
xlink:href="Vineyard.jpg" />
<Format>image/jpeg</Format>
</ExternalGraphic>
<Size>32</Size>
</Graphic>
</PointSymbolizer>
</Rule>
<Rule>
<Name>Retail Seafood</Name>
<Title>All Retail Seafood</Title>
<ogc:Filter>
<ogc:PropertyIsLike wildCard="*" singleChar="." escape="!">
<ogc:PropertyName>type</ogc:PropertyName>
<ogc:Literal>Retail Seafood</ogc:Literal>
</ogc:PropertyIsLike>
</ogc:Filter>
<PointSymbolizer>
<Graphic>
<ExternalGraphic>
<OnlineResource
xlink:type="simple"
xlink:href="Retail Seafood.jpg" />
<Format>image/jpeg</Format>
</ExternalGraphic>
<Size>32</Size>
</Graphic>
</PointSymbolizer>
</Rule>
<Rule>
<Name>Bakery</Name>
<Title>All Bakeries</Title>
<ogc:Filter>
<ogc:PropertyIsLike wildCard="*" singleChar="." escape="!">
<ogc:PropertyName>type</ogc:PropertyName>
<ogc:Literal>Bakery</ogc:Literal>
</ogc:PropertyIsLike>
</ogc:Filter>
<PointSymbolizer>
<Graphic>
<ExternalGraphic>
<OnlineResource
xlink:type="simple"
xlink:href="Bakery.jpg" />
<Format>image/jpeg</Format>
</ExternalGraphic>
<Size>32</Size>
</Graphic>
</PointSymbolizer>
</Rule>
<Rule>
<Name>Dairy/Eggs</Name>
<Title>All Dairy/ Eggs</Title>
<ogc:Filter>
<ogc:PropertyIsLike wildCard="*" singleChar="." escape="!">
<ogc:PropertyName>type</ogc:PropertyName>
<ogc:Literal>Dairy/Eggs</ogc:Literal>
</ogc:PropertyIsLike>
</ogc:Filter>
<PointSymbolizer>
<Graphic>
<ExternalGraphic>
<OnlineResource
xlink:type="simple"
xlink:href="Dairy_Eggs.jpg" />
<Format>image/jpeg</Format>
</ExternalGraphic>
<Size>32</Size>
</Graphic>
</PointSymbolizer>
</Rule>
<Rule>
<Name>Christmas Tree Farm</Name>
<Title>All Christmas Tree Farms</Title>
<ogc:Filter>
<ogc:PropertyIsLike wildCard="*" singleChar="." escape="!">
<ogc:PropertyName>type</ogc:PropertyName>
<ogc:Literal>Christmas Tree Farm</ogc:Literal>
</ogc:PropertyIsLike>
</ogc:Filter>
<PointSymbolizer>
<Graphic>
<ExternalGraphic>
<OnlineResource
xlink:type="simple"
xlink:href="Christmas Tree Farm.jpg" />
<Format>image/jpeg</Format>
</ExternalGraphic>
<Size>32</Size>
</Graphic>
</PointSymbolizer>
</Rule>
<Rule>
<Name>Grains</Name>
<Title>All Grain Farms</Title>
<ogc:Filter>
<ogc:PropertyIsLike wildCard="*" singleChar="." escape="!">
<ogc:PropertyName>type</ogc:PropertyName>
<ogc:Literal>Grains</ogc:Literal>
</ogc:PropertyIsLike>
</ogc:Filter>
<PointSymbolizer>
<Graphic>
<ExternalGraphic>
<OnlineResource
xlink:type="simple"
xlink:href="Grains.jpg" />
<Format>image/jpeg</Format>
</ExternalGraphic>
<Size>32</Size>
</Graphic>
</PointSymbolizer>
</Rule>
<Rule>
<Name>Meat Products</Name>
<Title>All Meat Products</Title>
<ogc:Filter>
<ogc:PropertyIsLike wildCard="*" singleChar="." escape="!">
<ogc:PropertyName>type</ogc:PropertyName>
<ogc:Literal>Meat Products</ogc:Literal>
</ogc:PropertyIsLike>
</ogc:Filter>
<PointSymbolizer>
<Graphic>
<ExternalGraphic>
<OnlineResource
xlink:type="simple"
xlink:href="Meat.jpg" />
<Format>image/jpeg</Format>
</ExternalGraphic>
<Size>32</Size>
</Graphic>
</PointSymbolizer>
</Rule>
<Rule>
<Name>Nursery</Name>
<Title>All Nurseries</Title>
<ogc:Filter>
<ogc:PropertyIsLike wildCard="*" singleChar="." escape="!">
<ogc:PropertyName>type</ogc:PropertyName>
<ogc:Literal>Nursery</ogc:Literal>
</ogc:PropertyIsLike>
</ogc:Filter>
<PointSymbolizer>
<Graphic>
<ExternalGraphic>
<OnlineResource
xlink:type="simple"
xlink:href="Nursery.jpg" />
<Format>image/jpeg</Format>
</ExternalGraphic>
<Size>32</Size>
</Graphic>
</PointSymbolizer>
</Rule>
<Rule>
<Name>Petting Zoo</Name>
<Title>All Petting Zoos</Title>
<ogc:Filter>
<ogc:PropertyIsLike wildCard="*" singleChar="." escape="!">
<ogc:PropertyName>type</ogc:PropertyName>
<ogc:Literal>Petting Zoo</ogc:Literal>
</ogc:PropertyIsLike>
</ogc:Filter>
<PointSymbolizer>
<Graphic>
<ExternalGraphic>
<OnlineResource
xlink:type="simple"
xlink:href="Petting Zoo.jpg" />
<Format>image/jpeg</Format>
</ExternalGraphic>
<Size>32</Size>
</Graphic>
</PointSymbolizer>
</Rule>
</FeatureTypeStyle>
</UserStyle>
I realize this post is old but maybe someone will benefit from my answer.
I didn't succeed in using relative image paths so I turned to using URL paths.
Put image(s) in $GEOSERVER_DATA_DIR/styles and reference it with http://localhost:8081/geoserver/styles/some_image.png
For example
<ExternalGraphic>
<OnlineResource xlink:type="simple" xlink:href="http://localhost:8081/geoserver/styles/some_image.png"/>
<Format>image/png</Format>
</ExternalGraphic>
Nice answer, but you need to change the 8081 to 8080 assuming the geoserver instance is working on port 8080
you can put your image in style folder

Membership authentication on windows azure ASP.NET MVC 3 - couldn't find column

I've try to migrate my ASP.NET MVC 3 project (with CodeFirst) to Windows Azure. Offcurse I changed the Providers.I've check the azure sql db and there are new tables like: Applications, Memberships, Profiles,Roles,Users
but now I got error:
[SqlException (0x80131904): Invalid column name 'ApplicationId'.
Invalid column name 'UserName'.
Invalid column name 'UserId'.
Invalid column name 'ApplicationId'.
Invalid column name 'UserName'.
Invalid column name 'IsAnonymous'.
Invalid column name 'LastActivityDate'.]
System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection) +2091750
System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection) +5103168
System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning() +260
System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj) +2294
System.Data.SqlClient.SqlDataReader.ConsumeMetaData() +33
System.Data.SqlClient.SqlDataReader.get_MetaData() +86
System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString) +311
System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async) +987
System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, DbAsyncResult result) +162
System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method) +32
System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method) +141
System.Data.SqlClient.SqlCommand.ExecuteDbDataReader(CommandBehavior behavior) +12
System.Data.Common.DbCommand.ExecuteReader(CommandBehavior behavior) +10
System.Data.EntityClient.EntityCommandDefinition.ExecuteStoreCommands(EntityCommand entityCommand, CommandBehavior behavior) +443
[EntityCommandExecutionException: An error occurred while executing the command definition. See the inner exception for details.]
System.Data.EntityClient.EntityCommandDefinition.ExecuteStoreCommands(EntityCommand entityCommand, CommandBehavior behavior) +479
System.Data.Objects.Internal.ObjectQueryExecutionPlan.Execute(ObjectContext context, ObjectParameterCollection parameterValues) +736
System.Data.Objects.ObjectQuery`1.GetResults(Nullable`1 forMergeOption) +149
System.Data.Objects.ObjectQuery`1.System.Collections.Generic.IEnumerable<T>.GetEnumerator() +44
System.Linq.Enumerable.FirstOrDefault(IEnumerable`1 source) +182
System.Data.Objects.ELinq.ObjectQueryProvider.<GetElementFunction>b__1(IEnumerable`1 sequence) +41
System.Data.Objects.ELinq.ObjectQueryProvider.ExecuteSingle(IEnumerable`1 query, Expression queryRoot) +59
System.Data.Objects.ELinq.ObjectQueryProvider.System.Linq.IQueryProvider.Execute(Expression expression) +150
System.Data.Entity.Internal.Linq.DbQueryProvider.Execute(Expression expression) +87
System.Linq.Queryable.FirstOrDefault(IQueryable`1 source) +265
System.Web.Providers.QueryHelper.GetUser(MembershipContext ctx, String userName, String applicationName) +2104
System.Web.Providers.DefaultMembershipProvider.Membership_CreateUser(String applicationName, String userName, String password, String salt, String email, String passwordQuestion, String passwordAnswer, Boolean isApproved, DateTime& createDate, Boolean uniqueEmail, Int32 passwordFormat, Object& providerUserKey) +151
System.Web.Providers.DefaultMembershipProvider.CreateUser(String username, String password, String email, String passwordQuestion, String passwordAnswer, Boolean isApproved, Object providerUserKey, MembershipCreateStatus& status) +836
System.Web.Security.Membership.CreateUser(String username, String password, String email, String passwordQuestion, String passwordAnswer, Boolean isApproved, Object providerUserKey, MembershipCreateStatus& status) +207
GameiDemo.Controllers.HomeController.Index(User model) +99
lambda_method(Closure , ControllerBase , Object[] ) +108
System.Web.Mvc.ActionMethodDispatcher.Execute(ControllerBase controller, Object[] parameters) +17
System.Web.Mvc.ReflectedActionDescriptor.Execute(ControllerContext controllerContext, IDictionary`2 parameters) +208
System.Web.Mvc.ControllerActionInvoker.InvokeActionMethod(ControllerContext controllerContext, ActionDescriptor actionDescriptor, IDictionary`2 parameters) +27
System.Web.Mvc.<>c__DisplayClass15.<InvokeActionMethodWithFilters>b__12() +55
System.Web.Mvc.ControllerActionInvoker.InvokeActionMethodFilter(IActionFilter filter, ActionExecutingContext preContext, Func`1 continuation) +263
System.Web.Mvc.<>c__DisplayClass17.<InvokeActionMethodWithFilters>b__14() +19
System.Web.Mvc.ControllerActionInvoker.InvokeActionMethodWithFilters(ControllerContext controllerContext, IList`1 filters, ActionDescriptor actionDescriptor, IDictionary`2 parameters) +191
System.Web.Mvc.ControllerActionInvoker.InvokeAction(ControllerContext controllerContext, String actionName) +343
System.Web.Mvc.Controller.ExecuteCore() +116
System.Web.Mvc.ControllerBase.Execute(RequestContext requestContext) +97
System.Web.Mvc.ControllerBase.System.Web.Mvc.IController.Execute(RequestContext requestContext) +10
System.Web.Mvc.<>c__DisplayClassb.<BeginProcessRequest>b__5() +37
System.Web.Mvc.Async.<>c__DisplayClass1.<MakeVoidDelegate>b__0() +21
System.Web.Mvc.Async.<>c__DisplayClass8`1.<BeginSynchronous>b__7(IAsyncResult _) +12
System.Web.Mvc.Async.WrappedAsyncResult`1.End() +62
System.Web.Mvc.<>c__DisplayClasse.<EndProcessRequest>b__d() +50
System.Web.Mvc.SecurityUtil.<GetCallInAppTrustThunk>b__0(Action f) +7
System.Web.Mvc.SecurityUtil.ProcessInApplicationTrust(Action action) +22
System.Web.Mvc.MvcHandler.EndProcessRequest(IAsyncResult asyncResult) +60
System.Web.Mvc.MvcHandler.System.Web.IHttpAsyncHandler.EndProcessRequest(IAsyncResult result) +9
System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +8969201
System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +184
Web.config:
<?xml version="1.0" encoding="utf-8"?>
<!--
For more information on how to configure your ASP.NET application, please visit
http://go.microsoft.com/fwlink/?LinkId=152368
-->
<configuration>
<configSections>
<!-- For more information on Entity Framework configuration, visit http://go.microsoft.com/fwlink/?LinkID=237468 -->
<section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection, EntityFramework, Version=4.4.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
</configSections>
<connectionStrings>
<!--
<add name="ApplicationServices"
connectionString="data source=mssql01\sql01;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|aspnetdb.mdf;User Instance=true"
providerName="System.Data.SqlClient" />
-->
<!--<add name="ApplicationServices" connectionString="Server=tcp:...database.windows.net,1433;Database=...;User ID=...#...;Password={your_password_here};Trusted_Connection=False;Encrypt=True;Connection Timeout=30;" providerName="System.Data.SqlClient" />-->
<!--<add name="DBConnection" connectionString="Server=tcp:....database.windows.net,1433;Database=...;User ID=...#...;Password={your_password_here};Trusted_Connection=False;Encrypt=True;Connection Timeout=30;" providerName="System.Data.SqlClient" />/-->
<!--
<add name="DBConnection" connectionString="data source=.\SQLEXPRESS;initial catalog=GameiDemo;integrated security=True;multipleactiveresultsets=True;" providerName="System.Data.SqlClient" />
-->
<!--<add name="ApplicationServices" connectionString="data source=.\SQLEXPRESS;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|aspnetdb.mdf;User Instance=true"
providerName="System.Data.SqlClient" />//-->
<add name="DefaultConnection" providerName="System.Data.SqlClient"
connectionString="Data Source=tcp:....database.windows.net,1433;Initial Catalog=gamei_db;User Id=...#...;Password=123aba321!;Trusted_Connection=False;Encrypt=True;Connection Timeout=130;**MultipleActiveResultSets=True**" />
</connectionStrings>
<appSettings>
<add key="webpages:Version" value="1.0.0.0" />
<add key="ClientValidationEnabled" value="true" />
<add key="UnobtrusiveJavaScriptEnabled" value="true" />
</appSettings>
<system.web>
<compilation debug="true" targetFramework="4.0">
<assemblies>
<add assembly="System.Web.Abstractions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
<add assembly="System.Web.Helpers, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
<add assembly="System.Web.Routing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
<add assembly="System.Web.Mvc, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
<add assembly="System.Web.WebPages, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
</assemblies>
</compilation>
<authentication mode="Forms">
<forms loginUrl="~/Account/LogOn" timeout="2880" />
</authentication>
<membership defaultProvider="DefaultMembershipProvider">
<providers>
<clear />
<!-- <add name="AspNetSqlMembershipProvider" type="System.Web.Security.SqlMembershipProvider" connectionStringName="ApplicationServices" enablePasswordRetrieval="false" enablePasswordReset="true" requiresQuestionAndAnswer="false" requiresUniqueEmail="false" maxInvalidPasswordAttempts="5" minRequiredPasswordLength="6" minRequiredNonalphanumericCharacters="0" passwordAttemptWindow="10" applicationName="/" /> //-->
<add name="DefaultMembershipProvider" type="System.Web.Providers.DefaultMembershipProvider, System.Web.Providers, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" connectionStringName="DefaultConnection" enablePasswordRetrieval="false" enablePasswordReset="true" requiresQuestionAndAnswer="false" requiresUniqueEmail="false" maxInvalidPasswordAttempts="5" minRequiredPasswordLength="6" minRequiredNonalphanumericCharacters="0" passwordAttemptWindow="10" applicationName="/" />
</providers>
</membership>
<profile defaultProvider="DefaultProfileProvider">
<providers>
<clear />
<!-- <add name="AspNetSqlProfileProvider" type="System.Web.Profile.SqlProfileProvider" connectionStringName="ApplicationServices" applicationName="/" /> //-->
<add name="DefaultProfileProvider" type="System.Web.Providers.DefaultProfileProvider, System.Web.Providers, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" connectionStringName="DefaultConnection" applicationName="/" />
</providers>
</profile>
<roleManager enabled="false" defaultProvider="DefaultRoleProvider">
<providers>
<clear />
<!--<add name="AspNetSqlRoleProvider" type="System.Web.Security.SqlRoleProvider" connectionStringName="ApplicationServices" applicationName="/" />-->
<add name="AspNetWindowsTokenRoleProvider" type="System.Web.Security.WindowsTokenRoleProvider" applicationName="/" />
<add name="DefaultRoleProvider" type="System.Web.Providers.DefaultRoleProvider, System.Web.Providers, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" connectionStringName="DefaultConnection" applicationName="/" />
</providers>
</roleManager>
<pages>
<namespaces>
<add namespace="System.Web.Helpers" />
<add namespace="System.Web.Mvc" />
<add namespace="System.Web.Mvc.Ajax" />
<add namespace="System.Web.Mvc.Html" />
<add namespace="System.Web.Routing" />
<add namespace="System.Web.WebPages" />
</namespaces>
</pages>
<sessionState mode="InProc" customProvider="DefaultSessionProvider">
<providers>
<add name="DefaultSessionProvider" type="System.Web.Providers.DefaultSessionStateProvider, System.Web.Providers, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" connectionStringName="DefaultConnection" />
</providers>
</sessionState>
</system.web>
<system.webServer>
<validation validateIntegratedModeConfiguration="false" />
<modules runAllManagedModulesForAllRequests="true" />
</system.webServer>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="System.Web.Mvc" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="1.0.0.0-2.0.0.0" newVersion="3.0.0.0" />
</dependentAssembly>
</assemblyBinding>
</runtime>
<system.web>
<customErrors mode="Off" />
</system.web>
<entityFramework>
<defaultConnectionFactory type="System.Data.Entity.Infrastructure.SqlConnectionFactory, EntityFramework" />
</entityFramework>
</configuration>
I change username and serwer adres with "..." :)
I found what was wrong. One table form my model was named Users -> this cause that User table from System.Web.Providers does create.

Resources