Shi means small, so that HIBERNATE support for the standard deviation of the variance function of MYSQL

Open-source category org.hibernate.dialect.MySQLDialect

In the constructor to include two lines of code

registerFunction ( "variance", new StandardSQLFunction ( "variance", Hibernate.DOUBLE));
registerFunction ( "stddev", new StandardSQLFunction ( "stddev", Hibernate.DOUBLE));

Compile this class, the replacement of the same name to hibernate3.jar in class.

Village at HQL you can use the following statement you:

select stddev (obj.nl) from User as obj

This SQL can be directly obtained form the user's age standard deviation (seeking variance with variance function).

分类:Java 时间:2009-03-04 人气:579
分享到:
blog comments powered by Disqus

相关文章

  • How to use the sql function average. Total. Min. Max. Combined. Standard deviation 2010-12-21

    sql function Use sql function, you can query in a select statement which directly calculate the average of the database information, the total number, minimum, maximum, sum, standard deviation, variance and other statistics. Using the recordset objec

  • How to use the sql function average total number of minimum. Maximum sum of the standard deviation 2010-12-21

    sql function Use the sql function, you can query in a select statement which directly calculate the average of the database data, total, minimum, maximum, sum, standard deviation, variance and other statistics. Using the recordset object, can also us

  • jQuery source code analysis-extend function 2010-07-16

    Prepared to jQuery, Ext, etc. Source careful analysis of the framework again, and the results sent to for all to study and discussions. This is my virgin posted, also please be lenient. /*! * jQuery Source Analysis-extend the function * jQuery Versio

  • Debugging in Eclipse run launcher source (1) - Get launcher source 2010-08-15

    Need to start studying the recent work Launcher source, here to record my learning process, but also hope to share with everyone, they laughed at the master! Source I would not do on the Launcher introduced, if we do not know what that first went to

  • jQuery source code analysis-each function 2010-07-20

    /*! * jQuery Source Analysis-each function * jQuery Version :1.4.2 * * ---------------------------------------------------------- * Function Description * * each Function by jQuery.extend function attached to jQuery Object : * jQuery.extend({ * each:

  • [Reprinted] wordpress Source Analysis: query_posts () function (wordpress log calls) 2010-09-20

    http://www.codedesign.cn/?p=252 Will query_posts () before the limit on what you need LOOP conditions, wp_query will produce a new parameter to use your SQL queries, and ignore the URL received by the other parameters, do not ignore if you want, you

  • SQL judge database. Table. Stored procedure. View. Function exists 2010-09-06

    - Determine the existence of the database if exists (select * from master .. sysdatabases where name = N 'Library name') print 'exists' else print 'not exists' --------------- - Determine whether to create the table name exists if exists (select * fr

  • 12 very simple, basic but useful function source in Flex 2011-05-25

    From the original: http://ntt.cc/2008/04/19/12-very-simple-basic-but-useful-function-source-in-flex.html No.1 Copy content to clipboard: System.setClipboard(strContent); No.2 Clone an ArrayCollection: //dummy solution( well, it works ) var bar:ArrayC

  • sql server 2005 the number of dynamic function 2011-01-11

    All objects: SELECT name, object_id, principal_id, schema_id, parent_object_id, type, type_desc, create_date, modify_date, is_ms_shipped, is_published, is_schema_published FROM sys.all_objects ORDER BY name Index object: SELECT object_id, name, index

iOS 开发

Android 开发

Python 开发

JAVA 开发

开发语言

PHP 开发

Ruby 开发

搜索

前端开发

数据库

开发工具

开放平台

Javascript 开发

.NET 开发

云计算

服务器

Copyright (C) codeweblog.com, All Rights Reserved.

CodeWeblog.com 版权所有 黔ICP备15002463号-1

processed in 0.311 (s). 12 q(s)