Apple MACCMSv10 source code commonly used SQL statements

1. Query data
SELECT * FROM {pre}vod Query all data
SELECT * FROM {pre}vod WHERE vod_id=1000 Query specified ID data
2. Delete data
DELETE FROM {pre}vod Delete all data
DELETE FROM {pre}vod WHERE vod_id =1000 Delete the specified data
DELETE FROM {pre}vod WHERE vod_actor LIKE'%刘德华%' Delete the data with "Andy Lau" in the vod_actor field
DELETE FROM {pre}vod WHERE vod_type=1 Delete the data of the specified category ID
DELETE FROM {pre}vod WHERE vod_area LIKE'%Taiwan%'
DELETE FROM {pre}vod WHERE vod_lang LIKE'%Cantonese%' Delete data in the specified language
3. Modify data
UPDATE {pre}vod SET vod_hits= 1 Modify all the values ​​in the vod_hits field to 1
UPDATE {pre}vod SET vod_hits=1 WHERE vod_id=1000 Specify the number of data to modify the value in the vod_hits field to 1
4. Change a character string in the image address Replace with another string
UPDATE {pre}vod SET vod_pic=REPLACE(vod_pic,'original string','replace with other string')
5. After deleting the database, the auto-increment ID restarts from 1
PHP: truncate {pre}vod
ASP: acc Open the database with office, after deleting the data, compress and repair the database.
Or ALTER TABLE {pre}vod ALTER COLUMN vod_id COUNTER (1, 1)
mssql use TRUNCATE TABLE {pre}vod
6, delete data with duplicate database names
DELETE FROM {pre}vod where vod_id not in (SELECT vod_id FROM {pre}vod the HAVING COUNT BY vod_name the GROUP (*)> 1)
7, repair deadlock table
rEPAIR tABLE {pre}art, {pre}vod, {pre}type, {pre}comment, {pre}gbook, {pre}link, {pre}admin, {pre}topic, {pre}user, {pre}card, {pre}group,{pre}visit

After the page submits the data, it takes some time to take effect?

JavaScript

这个一般是web服务配置了缓存导致的~~
访问phpinfo(),看看是不是你开启了ZendOpcache之类的opcode缓存.ZendOpcache里面有个过期时间配置,如opcache.revalidate_freq=60 ,表示60秒后脚本再次被访问时会检测PHP文件的时间戳,有改变则更新opcode缓存,你可以设为0,这样每次访问都会检测文件时间戳,你的修改就能生效了.
在php.ini文件中找到
opcache.enable=1
或
opcache.enable_cli=1
改为0,重启php-fpm,done

Guess you like

Origin blog.csdn.net/qq_41186565/article/details/104500547