|
|
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
- <html xmlns="http://www.w3.org/1999/xhtml">
- <head>
- <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
- <title>WORM: WSqlDataType Namespace Reference</title>
- <link href="tabs.css" rel="stylesheet" type="text/css"/>
- <link href="search/search.css" rel="stylesheet" type="text/css"/>
- <script type="text/javascript" src="search/search.js"></script>
- <link href="doxygen.css" rel="stylesheet" type="text/css"/>
- </head>
- <body onload='searchBox.OnSelectItem(0);'>
- <!-- Generated by Doxygen 1.7.3 -->
- <script type="text/javascript"><!--
- var searchBox = new SearchBox("searchBox", "search",false,'Search');
- --></script>
- <script type="text/javascript">
- function hasClass(ele,cls) {
- return ele.className.match(new RegExp('(\\s|^)'+cls+'(\\s|$)'));
- }
-
- function addClass(ele,cls) {
- if (!this.hasClass(ele,cls)) ele.className += " "+cls;
- }
-
- function removeClass(ele,cls) {
- if (hasClass(ele,cls)) {
- var reg = new RegExp('(\\s|^)'+cls+'(\\s|$)');
- ele.className=ele.className.replace(reg,' ');
- }
- }
-
- function toggleVisibility(linkObj) {
- var base = linkObj.getAttribute('id');
- var summary = document.getElementById(base + '-summary');
- var content = document.getElementById(base + '-content');
- var trigger = document.getElementById(base + '-trigger');
- if ( hasClass(linkObj,'closed') ) {
- summary.style.display = 'none';
- content.style.display = 'block';
- trigger.src = 'open.png';
- removeClass(linkObj,'closed');
- addClass(linkObj,'opened');
- } else if ( hasClass(linkObj,'opened') ) {
- summary.style.display = 'block';
- content.style.display = 'none';
- trigger.src = 'closed.png';
- removeClass(linkObj,'opened');
- addClass(linkObj,'closed');
- }
- return false;
- }
- </script>
- <div id="top">
- <div id="titlearea">
- <table cellspacing="0" cellpadding="0">
- <tbody>
- <tr style="height: 56px;">
- <td id="projectlogo"><img alt="Logo" src="worm_sm.png"></td>
- <td style="padding-left: 0.5em;">
- <div id="projectname">WORM <span id="projectnumber">0.2</span></div>
- <div id="projectbrief">A C++ DAL/ORM code generation framework</div>
- </td>
- </tr>
- </tbody>
- </table>
- </div>
- <div id="navrow1" class="tabs">
- <ul class="tablist">
- <li><a href="index.html"><span>Main Page</span></a></li>
- <li><a href="modules.html"><span>Modules</span></a></li>
- <li class="current"><a href="namespaces.html"><span>Namespaces</span></a></li>
- <li><a href="annotated.html"><span>Classes</span></a></li>
- <li><a href="files.html"><span>Files</span></a></li>
- <li id="searchli">
- <div id="MSearchBox" class="MSearchBoxInactive">
- <span class="left">
- <img id="MSearchSelect" src="search/mag_sel.png"
- onmouseover="return searchBox.OnSearchSelectShow()"
- onmouseout="return searchBox.OnSearchSelectHide()"
- alt=""/>
- <input type="text" id="MSearchField" value="Search" accesskey="S"
- onfocus="searchBox.OnSearchFieldFocus(true)"
- onblur="searchBox.OnSearchFieldFocus(false)"
- onkeyup="searchBox.OnSearchFieldChange(event)"/>
- </span><span class="right">
- <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
- </span>
- </div>
- </li>
- </ul>
- </div>
- <div id="navrow2" class="tabs2">
- <ul class="tablist">
- <li><a href="namespaces.html"><span>Namespace List</span></a></li>
- <li><a href="namespacemembers.html"><span>Namespace Members</span></a></li>
- </ul>
- </div>
- </div>
- <div class="header">
- <div class="headertitle">
- <h1>WSqlDataType Namespace Reference</h1> </div>
- </div>
- <div class="contents">
-
- <p><a class="el" href="namespace_w_sql_data_type.html" title="WSqlDataType namespace - flags for supported SQL data types.">WSqlDataType</a> namespace - flags for supported SQL data types.
- <a href="#_details">More...</a></p>
- <table class="memberdecls">
- </table>
- <hr/><a name="_details"></a><h2>Detailed Description</h2>
- <div class="textblock"><p><a class="el" href="namespace_w_sql_data_type.html" title="WSqlDataType namespace - flags for supported SQL data types.">WSqlDataType</a> namespace - flags for supported SQL data types. </p>
- <p>This is a container for type flags and convenience functions for the supported SQL datatypes.</p>
- <p>These are the ANSI SQl standard types supported by WSQL - these will be mapped to native C++ data types in ORM class generation. For example a TINYINT column will declared as a member of type "short", a VARCHAR or TEXT as type std::string, a DECIMAL to a double, etc. The following is a list of the types with specifications - Implementers of drivers should use this as a guide for translating types for a particular DBMS.</p>
- <p>Writers of drivers should translate any proprietary or other data types specific to the DBMS of the driver to these types. Most DBMS metadata is returned in a string identifier of one of these types and can usually be mapped conveniently by using the functions toString(type) or toType(string).</p>
- <p>See the following for more information on the specific data types: </p>
- <div class="fragment"><pre class="fragment"> Note: these types are modeled after the MySQL data types (which seemed the broadest
- and closest to ANSI standard). I include these notes <span class="keywordflow">for</span> reference only - they are
- <span class="keywordflow">for</span> determining how types will be converted..(todo)
-
- <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a2fa7f6e8be4f3f438461f01e8aacd76e">TINYINT</a> - A very small integer that can be <span class="keywordtype">signed</span> or <span class="keywordtype">unsigned</span>. If <span class="keywordtype">signed</span>, the
- allowable range is from -128 to 127. If <span class="keywordtype">unsigned</span>, the allowable range is from 0
- to 255. You can specify a width of up to 4 digits.
-
- <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a185153956d8bff78e071637d75518049">SMALLINT</a> - A small integer that can be <span class="keywordtype">signed</span> or <span class="keywordtype">unsigned</span>. If <span class="keywordtype">signed</span>, the
- allowable range is from -32768 to 32767. If <span class="keywordtype">unsigned</span>, the allowable range is
- from 0 to 65535. You can specify a width of up to 5 digits.
-
- <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a5cd5fddf9f96a63b0e8fbab168793348">MEDIUMINT</a> - A medium-sized integer that can be <span class="keywordtype">signed</span> or <span class="keywordtype">unsigned</span>. If <span class="keywordtype">signed</span>,
- the allowable range is from -8388608 to 8388607. If <span class="keywordtype">unsigned</span>, the allowable
- range is from 0 to 16777215. You can specify a width of up to 9 digits.
-
- <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11afc4d0f8755ce336f16e9ecc467c29175">INT</a> - A normal-sized integer that can be <span class="keywordtype">signed</span> or <span class="keywordtype">unsigned</span>. If <span class="keywordtype">signed</span>, the
- allowable range is from -2147483648 to 2147483647. If <span class="keywordtype">unsigned</span>, the allowable
- range is from 0 to 4294967295. You can specify a width of up to 11 digits.
-
- <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a18d7620211cfa3ba63be7f081fc0c181">BIGINT</a> - A large integer that can be <span class="keywordtype">signed</span> or <span class="keywordtype">unsigned</span>. If <span class="keywordtype">signed</span>, the
- allowable range is from -9223372036854775808 to 9223372036854775807. If
- <span class="keywordtype">unsigned</span>, the allowable range is from 0 to 18446744073709551615. You can specify
- a width of up to 11 digits.
-
- <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a82673be233e9f7a52bbb9e94f1ea526a">FLOAT</a>(M,D) - A floating-point number that cannot be <span class="keywordtype">unsigned</span>. You can define the
- display length (M) and the number of decimals (D). This is not required and will
- default to 10,2, where 2 is the number of decimals and 10 is the total number of
- digits (including decimals). Decimal precision can go to 24 places for a <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a82673be233e9f7a52bbb9e94f1ea526a">FLOAT</a>.
-
- <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11ad9d614c9575a0891342c3171fc2772e5">DOUBLE</a>(M,D) - A <span class="keywordtype">double</span> precision floating-point number that cannot be <span class="keywordtype">unsigned</span>.
- You can define the display length (M) and the number of decimals (D). This is
- not required and will default to 16,4, where 4 is the number of decimals.
- Decimal precision can go to 53 places for a <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11ad9d614c9575a0891342c3171fc2772e5">DOUBLE</a>. REAL is a synonym for
- <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11ad9d614c9575a0891342c3171fc2772e5">DOUBLE</a>.
-
- <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11aead2d4157138ca0913950d5efb1a2ca6">DECIMAL</a>(M,D) - An unpacked floating-point number that cannot be <span class="keywordtype">unsigned</span>. In
- unpacked decimals, each decimal corresponds to one byte. Defining the display
- length (M) and the number of decimals (D) is required. NUMERIC is a synonym for
- <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11aead2d4157138ca0913950d5efb1a2ca6">DECIMAL</a>.
-
- Date and Time Types:
-
- <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a2c6b3641a625bd3ff903a2c247b26517">DATE</a> - A date in YYYY-MM-DD format, between 1000-01-01 and 9999-12-31. For
- example, December 30th, 1973 would be stored as 1973-12-30.
-
- <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11abd11772d96be90ace717e22ba24bc71e">DATETIME</a> - A date and time combination in YYYY-MM-DD HH:MM:SS format, between
- 1000-01-01 00:00:00 and 9999-12-31 23:59:59. For example, 3:30 in the afternoon
- on December 30th, 1973 would be stored as 1973-12-30 15:30:00.
-
- <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11ab5c547c63dba19815e88b2cca05f4e32">TIMESTAMP</a> - A timestamp between midnight, January 1, 1970 and sometime in 2037.
- This looks like the previous <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11abd11772d96be90ace717e22ba24bc71e">DATETIME</a> format, only without the hyphens between
- numbers; 3:30 in the afternoon on December 30th, 1973 would be stored as
- 19731230153000 ( YYYYMMDDHHMMSS ).
-
- <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a1e863429b29d2e90ff60f8251017baef">TIME</a> - Stores the time in HH:MM:SS format.
-
- <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a8f6410ee01071f02a1d75259e4a4120c">YEAR</a>(M) - Stores a year in 2-digit or 4-digit format. If the length is specified
- as 2 (for example <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a8f6410ee01071f02a1d75259e4a4120c">YEAR</a>(2)), YEAR can be 1970 to 2069 (70 to 69). If the length
- is specified as 4, YEAR can be 1901 to 2155. The default length is 4.
-
- String Types:
-
- <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11af83d87e0848372230d82996d24f6a0ce">CHAR</a>(M) - A fixed-length <span class="keywordtype">string</span> between 1 and 255 characters in length (for
- example <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11af83d87e0848372230d82996d24f6a0ce">CHAR</a>(5)), right-padded with spaces to the specified length when stored.
- Defining a length is not required, but the default is 1.
-
- <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11ad02611db29673467c36fbd4d267dccf8">VARCHAR</a>(M) - A variable-length <span class="keywordtype">string</span> between 1 and 255 characters in length;
- for example <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11ad02611db29673467c36fbd4d267dccf8">VARCHAR</a>(25). You must define a length when creating a <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11ad02611db29673467c36fbd4d267dccf8">VARCHAR</a> field.
-
- <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a79b1e3c78a2aae4000205a6340120066">BLOB</a> or <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11ad0523af90d4025e99f05182cac18863e">TEXT</a> - A field with a maximum length of 65535 characters. BLOBs are
- "Binary Large Objects" and are used to store large amounts of binary data, such
- as images or other types of files. Fields defined as <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11ad0523af90d4025e99f05182cac18863e">TEXT</a> also hold large
- amounts of data; the difference between the two is that sorts and comparisons on
- stored data are case sensitive on BLOBs and are not case sensitive in <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11ad0523af90d4025e99f05182cac18863e">TEXT</a>
- fields. You do not specify a length with <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a79b1e3c78a2aae4000205a6340120066">BLOB</a> or <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11ad0523af90d4025e99f05182cac18863e">TEXT</a>.
-
- TINYBLOB or <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a229e9a69a403ad69b83e3ffcc6cafbab">TINYTEXT</a> - A <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a79b1e3c78a2aae4000205a6340120066">BLOB</a> or <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11ad0523af90d4025e99f05182cac18863e">TEXT</a> column with a maximum length of 255
- characters. You do not specify a length with TINYBLOB or <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a229e9a69a403ad69b83e3ffcc6cafbab">TINYTEXT</a>.
-
- MEDIUMBLOB or <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a3ec0265b0cd32336a8cc6927706a97d6">MEDIUMTEXT</a> - A <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a79b1e3c78a2aae4000205a6340120066">BLOB</a> or <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11ad0523af90d4025e99f05182cac18863e">TEXT</a> column with a maximum length of
- 16777215 characters. You do not specify a length with MEDIUMBLOB or <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a3ec0265b0cd32336a8cc6927706a97d6">MEDIUMTEXT</a>.
-
- LONGBLOB or <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a4c4198e10fa328e23de4cccfac355eef">LONGTEXT</a> - A <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a79b1e3c78a2aae4000205a6340120066">BLOB</a> or <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11ad0523af90d4025e99f05182cac18863e">TEXT</a> column with a maximum length of 4294967295
- characters. You do not specify a length with LONGBLOB or <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a4c4198e10fa328e23de4cccfac355eef">LONGTEXT</a>.
-
- <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a693d7d1d546702a3efaa1e0df104e1eb">ENUM</a> - An enumeration, which is a fancy term for list. When defining an <a class="code" href="namespace_w_sql_1_1_w_sql_data_type.html#aa234580d74e3dfc10946a4ec8e317d11a693d7d1d546702a3efaa1e0df104e1eb">ENUM</a>,
- you are creating a list of items from which the value must be selected (or it
- can be NULL). For example, if you wanted your field to contain "A" or "B" or
- "C", you would define your ENUM as ENUM ('A', 'B', 'C') and only those values
- (or NULL) could ever populate that field.
- </pre></div> </div></div>
- <!--- window showing the filter options -->
- <div id="MSearchSelectWindow"
- onmouseover="return searchBox.OnSearchSelectShow()"
- onmouseout="return searchBox.OnSearchSelectHide()"
- onkeydown="return searchBox.OnSearchSelectKey(event)">
- <a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark"> </span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark"> </span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark"> </span>Namespaces</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark"> </span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark"> </span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark"> </span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark"> </span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark"> </span>Enumerator</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark"> </span>Friends</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(9)"><span class="SelectionMark"> </span>Defines</a></div>
-
- <!-- iframe showing the search results (closed by default) -->
- <div id="MSearchResultsWindow">
- <iframe src="" frameborder="0"
- name="MSearchResults" id="MSearchResults">
- </iframe>
- </div>
-
- <hr class="footer"/><address class="footer"><small>Generated on Mon Oct 31 2011 12:57:17 for WORM by 
- <a href="http://www.doxygen.org/index.html">
- <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.3 </small></address>
- </body>
- </html>
|