<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="pt-br">
		<id>http://wiki.mstech.com.br/index.php?action=history&amp;feed=atom&amp;title=Alunos_por_curso</id>
		<title>Alunos por curso - Histórico de revisão</title>
		<link rel="self" type="application/atom+xml" href="http://wiki.mstech.com.br/index.php?action=history&amp;feed=atom&amp;title=Alunos_por_curso"/>
		<link rel="alternate" type="text/html" href="http://wiki.mstech.com.br/index.php?title=Alunos_por_curso&amp;action=history"/>
		<updated>2026-05-07T21:41:38Z</updated>
		<subtitle>Histórico de revisões para esta página neste wiki</subtitle>
		<generator>MediaWiki 1.26.2</generator>

	<entry>
		<id>http://wiki.mstech.com.br/index.php?title=Alunos_por_curso&amp;diff=4281&amp;oldid=prev</id>
		<title>Andre.iguera em 18h40min de 24 de janeiro de 2017</title>
		<link rel="alternate" type="text/html" href="http://wiki.mstech.com.br/index.php?title=Alunos_por_curso&amp;diff=4281&amp;oldid=prev"/>
				<updated>2017-01-24T18:40:30Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table class='diff diff-contentalign-left'&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;tr style='vertical-align: top;' lang='pt-BR'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Edição anterior&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Edição das 18h40min de 24 de janeiro de 2017&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l1&quot; &gt;Linha 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Linha 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&amp;lt;syntaxhighlight lang=&amp;quot;sql&amp;quot; line=&amp;quot;1&amp;quot; &amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;/*&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;/*&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;- Alunos por curso (ensino médio, fundamental) (exibir ano letivo, curso, turma, disciplina)&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;- Alunos por curso (ensino médio, fundamental) (exibir ano letivo, curso, turma, disciplina)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l67&quot; &gt;Linha 67:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Linha 68:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	, Turma&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	, Turma&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	, Aluno&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	, Aluno&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&amp;lt;/syntaxhighlight&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Andre.iguera</name></author>	</entry>

	<entry>
		<id>http://wiki.mstech.com.br/index.php?title=Alunos_por_curso&amp;diff=4280&amp;oldid=prev</id>
		<title>Andre.iguera: Criou página com '/* - Alunos por curso (ensino médio, fundamental) (exibir ano letivo, curso, turma, disciplina) */  USE DES_BLU_GestaoEscolar GO  ; with Dados AS  ( 	SELECT 		Uad.uad_nome AS...'</title>
		<link rel="alternate" type="text/html" href="http://wiki.mstech.com.br/index.php?title=Alunos_por_curso&amp;diff=4280&amp;oldid=prev"/>
				<updated>2017-01-24T18:32:44Z</updated>
		
		<summary type="html">&lt;p&gt;Criou página com &amp;#039;‎&lt;span dir=&quot;auto&quot;&gt;&lt;span class=&quot;autocomment&quot;&gt;- Alunos por curso (ensino médio, fundamental) (exibir ano letivo, curso, turma, disciplina): &lt;/span&gt;  USE DES_BLU_GestaoEscolar GO  ; with Dados AS  ( 	SELECT 		Uad.uad_nome AS...&amp;#039;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Página nova&lt;/b&gt;&lt;/p&gt;&lt;div&gt;/*&lt;br /&gt;
- Alunos por curso (ensino médio, fundamental) (exibir ano letivo, curso, turma, disciplina)&lt;br /&gt;
*/&lt;br /&gt;
&lt;br /&gt;
USE DES_BLU_GestaoEscolar&lt;br /&gt;
GO&lt;br /&gt;
&lt;br /&gt;
; with Dados AS &lt;br /&gt;
(&lt;br /&gt;
	SELECT&lt;br /&gt;
		Uad.uad_nome AS DRE&lt;br /&gt;
		, Esc.esc_nome AS Escola&lt;br /&gt;
		, Pes.pes_nome as Aluno&lt;br /&gt;
		, Alc.alc_matricula AS [LoginBoletimOnline]&lt;br /&gt;
		, Tci.tci_nome AS Ciclo&lt;br /&gt;
		, Cur.cur_nome AS Curso&lt;br /&gt;
		, Crp.crp_descricao AS Serie&lt;br /&gt;
		, Cal.cal_ano AS AnoLetivo&lt;br /&gt;
		, Tur.tur_codigo AS Turma&lt;br /&gt;
		, CASE Tur.tur_tipo WHEN 1 THEN 'Normal' WHEN 2 THEN 'Recuperação paralela' WHEN 3 THEN 'Educação Física' WHEN 4 THEN 'Educação Física' ELSE '' END AS TipoTurma&lt;br /&gt;
		, Tur.tur_id&lt;br /&gt;
		, Tur.esc_id&lt;br /&gt;
		, ROW_NUMBER() OVER (PARTITION BY Esc.esc_id, Cur.cur_id ORDER BY Alu.alu_id) AS NumeroAlunoCurso&lt;br /&gt;
	FROM ACA_Aluno Alu WITH(NOLOCK)&lt;br /&gt;
	INNER JOIN MTR_MatriculaTurma Mtu WITH(NOLOCK)&lt;br /&gt;
		ON Mtu.alu_id = Alu.alu_id&lt;br /&gt;
		AND Mtu.mtu_situacao = 1&lt;br /&gt;
	INNER JOIN ACA_AlunoCurriculo Alc WITH(NOLOCK)&lt;br /&gt;
		ON Alc.alu_id = Mtu.alu_id&lt;br /&gt;
		AND Alc.alc_id = Mtu.alc_id&lt;br /&gt;
		AND Alc.alc_situacao = 1&lt;br /&gt;
	INNER JOIN TUR_Turma Tur WITH(NOLOCK)&lt;br /&gt;
		ON Tur.tur_id = Mtu.tur_id&lt;br /&gt;
	INNER JOIN ACA_CalendarioAnual Cal WITH(NOLOCK)&lt;br /&gt;
		ON Cal.cal_id = Tur.cal_id&lt;br /&gt;
	INNER JOIN ESC_Escola Esc WITH(NOLOCK)&lt;br /&gt;
		ON Esc.esc_id = Tur.esc_id&lt;br /&gt;
	LEFT JOIN Synonym_SYS_UnidadeAdministrativa Uad WITH(NOLOCK)&lt;br /&gt;
		ON Uad.ent_id = Esc.ent_id&lt;br /&gt;
		AND Uad.uad_id = Esc.uad_idSuperiorGestao&lt;br /&gt;
&lt;br /&gt;
	INNER JOIN Synonym_PES_Pessoa Pes WITH(NOLOCK)&lt;br /&gt;
		ON Pes.pes_id = Alu.pes_id&lt;br /&gt;
	LEFT JOIN Synonym_SYS_Usuario Usu WITH(NOLOCK)&lt;br /&gt;
		ON Usu.pes_id = Pes.pes_id&lt;br /&gt;
		AND Usu.usu_situacao &amp;lt;&amp;gt; 3&lt;br /&gt;
&lt;br /&gt;
	INNER JOIN ACA_Curso Cur WITH(NOLOCK)&lt;br /&gt;
		ON Cur.cur_id = Alc.cur_id&lt;br /&gt;
	INNER JOIN ACA_CurriculoPeriodo Crp WITH(NOLOCK)&lt;br /&gt;
		ON Crp.cur_id = Alc.cur_id&lt;br /&gt;
		AND Crp.crr_id = Alc.crr_id&lt;br /&gt;
		AND Crp.crp_id = Alc.crp_id&lt;br /&gt;
	LEFT JOIN ACA_TipoCiclo Tci WITH(NOLOCK)&lt;br /&gt;
		ON Tci.tci_id = Crp.tci_id&lt;br /&gt;
&lt;br /&gt;
	WHERE&lt;br /&gt;
		Alu.alu_situacao = 1&lt;br /&gt;
		AND Tur.tur_situacao = 1&lt;br /&gt;
)&lt;br /&gt;
SELECT *&lt;br /&gt;
FROM Dados&lt;br /&gt;
--WHERE NumeroAlunoCurso &amp;lt;= 20&lt;br /&gt;
order by&lt;br /&gt;
	DRE&lt;br /&gt;
	, Escola&lt;br /&gt;
	, Turma&lt;br /&gt;
	, Aluno&lt;/div&gt;</summary>
		<author><name>Andre.iguera</name></author>	</entry>

	</feed>