Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

sqliteÊý¾Ý¿â²éѯ±í¿¿Ç°

¸ÕÈëÃÅ ÏëʵÏÖÐÂÎűíÐÂÎÅÖö¥µÄ¹¦ÄÜ

select * from web_news  order by id desc limit 0,6

web_news ±íÀïÓÐTOPÁÐ ÔõÑùÈÃTOPÁмǼΪ1µÄΪÖÃǰ  ¸÷λ´ó´óÃǰï°ïæ ·Ö²»¶à Çë°üº­£¡£¡
order by top²»ÐÐÂð£¿

idºÍtopÄǸöÓÅÏÈ£¿

SQL code:
select * from web_news order by top!=1 ,id desc limit 0,6;



ÄãµÄÒâ˼ÊDz»ÊÇtop=1µÄÊÇÖö¥µÄÄØ£¿
SELECT * from  web_news ORDER BY `topid` DESC LIMIT 0 , 6

²¹³äһϣ¡

ÄãµÄÒâ˼ÊDz»ÊÇtop=1µÄÊÇÖö¥top=0µÄ²»Öö¥µÄÄØ£¿
SELECT * from  web_news ORDER BY 'top' DESC LIMIT 0 , 6



ÒýÓÃ
SQL codeselect*from web_newsorderbytop!=1 ,iddesc limit0,6;

THANK YOU  ½â¾öÁË!


Ïà¹ØÎÊ´ð£º

c#Á¬½ÓSqliteÊý¾Ý¿âÎÊÌâ

ÎÒÓÃsqliteadmin½¨ÁËÒ»¸öÊý¾Ý¿âtest.sdb,¿ÉÊÇÔõôҲ´ò²»¿ªÌáʾÈçÏ´íÎó£ºFile opened that is not a database file
file is encrypted or is not a database¡£

ÎÒµÄÁ¬½Ó×Ö·û´®ÈçÏÂÂ¥ÉϵĿɲ»¿ÉÒÔ°ïÎÒ¿´¿´
S ......

ÓйØSQliteµÄÒ»¸öÎÊÌâ

³ÌÐò´úÂëÈçÏ£º
sqlTime = "select SUM(onlineTimeSpan) from T_OnlineTimeSum where ipAddress = :a AND onlineDate BETWEEN :b AND :c";
                ......

sqliteµÄ¿ÕÖµ²éѯÔõôд,ÄÜÕߵ÷Ö

sqliteµÄ¿ÕÖµ²éѯÔõôд,ÄÜÕߵ÷Ö
select * from tt where f1 is null

select * from yourTable where col is null;

SQL code:
sqlite> create table Aoqun (id int primary key,col1 int);
sqlite> ......

¡¾ÈçºÎ²é¿´SqliteÊý¾Ý¿âÖÐÓжàÉÙÕűí[¶¥ÕßÓзÖ]

SqlServerÖÐÕâÑùͳ¼Æ:

select name from sysobjects where xtype='U'
ÒªÖªµÀ×ÜÊýµÄ»°¾Í¼òµ¥ÁË£º
select count(*) from sysobjects where xtype='U'

OracleÖÐÕâÑù²éѯ£º
Sele ......

Çë½Ì£ºVCÖеÄTree¿Ø¼þÓëSQLiteÊý¾Ý±íµÄʹÓÃÎÊÌâ

ÎÒÒª°ÑÊý¾Ý±íÖеÄÊý¾Ý£¬ÒÔÊ÷µÄÐÎʽÏÔʾÔÚ¶Ô»°¿òÖС£
±ÈÈ磺
Ö»ÒªÊý¾Ý±íÖÐÓÐ3¸ö×ֶΡ¢id¡¢parentid¡¢name
ÇëÎÊÎÒÈçºÎдһЩ´úÂ뽫Êý¾Ý±íÖеÄÄÚÈÝÌîµ½Ê÷¿Ø¼þÖÐÈ¥ 

ÒýÓÃ
Ò»°ãÊÇÓõݹéµÄ·½·¨À´ÊµÏ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ