SQL ¶àÐÐÖµºÏ²¢ÎªÒ»¸öÖµ
·½·¨(1)
SELECT stuff((select ','+ltrim(ColumnName) from #A for xml path('')
),1,1,'')
/*
102,103,104,105
*/
·½·¨(2)
DECLARE @s NVARCHAR(1000)='';
SELECT @s+=ColumnName+',' from #A;
SELECT @s;
Ïà¹ØÎĵµ£º
´ÓTable ±íÖÐÈ¡³öµÚ m Ìõµ½µÚ n ÌõµÄ¼Ç¼£º(Not In °æ±¾)
SELECT TOP n-m+1 *
from Table
WHERE (id NOT IN (SELECT TOP m-1 id from Table ))
--´ÓTABLE±íÖÐÈ¡³öµÚmµ½nÌõ¼Ç¼ (Exists°æ±¾)
SELECT TOP n-m+1 * from TABLE AS a WHERE Not Exists
(Select * from (Select Top m-1 * from TABLE orde ......
ÉÏ»ØËµµ½£¬²Ù×÷Object Array
Æäʵ»¹¿ÉÒÔÕâÑù²Ù×÷£º
var Room = [
{
ID: 'bot',
name: 'test' ......
alert index mem_ct monitoring usage;
desc v$object_usage;
set linesize 190
select * from v$object_usage;
SQL>SET AUTOTRACE ON;
¡¡¡¡*autotrace¹¦ÄÜÖ»ÄÜÔÚSQL*PLUSÀïʹÓÃ
¡¡¡¡ÆäËûһЩʹÓ÷½·¨£º
¡¡¡¡2.2.1¡¢ÔÚSQLPLUSÖеõ½Óï¾ä×ܵÄÖ´ÐÐʱ¼ä
¡¡¡¡SQL> set timing on;
2.2.2¡¢Ö»ÏÔʾִÐмƻ®--(»áÍ¬Ê ......