最新文章专题视频专题问答1问答10问答100问答1000问答2000关键字专题1关键字专题50关键字专题500关键字专题1500TAG最新视频文章推荐1 推荐3 推荐5 推荐7 推荐9 推荐11 推荐13 推荐15 推荐17 推荐19 推荐21 推荐23 推荐25 推荐27 推荐29 推荐31 推荐33 推荐35 推荐37视频文章20视频文章30视频文章40视频文章50视频文章60 视频文章70视频文章80视频文章90视频文章100视频文章120视频文章140 视频2关键字专题关键字专题tag2tag3文章专题文章专题2文章索引1文章索引2文章索引3文章索引4文章索引5123456789101112131415文章专题3
问答文章1 问答文章501 问答文章1001 问答文章1501 问答文章2001 问答文章2501 问答文章3001 问答文章3501 问答文章4001 问答文章4501 问答文章5001 问答文章5501 问答文章6001 问答文章6501 问答文章7001 问答文章7501 问答文章8001 问答文章8501 问答文章9001 问答文章9501
当前位置: 首页 - 科技 - 知识百科 - 正文

OurSQLEpisode191:CommonSchema,part1_MySQL

来源:懂视网 责编:小采 时间:2020-11-09 20:00:19
文档

OurSQLEpisode191:CommonSchema,part1_MySQL

OurSQLEpisode191:CommonSchema,part1_MySQL:This week we start talking about common schema by Shlomi Noach. Ear Candy is some caveats about GTIDs and replication, and At the Movies is using jQuery, AJAX and PHP to insert data into MySQL.NewsIn the news, the OurSQL podcast will change
推荐度:
导读OurSQLEpisode191:CommonSchema,part1_MySQL:This week we start talking about common schema by Shlomi Noach. Ear Candy is some caveats about GTIDs and replication, and At the Movies is using jQuery, AJAX and PHP to insert data into MySQL.NewsIn the news, the OurSQL podcast will change

This week we start talking about common schema by Shlomi Noach. Ear Candy is some caveats about GTIDs and replication, and At the Movies is using jQuery, AJAX and PHP to insert data into MySQL.

News

In the news, the OurSQL podcast will change to a monthly format after episode 200. We love doing the podcast, but it is very time consuming and production is expensive. We will still bring quality episodes, they will just be spaced further apart.

Common Schema

Common SchemaGoogle Code page

Installation sectionof the common schema documentation.

  • Process Routines- stored routines managing query, session and process information & workflow
  • session_unique_id()
  • query_latptime()
  • query_runtime()
  • this_query()
  • throttle()- some good examples here
  • General Routines- stored routines mostly dealing with checksums
  • crc64()- returns a crc64 checksum of the data given
  • query_checksum()- return a checksum of the results of the query specified
  • random_hash()
  • shorttime_to_seconds- converts human readable "short times" like 1h, 45m, and so on to a number of seconds
  • Query Analysis Routines- takes in the name of a schema and an object (event, routine, SQL statement or view) and returns a summary of the objects the given object involves, the type and schema for each dependent object
  • get_event_dependencies()- for events
  • get_routine_dependencies()- for stored functions and stored procedures
  • get_sql_dependencies()- for SQL statements
  • get_view_dependencies()- for views
  • Example of get_routine_dependencies():

    CALL common_schema.get_routine_dependencies( 'common_schema', 'get_routine_dependencies');

    +-------------+--------------------+-----------+------+

    | schema_name | object_name | object_type | action |

    +-------------+--------------------+-----------+------+

    | common_schema | get_sql_dependencies | procedure | call |

    | mysql | proc | table | select |

    +-------------+--------------------+-----------+------+

    2 rows in set (0.07 sec)

  • Schema Analysis Routines
  • table_exists()
  • table_rotate()- rotate a table in logrotate format
  • Security Routines
  • duplicate_grantee()- create a new user with the same privileges as an existing user
  • grant_access()- grant SELECT and EXECUTE on common_schema items to the user listed
  • match_grantee()- match a specified user@host with an entry in the mysql.user table
    For example, from PROCESSLIST:
    SELECT id, common_schema.mysql_grantee(user, host) FROM information_schema.processlist;
  • mysql_grantee()- return a qualified, valid mysql user from the information given
  • killall()
  • security_audit()- find unsecure accounts
  • Date and Time Routines
  • start_of_hour()
  • start_of_week()
  • start_of_week_sunday()
  • start_of_month()
  • start_of_quarter()
  • start_of_year()
  • is_datetime()
  • easter_day()
  • Charting Routines
  • line_chart()
  • google_line_chart()
  • Common Schema risks

    Ear Candy

    In this week's ear candy we discussreplication challenges with GTIDs.

    At the movies

    This week in at the movies, we present a video on how toInsert Data Into MySQL Database using jQuery + AJAX + PHP

    Where you can see us

    Sheeri will be at theJuly Boston MySQL User Groupon Monday, July 14th, where we'll have David Berube talking about "Improving Your Database Designs with Practical Database Theory"..

    Gerry will be at theJuly Seattle MySQL User Groupon Monday, July 14th.

    Sheeri will be attending theTDWI Executive Summitin Boston from Sunday July 20th through Wednesday July 23rd.

    Gerry will be attendingOSCon 2014from Sunday July 20th through Thursday July 24th.

    Feedback

    Facebook group

    Google+ page

    e-mail: podcast at technocation.org

    voicemail using phone/Skype: +1-617-674-2369

    twitter:@oursqlcast

    orTweet about @oursqlcast

    Trackback URL for this post:

    http://technocation.org/trackback/1323

    声明:本网页内容旨在传播知识,若有侵权等问题请及时与本网联系,我们将在第一时间删除处理。TEL:177 7030 7066 E-MAIL:11247931@qq.com

    文档

    OurSQLEpisode191:CommonSchema,part1_MySQL

    OurSQLEpisode191:CommonSchema,part1_MySQL:This week we start talking about common schema by Shlomi Noach. Ear Candy is some caveats about GTIDs and replication, and At the Movies is using jQuery, AJAX and PHP to insert data into MySQL.NewsIn the news, the OurSQL podcast will change
    推荐度:
    标签: sql mysql Schema
    • 热门焦点

    最新推荐

    猜你喜欢

    热门推荐

    专题
    Top