Giter Site home page Giter Site logo

osdldbt / dbt3 Goto Github PK

View Code? Open in Web Editor NEW
2.0 1.0 2.0 3.06 MB

Database Test 3: Fair Use TPC Benchmark(TM) H kit

Home Page: https://osdldbt.github.io/dbt3/

License: Artistic License 2.0

Shell 86.77% TSQL 0.53% CMake 10.36% PLpgSQL 1.58% Makefile 0.76%

dbt3's Issues

How to build TPC-H Tools for MySQL

Hello, I met some problems while building TPC-H Tools for MySQL. I refered to the INSTALL.rst and user's guide. The user's guide says dbt3 supports MySQL but it didn't work when I want to use dbt3-build-dbgen.

The command line is following:
./dbt3-build-dbgen --patch-dir=/home/czhang/mysql-dbt3/share/dbt3/patches --query-dir=/home/czhang/mysql-dbt3/share/dbt3/queries mysql /home/czhang/mysql-tpch

But the ERROR is reported: ERROR: Unhandled DBMS: mysql

image

dbt3 doesn't seem to natively support MySQL, so I have two questions I'd like to get help:

  1. How do I modify the dbt3's scripts to make it work with MySQL? Is there a more detailed user's guide?
  2. Where should the extracted TPC-H-tool folder be placed? Does it have to be somewhere in the dbt3 folder? Or is it anywhere?

Thank you for your help very much!

Result statistics broken in new version of dbt3-post-process

Hi,

Thanks for maintaining dbt3!

I've been using it to benchmark PostgreSQL over the past few weeks and I just noticed that the generated statistics in summary.rst don't make sense. As an example:

========  ========  ========  ========  ========  ========  ========  ========
 Stream      Q1        Q2        Q3        Q4        Q5        Q6        Q7
========  ========  ========  ========  ========  ========  ========  ========
       1      1.73      0.26      0.41      0.13      0.79      0.35      1.00
       2      1.74      0.25      0.40      0.14      0.79      0.36      0.97
     Min      1.74      0.25      0.40      0.14      0.79      0.36      0.97
     Max      1.74      0.25      0.40      0.14      0.79      0.36      0.97
     Avg      0.87      0.12      0.20      0.07      0.39      0.18      0.48
========  ========  ========  ========  ========  ========  ========  ========

As you can see, both Min and Max are simply the value of the last stream, whilst Avg is the last stream divided by the number of streams. As an example, Q1 here is reported to have an average of 0.87 instead of the correct 1.74. (The same type of errors can be seen in the example in doc/dbt3.rst.)

If we take a look at what the script does, the error is evident:

printf " Avg"
for Q in $(seq "${Q0}" "${Q1}"); do
if [ "${Q}" -eq 23 ]; then
STRING="^PERF\.THRUPUT\.RFST.*\.RF1,"
elif [ "${Q}" -eq 24 ]; then
STRING="^PERF\.THRUPUT\.RFST.*\.RF2,"
else
STRING="^PERF\.THRUPUT\.QS${STREAM}\.Q${Q},"
fi
if [ $HTML -eq 1 ]; then
SIZE=80
else
SIZE=8
fi
SUM=$(grep "${STRING}" "${QTIME}" \
| cut -d "," -f 5 | xargs | tr ' ' + | bc -l)
printf " %${SIZE}.2f" "$(echo "${SUM} / ${STREAMS}" | bc -l)"
done

STREAM is set in a for loop further up in the script, but this section is not contained within it. Thus, STREAM just retains its latest value (in this case 2) and the basis of the calculation becomes just the final stream instead of all streams.

Looking at the history for scripts/dbt3-post-process.in, I believe this error was introduced when the post-processing was converted from R to shell in a1719d7.

I think a solution would be to not use the STREAM variable in the STRING regex for the aggregations, e.g.

STRING="^PERF\.THRUPUT\.QS[[:digit:]]\+\.Q${Q},"

Happy to make a PR if you agree!

All the best,
Ole

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.