1. Don't fetch any data that you don't need,or don't fetch any columns that you don't need. Because retrieving more data or more columns, which can increase network,I/O,memory and CPU overhead for the server. For example, if you need several columns you can use
    AT EPOCH LATEST
    SELECT fi.name, fi.InvestmentKey,id.VendorId,id.CUSIP,id.ISIN,id.DomicileCountryId,id.CurrencyId
    FROM dbo.FixedIncome fi
    INNER JOIN dbo.InvestmentIdDimension id ON id.InvestmentKey = fi.InvestmentKey
    WHERE id.InvestmentId = 'B000023K1X'
    But do not use:
    AT EPOCH LATEST
    SELECT fi.*, id.*
    FROM dbo.FixedIncome fi
    INNER JOIN dbo.InvestmentIdDimension id ON id.InvestmentKey = fi.InvestmentKey
    WHERE id.InvestmentId = 'B000023K1X'
  2. To avoid blocking Vertica write process, we alway add the "AT EPOCH
    LATEST" for query,which is snapshot read. for example, You can use
    AT EPOCH LATEST SELECT ... FROM ...,
    But do not use:
    SELECT ... FROM ...
  3. Chop up a complex query to many simpler queries.
  4. Join decomposition, if posible, Sometimes, Using "In" clause or sub
    query clause instead of a complex "JOIN" clause. like this, we can use
    AT EPOCH LATEST
    SELECT s1.CompanyId, id.InvestmentId, s1.InvestmentKey,id.VendorId,id.CUSIP,id.ISIN,id.DomicileCountryId,id.CurrencyId
    FROM ( SELECT CompanyId,InvestmentKey FROM dbo.FixedIncome WHERE CompanyId = '0C00000BDL') s1
    INNER JOIN dbo.InvestmentIdDimension id ON id.InvestmentKey = s1.InvestmentKey
    WHERE id.VendorId = 101 OR id.VendorId = 102;
    But do not use:
    AT EPOCH LATEST
    SELECT s1.CompanyId, id.InvestmentId, s1.InvestmentKey,id.VendorId,id.CUSIP,id.ISIN,id.DomicileCountryId,id.CurrencyId
    FROM dbo.FixedIncome fi
    INNER JOIN dbo.InvestmentIdDimension id ON id.InvestmentKey = s1.InvestmentKey
    WHERE fi.CompanyId = '0C00000BDL' AND( id.VendorId = 101 OR id.VendorId = 102 );
  5. Try to use the temporary table to cache data, which can avoid scan an physical table for times.
  6. Try to push the outer predicate into the inner subquery clause, so that it is evaluated before the analytic computation
  7. For Top-K query, if posible, we'd better omit the order by clause, Or we'd better adding a filter condition for it.
  8. For sort operation, We can create Pre-sorted projections, so the
    vertica can choose the faster Group By Pipeline over Group By Hash
  9. Please refer to the "Optimizing Query Performance" chapter in
    reference manual of vertica, which doc's name is "Communiti Vertica
    Community Edition 6.0"
    [https://my.vertica.com/docs/CE/6.0.1/HTML/index.htm#12525.htm ]

Query performance optimization of Vertica的更多相关文章

  1. Goal driven performance optimization

    When your goal is to optimize application performance it is very important to understand what goal d ...

  2. opengl performance optimization

    OpenGL 性能优化 作者: Yang Jian (jyang@cad.zju.edu.cn) 日期: 2009-05-04 本文从硬件体系结构.状态机.光照.纹理.顶点数组.LOD.Cull等方面 ...

  3. Java Performance Optimization Tools and Techniques for Turbocharged Apps--reference

    Java Performance Optimization by: Pierre-Hugues Charbonneau reference:http://refcardz.dzone.com/refc ...

  4. Development of large-scale site performance optimization method from LiveJournal background

    A LiveJournal course of development is a project in the 99 years began in the campus, a few people d ...

  5. Performance Optimization (2)

    DesktopGood performance is critical to the success of many games. Below are some simple guidelines f ...

  6. Chrome DevTools & performance optimization

    Chrome DevTools & performance ptimization https://www.bing.com https://developers.google.com/web ...

  7. 网站性能优化(website performance optimization)2

    我们先研究下构建渲染树前的几个步骤:也就是DOM和CSSOM,通常这些步骤的效果最差使你的网页呈现速度非常慢,我们是讨论尽可能快的将HTML流式传输给客户端,使浏览器能够开始构建DOM,还有其他注意事 ...

  8. Android Performance Optimization

    1.zipalign 2.ui优化 3.package size 4.RenderScript 5.Resource Shrinking & Code Shrinking 6.java cod ...

  9. 网站性能优化(website performance optimization)

    提高代码运行速度,或许我们从来没有优化这些页面来提高速度 想要开发优秀的网站,你必须了解你的用户,知道他们想要达到什么目的,同时还要明白浏览器的工作原理,从而能够打造快速良好的体验,我最近在PageS ...

随机推荐

  1. Windows上编译OpenEXR

    注意一定要使用1.0.1版本的ilmbase和1.6.1版本的openexr,其它版本的我测试过,OpenImageIO会编译失败. 解压ilmbase 1.0.1到[工作目录]/openexr/il ...

  2. 线上 ELK 集群健康值 red 状态问题排查与解决

    之前一直运行正常的数据分析平台,最近一段时间没有注意发现日志索引数据一直未生成,大概持续了n多天,当前状态: 单台机器, Elasticsearch(下面称ES)单节点(空集群),1000+shrad ...

  3. coderfoces D. Gourmet choice

      D. Gourmet choice time limit per test 2 seconds memory limit per test 256 megabytes   题目链接: https: ...

  4. fdisk 磁盘分区

    .[root@test4 ~]# fdisk /dev/sda //对sda磁盘进行分区 Device contains neither a valid DOS partition table, no ...

  5. “全栈2019”Java第四十一章:static关键字

    难度 初级 学习时间 10分钟 适合人群 零基础 开发语言 Java 开发环境 JDK v11 IntelliJ IDEA v2018.3 文章原文链接 "全栈2019"Java第 ...

  6. leecode刷题(13) -- 字符串中的第一个唯一字符

    leecode刷题(13) -- 字符串中的第一个唯一字符 字符串中的第一个唯一字符 描述: 给定一个字符串,找到它的第一个不重复的字符,并返回它的索引.如果不存在,则返回 -1. 案例: s = & ...

  7. [ActionScript 3.0] 动态链接库

    很多时候,我们为了项目和程序结构更加清晰,需要将发布好的swf放到一个固定的地方供主文件引用,这时就会出现发布好的swf所用的as类路径发生改变,为避免这个问题,需要用到动态链接库,以下做一个简单例子 ...

  8. centos7中使用Rsync和inotify同步文件

    一. 环境说明 由于web服务器所提供的网站数据需要保持一致,但当服务器越来越多时,这些主机之间同步网站数据会很麻烦. 解决方案是在后端建立一个数据发布服务器,该服务器作为rsync客户端,通过ino ...

  9. python3的enumerate函数

    enumerate() 函数用于将一个可遍历的数据对象(如列表.元组或字符串)组合为一个索引序列,同时列出数据和数据下标,一般用在 for 循环当中.

  10. jupyter notebook不小心点了退出,怎么找到密码

    在cmd中输入:jupyter notebook list   回车 在输出的内容中找"token=xxxxxxxxx",把等号后面一大堆的东西输入到 password or to ...