1 / 26

SQL Server 2012

SQL Server 2012. Top 10 new features. Agenda. AlwaysOn Availability Groups ColumnStore Index Contained database Windowing functions FileTable Semantic Search T-SQL enhancements Server roles en default schema voor groups SSIS project deployment BISM met PowerView.

payton
Télécharger la présentation

SQL Server 2012

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. SQL Server 2012 Top 10 new features

  2. Agenda • AlwaysOn Availability Groups • ColumnStore Index • Contained database • Windowing functions • FileTable • Semantic Search • T-SQL enhancements • Server roles en default schema voor groups • SSIS project deployment • BISM met PowerView

  3. 1. Availability Groups • Mirroring 2.0 (?) • Highlights: • Zelfgroep van databases definiëren • Tot 4 secondaries • Read-only secondaries • Backup from secondary • (not differential) • Ziesessie van Robert Hartskeerl over AlwaysOnom 11.00u

  4. 2. Column store index • Normale heap/index slaat records rijvoorrij op • Veel IO overhead alsnietallekolommennodigzijn • Column store index slaatgegevens per kolom op • Beterecompressie • Minder IO • Veelbetere performance • Ziesessie van Hugo Kornelis: SQL Server 2012 ColumnStore index om 14.45u

  5. 3. Contained Database • Moving a database to a different SQL Server instance is easy • Detach / attach • Backup / restore • Right? • How about • Logins ? • Linked Servers ? • Database mail ? • Jobs ? • #temp tables / cross database joins and collation ? • … ?

  6. Contained Database geeft: • Database authentication • Users met wachtwoord / windows users • Geen mapping met login -> geen orphaned users • TempDB collation issues • Objecten in tempdbwordengemaakt met de collation van de database • DB is meereen black box. Verplaatsen is makkelijker (Azure?, OTAP?, ..) • Nogtewensen: • Volledigeonafhankelijkheid van instance • Alleen partially contained is nu geïmplementeerd

  7. Contained database demo

  8. Tot slot • EXEC sp_configure ‘contained database authentication’, 1 • SELECT * FROM sys.dm_db_uncontained_entities • ALTER DATABASE <name> SET CONTAINMENT PARTIAL • Nietalle features zijntecombineren met contained databases • Erzijnenkele security implicties, oa: • Databases met guest account enabled zijnbenaderbaar • Users met control database permission kunnen containment aanzetten en mensentoeganggeven • … (zie BOL)

  9. 4. Windowing functions • over clause van aggregate functiesuitgebreid met: • Rows x preceding • Rows between x preceding and y following • Rows unbounded preceding • … • Geefttoepassingenals moving average, meelopendtotaal, vergelijk met vorigemaand, …

  10. Windowing functions demo

  11. Extra grouping functions • PERCENTILE_CONT, PERCENTILE_DISC • In statistics, a percentile (or centile) is the value of a variable below which a certain percent of observations fall. • PERCENT_RANK, CUME_DIST • Calculates the relative rank of a row within a group of rows • FIRST_VALUE, LAST_VALUE • Returns the first, last value in an ordered set of values • +- Comparable to sibling functions in SSAS hierarchy • LEAD, LAG • Accesses data from a subsequent, earlier row in the same result set without the use of a self-join with a given offset

  12. 5. FileTable • Klassiek database ontwerp issue: BLOB’s in database of extern op fileshare? • Beideoplossingenhebbennadelen • SQL Server 2008: FileStream • Best of both worlds: wijdoenze in de database maar SQL Server zetze op eenfileshare • Nadeel: applicatiecodemoetaangepastom feature tegebruiken • SQL Server 2012: FileTable • Geenonderscheidmeertussenfileshare en tabel • Intergreertgoed met full text en semantic search

  13. 6. Semantic Search • Uit BOL: • provides deep insight into unstructured documents stored in SQL Server databases by extracting statistically relevant key phrases, and then - based on these phrases – identifying similar documents. These results are made available as structured data through three Transact-SQL rowset functions • full-text search: query for words in a document • semantic search: query the meaning of the document • E.g. query the document similarity index to identify resumes that match a job description

  14. Voorbereiding • Installeer en enable full text search • Run SemanticLanguageDatabase.msi • Unpacks mdf • Attach semanticdb database • Register semanticdb: • sp_fulltext_semantic_register_language_statistics_db @dbname = N'semanticsdb; • InstalleeriFiltersomtezoekeninbijvoorbeelddocx, pptx, …

  15. FileTable + semantic search demo

  16. 7. T-SQL enhancements • Throw (tervervanging van raiserror) • Sequence (tervervanging van identity) • Paging (offset x rows fetch next y rows) • Functions: • Parse (convert met regional settings) • Try_parse (parse maar zonder errors) • Format (omdat we code 105 van convert nietkunnenonthouden) • Concat (omdat we niet van NULL houden) • IIF (omdat CASE somsomslachtig is)

  17. T-SQL demo

  18. 8. Security • Server roles • default schema voor groups

  19. User defined server roles • Eigen rollenmaken op instance level • Vergelijkbaar met database roles • Minder noodzaakvoorsysadmin • Minder rechtenvoor administrators (better separation of duties) • Triggers vooradd/remove logins to user-defined server roles • T-SQL • CREATE/DROP SERVER ROLE • ALTER SERVER ROLE • E.g. ALTER SERVER ROLE Production ADD MEMBER [TrainSQL\Peter] ; • Vervangtsp_addrolemember

  20. default schema voorgroups • Probleemmet SQL Server 2008 en eerder: • Schema en user wordenautomatischaangemaaktalsobject gemaaktin default schema en er is geen default schema • Logins gebaseerd op groepenkennengeen default schema • Login gebaseerd op windows groepkan nu default schema krijgen (no. 1 customer request) • Schema management makkelijker

  21. Security demo

  22. 9. SSIS project deployment • Probleem met SQL Server 2008 en eerder: • Deployennaarfilesystem of SQL Server (msdb)? • Project deployment: • SSISDB catalog (vergelijkbaar met ReportServer database) • Meer versies van project mogelijk • Environments vervangen configurations • Parameters vervangen parent package configurations • T-SQL procedures om packages uittevoeren

  23. SSIS demo

  24. 10. BISM met PowerView • BISM = BI Semantic Model • Nieuw model naast SSAS UDM • Gebaseerd op PowerPivot • PowerView: • Rapportage tool voorniettechneuten • Ziesessie van Marcel Westra om 13.30u

  25. GetReady 2012 • Utrecht • 19 juni • Hele dag nieuwe features • Peter terBraake

  26. Peter terBraake trainsql@live.nl @pbraake BEDANKT!

More Related