User Group Italiano SQL Server
SQL Server “Denali” CTP3
Le novità del comando EXECUTE
Sergio Govoni
[email protected]
Attribution-NonCommercial-ShareAlike 2.5
http://creativecommons.org/licenses/by-nc-sa/2.5/
Speaker
Sergio Govoni
• 10+ years on ERP software developer
• 6+ years on SQL Server
– MCP, MCTS SQL Server
– Microsoft SQL Server MVP
• Speaker, Editor and Publisher @ UGISS
– User Group: www.ugiss.org
– Blog: http://community.ugiss.org/blogs/sgovoni
• Co-Author
– MVP Deep Dives Volume 2
UGISS - User Group Italiano SQL Server
2
Agenda
• Metadata Discovery
– 2 Stored procedure
– 2 DMF
– EXECUTE
• WITH RESULT SETS
UGISS - User Group Italiano SQL Server
3
New EXECUTE syntax
EXECUTE < proc | clr proc | remote proc | function >
[WITH <execute_option>[,...n ]]
{ RESULT SETS { UNDEFINED | NONE | (<result_sets_definition>) } }
<result_sets_definition> ::=
{
<result_set_definition>
| AS OBJECT [<object_location>.]{ table_name | view_name | tvf }
| AS TYPE [schema_name.]table_type_name
| AS FOR XML
| (…)
[,...n ]
}
UGISS - User Group Italiano SQL Server
4
RESULT SETS definition
• Garantisce metadati specifici per i result set
restituiti da una SP o da un batch T-SQL
– Richiesta corrispondenza nel numero delle colonne
– Conversioni di tipo
– Errore: result sets non compatibili
• Opzioni supportate
– RESULT SETS UNDEFINED (default)
– RESULT SETS NONE
– RESULT SETS (…)
• Gestisce result sets multipli
UGISS - User Group Italiano SQL Server
5
Demo
RESULT SETS definition
UGISS - User Group Italiano SQL Server
6
Le novità del comando EXECUTE
Risorse Generiche
•
EXECUTE WITH RESULT SETS
–
–
•
Presentazione e demo
–
•
microsoft.public.it.sql
microsoft.public.sqlserver.*
Newsgroups pubblici via WEB
–
–
•
http://www.ugiss.org
Newsgroups pubblici via NTTP
–
–
•
http://www.microsoft.com/technet/prodtechnol/sql
http://msdn.microsoft.com/sql
Comunità SQL Server
–
•
http://www.microsoft.com/italy/sql
http://www.microsoft.com/sql
Supporto sviluppo ed professionisti IT
–
–
•
http://www.ugiss.org
Informazioni sul prodotto SQL Server
–
–
•
EXECUTE (Transact-SQL)
About WITH RESULT SETS clause in SQL Server Code-Name "Denali"
http://www.microsoft.com/italy/communities/newsgroups/default.mspx
http://www.microsoft.com/technet/community/newsgroups/server/sql.mspx
Formazione
–
http://www.microsoft.com/italy/traincert
UGISS - User Group Italiano SQL Server
7
SQL Server “Denali” CTP3
Le novità del comando EXECUTE
Attribution-NonCommercial-ShareAlike 2.5
http://creativecommons.org/licenses/by-nc-sa/2.5/
Scarica

execute - Microsoft