SQL Table
Table-Naming Standards
Table-naming standards, as well as any standard within a business, are critical to
maintaining control. After studying the tables and data in the previous sections, you
probably noticed that each table’s suffix is _TBL. This is a naming standard selected
for use, such as what’s been used at various client sites. The _TBL simply tells you
that the object is a table; there are many different types of objects in a relational
database. For example, you will see that the suffix _INX is used to identify indexes
on tables in later hours. Naming standards exist almost exclusively for overall
organization and assist immensely in the administration of any relational database.
Remember, the use of a suffix is not mandatory when naming database objects.
Ïà¹ØÎĵµ£º
http://www.umgr.com/blog/PostView.aspx?bpId=36294
1. Ö´ÐÐsqlÓï¾ä
int sqlite3_exec(sqlite3*£¬ const char *sql£¬ sqlite3_callbacksql Óï·¨
£¬ void *£¬ char **errmsg );
Õâ¾ÍÊÇÖ´ÐÐÒ»Ìõ sql Óï¾äµÄº¯Êý¡£
µÚ1¸ö²ÎÊý²»ÔÙ˵ÁË£¬ÊÇÇ°Ãæopenº¯ÊýµÃµ½µÄÖ¸Õ롣˵ÁËÊǹؼüÊý¾Ý½á¹¹¡£
µÚ2¸ö²ÎÊýconst char ......
ÉÏÉϸöÐÇÆÚ£¬ÓÐÈË·´À¡£¬CSDNÓÐSQL×¢È붶´£¬º¹ÑÕ£¬¼¸ÄêǰΪSQL×¢È붶´£¬²¿ÃÅרÃŶÔËùÓдúÂë×ö¹ýÒ»´Î·Ç³£´óµÄ¼ì²é£¬¾¹È»ÄǴμì²é»¹ÓÐÒÅ©µÄµØ·½¡£×î½üÕ⼸¸öÐÇÆÚ£¬¾ÍÊÇÒ»Ö±ÔÙ¶Ô´úÂë×öÔٴθ´²é£¬¿´ÓÐûÓÐSQL×¢È붶´¡£
´æÔÚSQL×¢È붶´£¬¾ÍÒòΪÄãµÄSQLÓï¾äÊÇ×Ô¼ºÆ´´ ......
Ê×ÏȾÍÊÇÒª×Ô¼º±àдһ¶Î´úÂ룬´æΪ.stx
Îļþ£¨ÀýÈçsql.stx£©£¬È»ºóÔÚeditplusµÄ²Ëµ¥À¸Tools->Configure User
Tools->Files->Setting &syntax,µãadd°´Å¥£¬ÔÚdescriptionÀ¸Î»ÌîÉÏsql,file
ExtensionsÀ¸Î»Ò²ÌîÉÏsql,Èç¹ûÓжà¸öÀ©Õ¹Ãû£¬Ö®¼äÓÓ£»”¸ô¿ª£¨ÀýÈ磺sql;db2£©,È»ºóÔÚsyntax
fileÀ¸Î»ÌîÉ ......
Çå¿Õ¹²Ïí³Ø£¬¹Ø±Õ£¬ÖØÆôÊý¾Ý¿â
SQL> shutdown immediate;
SQL> startup;
¿ªÆô ʱ¼äͳ¼Æ
SQL> set timi on
SQL> select count(*) from dba_objects;
COUNT(*)
----------
11308
Elapsed: 00:00:00.19
SQL> /
COUNT(*)
----------
&nb ......
ÔÚÈ¡Ò»¸öƽ¾ùÖµµÄʱºòÍùÍùÓöµ½Ð¡ÊýµãλÊýµÄ½ØÈ¡¡£
Ç°¼¸ÌìÓöµ½¹ýÕâô¸öÎÊÌ⣬ÔÚKingDee EAS µÄ²éѯ·ÖÎöÆ÷ÀïÃæÈç¹ûÇóijһÎïÁϵÄƽ¾ùµ¥¼ÛʱÎÒÕâÑùдµÀ£º
select avg = case sum(bentry.FQuantity) when 0 then 0 else (sum(bentry.famount)/sum(bentry.FQuantity)) end,
´ËÓï¾ä¿´ËÆûʲôÎÊÌ⣬±Ï¾¹ÊÇÇóƽ¾ùÖµ£¬¿ÉÊÇÈç¹ûÒªÔ ......