2014年2月17日
摘要: 1. 当前系统日期、时间 select getdate() 2. dateadd 在向指定日期加上一段时间的基础上,返回新的 datetime 值 例如:向日期加上2天 select dateadd(day,2,'2004-10-15') --返回:2004-10-17 00:00:00.000 3. datediff 返回跨两个指定日期的日期和时间边界数。 select datediff(day,'2004-09-01','2004-09-18') --返回:17 4. datepart 返回代表指定日期的指定日期部分的整数。 select DATEPART(month, '2004-10-15') --返回 10 5. datename 返回代表指定日期的指定日期部分的字符串 select datename(weekday, '2004-10-15') --返回:星期五 阅读全文
posted @ 2014-02-17 14:24 ITPCBI 阅读(327) 评论(0) 推荐(0) 编辑
  2014年2月12日
摘要: It's often useful to avoid repeating lengthy expressions. Here's one technique for reusing expressions. Consider the chart below. The Expression for the column labeled "Net" is: =sum(Quantity * Price) * (1-Discount) Let's add another column for "Commission", defined as 10% of Net. Instead of repeating the Net calculation, use the expression: =Net * .1 阅读全文
posted @ 2014-02-12 22:08 ITPCBI 阅读(265) 评论(0) 推荐(0) 编辑
  2014年1月28日
摘要: 一、表分区文章索引 SQL Server 合并(删除)分区解惑 SQL Server 2005 分区模板与实例 SQL Server 动态生成分区脚本 SQL Server 2005 自动化删除表分区设计方案 二、目的 这段时间,在SQL Server的生产环境中尝试了不同方式的表分区,积累了一些这方面的经验,这里就表分区的一些注意事项做些记录。 阅读全文
posted @ 2014-01-28 17:17 ITPCBI 阅读(421) 评论(0) 推荐(0) 编辑
  2014年1月22日
摘要: 我们经常在SQLServer之间使用Linked Server以访问远程数据库,但有时会需要访问其它类型数据源,比如MySQL,目前如何连接Mariadb(MySQL被Oracle收购后的分支用于维护其开源性)的文章比较少,我们便以Mariadb为例来简单介绍下. SQLServe提供了通过ODBC建立Linked Server的方法,我们通过此方法和Mariadb建立连接. 阅读全文
posted @ 2014-01-22 20:09 ITPCBI 阅读(2127) 评论(0) 推荐(0) 编辑
  2014年1月9日
摘要: 如今,当我们进入默认安装了Linux 后,系统启动后往往默认直接进入图形界面X Window。我们如何设置,让CentOS启动后直接进入控制台界面呢?首先要切换成root用户,这样可以更改系统配置文件/etc/inittab。然后打开编辑文档vim /etc/inittab将id:5:initdefault:改为id:3:initdefault:这样reboot后就可以直接进入控制台命令行界面了。当然,如果你想开启图形界面可以输入startx。 阅读全文
posted @ 2014-01-09 23:53 ITPCBI 阅读(2115) 评论(0) 推荐(0) 编辑
  2013年12月30日
摘要: We recently had a project reading data from a Oracle database using 'Microsoft OLE DB Provider for Oracle'. But since both of our database and OS are in 64bit version, we usually encoutered an error below: SSIS Error Code DTS_E_OLEDB_NOPROVIDER_64BIT_ERROR. The requested OLE DB provider MSDAORA.1 is not registered -- perhaps no 64-bit provider is available. 阅读全文
posted @ 2013-12-30 21:29 ITPCBI 阅读(325) 评论(0) 推荐(0) 编辑
  2013年12月24日
摘要: SSAS中的主动缓存,的意思就是主动处理类似,当一个条件触发,则cube开始处理维度和度量值聚合,所以主动缓存,可以理解为主动处理。 阅读全文
posted @ 2013-12-24 14:49 ITPCBI 阅读(647) 评论(0) 推荐(0) 编辑
  2013年12月23日
摘要: A database snapshot is a read-only, static view of a SQL Server database (the source database). The database snapshot is transactionally consistent with the source database as of the moment of the snapshot's creation. A database snapshot always resides on the same server instance as its source database. As the source database is updated, the database snapshot is updated. Therefore, the longer a database snapshot exists, the more likely it is to use up its available disk space. 阅读全文
posted @ 2013-12-23 14:39 ITPCBI 阅读(568) 评论(0) 推荐(0) 编辑
  2013年12月20日
摘要: 当我们使用Qlikview straight table来表现数据时,经常会遇到有很多的维度列或表达式列需要在表中表现出来,往往超出了屏幕的宽度而需要拖动滚动条,非常不方便。而实际上,并不是所有的列对于用户来说都是有意义的,甚至在不同的时期用户只关心其中某些列内的数据。但是,为了满足所有用户的需求,我们有时需要让所有的列对用户有效。 Dynamic dimension能够让用户可以方便的选择他关心的列,本文将要教你如何如何创建动态维度列。 阅读全文
posted @ 2013-12-20 14:15 ITPCBI 阅读(828) 评论(1) 推荐(1) 编辑