Quantcast
Channel: CodeSection,代码区,SQL Server(mssql)数据库 技术分享 - CodeSec
Browsing all 3160 articles
Browse latest View live

SQL中排除某一列代码字段含有字母的记录 sql SQLServer SQL语句 代码字段含有字母

SQL中排除某一列代码字段含有字母的记录。 科室代码DEPT_ID ,值是数字,但是source中过来的值有异常值“ttk”,明显不对; cube在处理到这个值的时候报错,所以在源头上排除掉科室代码为字母的记录。select * from DHC_OutPaAdm WHERE DEPT_ID NOT LIKE ('%[A-Z,a-z]%')

View Article


PLSQL的事务管理 sql SQLServer PGSQL 事务管理

PLSQL的事务管理。PL SQL 在执行DELETE、INSERT、update命令之后,不会自动提交事务。 需要执行commit;命令去提交事务 备注:可以打开自动提交命令。 set autocommit on PL SQL 中可以使用的命令: commit:提交事务 rollback:回滚事务 savepoint:保存当前事务点 autocommit:打开或者关闭自动提交事务 set...

View Article


SQL事务 sql SQLServer SQL语句 SQL事务

SQL事务一、事务概念 事务是一种机制、是一种操作序列,它包含了一组数据库操作命令,这组命令要么全部执行,要么全部不执行。因此事务是一个不可分割的工作逻辑单元。在数据库系统上执行并发操作时事务是作为最小的控制单元来使用的。这特别适用于多用户同时操作的数据通信系统。例如:订票、银行、保险公司以及证券交易系统等。 二、事务属性 事务4大属性: 1 原子性(Atomicity):事务是一个完整的操作。 2...

View Article

Image may be NSFW.
Clik here to view.

linux下postgresql的配置 linux linux系统 postgresql postgresql配置

linux下postgresql的配置一,什么是postgresql PostgreSQL是以加州大学伯克利分校计算机系开发的 POSTGRES 版本 4.2 为基础的对象关系型数据库管理系统(ORDBMS),简称pgsql,它支持大部分 SQL 标准并且提供了许多其他现代特性:复杂查询 外键 触发器 视图 事务完整性 多版本并发控制 同样,PostgreSQL 可以用许多方法扩展,比如,...

View Article

用MyBatis拦截器记录SQL执行时间 sql SQLServer MyBatis 拦截器 SQL执行时间

1、在项目的applicationContext-dao.xml 文件中增加一个plugins:sqlStatementInterceptor<bean id="dao-sqlSessionFactory" class="org.mybatis.spring.SqlSessionFactoryBean"> <property name="dataSource"...

View Article


Image may be NSFW.
Clik here to view.

Restoring an entire SQL Server user databases with PowerShell using dbatools

All the good DBAs backup their databases. A significant amount of SQL DBAs use Ola Hallengrens maintenance solution to do so. This gives a folder structure like this In my lab I had installed SQL 2016...

View Article

SQL Server next version CTP 1.4 now available

Microsoft is excited to announce a new preview for the next version of SQL Server (SQL Server v.Next). Community Technology Preview (CTP) 1.4 is available on both windows and linux. In this preview,...

View Article

Image may be NSFW.
Clik here to view.

SQL SERVER Microsoft.SqlServer.Management.Sdk. Sfc.EnumeratorException: Faile...

If you work with a product for a long time, you would start loving it. I have worked with many other RDBMS, but my love to SQL Server will never die. The amount of information available in logs is very...

View Article


ALTER DATABASE failed because a lock could not be placed on database...

At times, we may need to take a database offline. And there is a chance that we encounter an error message like below. How do we solve this issue and take the database offline? Msg 5061, Level 16,...

View Article


An Introduction to SQL Server 2016 Query Store

By David Postlethwaite David is delivering a talk An Introduction to SQL Server Query Store at SQL Saturday Iceland today - this post has been scheduled to coincide with his talk If you are at SQL...

View Article

Image may be NSFW.
Clik here to view.

Microsoft SQL Server R Services - Internals I

18 Mar 2017 in categories: SQL Server Microsoft R Server Data Science tags: SQL Server R Services R WinDbg This post is part of a series of blog-posts about Microsoft SQL Server R Services: Microsoft...

View Article

Image may be NSFW.
Clik here to view.

T-SQL Grouping Set Showcase

Greetings all, In the interim, whilst I juggle my time to get more in-depth posts rolled out (like the one surrounding Alexa skills), I back-tracked once again to look at overlooked features from the...

View Article

Image may be NSFW.
Clik here to view.

SQL Server SME Interview Experience

SQL Server SME Interview Experience This post “SQL Server SME Interview Experience” can help you in understanding and answering the most common question for a SQL Server DBA or Developer. A few days...

View Article


Image may be NSFW.
Clik here to view.

What’s new in SQL Server 2016 Reporting Services (SSRS)

Microsoft released many new features in Reporting Services with the SQL 2016 release.: New Report Portal Paginated Report Enhancements Mobile Report Publisher New Report Portal The first thing you will...

View Article

Image may be NSFW.
Clik here to view.

Understanding the XML description of the Deadlock Graph in SQL Server

Introduction In my previous 2 articles, What is a SQL Server Deadlock and Understanding the graphical representation of the SQL Server Deadlock Graph , I discussed what a deadlock is, how SQL Server...

View Article


Get Row Count of Insert/Update/Delete records in MERGE Statement MSDN TSQL fo...

Get Row Count of Insert/Update/Delete records in MERGE Statement MSDN TSQLforum > Question: How can I get the numbers of records affected in the Merge statement, INSERT,UPDATE,DELETE separately and...

View Article

Image may be NSFW.
Clik here to view.

SQL SERVER 5 Tips to Optimize SQL Server Application Performance

I recently talked with Mark Wright, CTO of Nitrosphere, a company that optimizes SQL Server application performance. In his career, he has seen many “standard” practices that often negatively affect...

View Article


Image may be NSFW.
Clik here to view.

Foreign Key Support in SQL Server 2016 Memory Optimized Tables

By:Ahmad Yaseen || Related Tips:More >In-Memory OLTP Problem The SQL Server In-Memory OLTP feature , also known as Hekaton, is an interesting in-memory processing technology that was introduced in...

View Article

Image may be NSFW.
Clik here to view.

SQL Server Configuration Manager for Linux

By:Rajendra Gupta || Related Tips:More >SQL Server on linux Problem Microsoft has released SQL Server to run on Linux . As a DBA, you must be familiar with SQL Server Configuration Manager for...

View Article

How to troubleshoot long running queries in MS SQL Server

Preface There is an information system that I administer. The system consists of the following components: 1. MS SQL Server database 2. Server application 3. Client applications These information...

View Article
Browsing all 3160 articles
Browse latest View live