Tag:Table building

  • Common statements of MySQL date


    data type datetime timestamp Statement testing Table building DROP TABLE IF EXISTS test_time; CREATE TABLE test_time ( `id` INT (3) UNSIGNED AUTO_INCREMENT, `Name ` char (5) default ‘// used for update time test `test_datetime` datetime DEFAULT CURRENT_TIMESTAMP, `test_datetime1` datetime DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, `test_timestamp` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP, `test_timestamp1` timestamp NOT NULL DEFAULT […]

  • Range partition


    Series articles: Range partition MySQL execution plan The partition method of range partition table is: each partition contains row data, and the partition expression is within the given range. The range of partition should be continuous and can not overlap, which can be defined by the values less than operator. Create common table 1 CREATE […]

  • All parsing of external, terminated, partitioned and stored in the table creation statement of hive


    Starting from the statement of creating tables on the official website, my analysis is as follows: `CREATE [TEMPORARY] [EXTERNAL] TABLE [IF NOT EXISTS] [db_name.]table_name    — (Note: TEMPORARY available in Hive“0.14“.“0“and later)` `[(col_name data_type [column_constraint_specification] [COMMENT col_comment], … [constraint_specification])]` `[COMMENT table_comment]` `[PARTITIONED BY (col_name data_type [COMMENT col_comment], …)]` `[CLUSTERED BY (col_name, col_name, …) [SORTED BY (col_name […]

  • Review of MySQL eight data types


    Dark night sky, can always make people have countless reverie, I do not know the screen in front of you, this week how? Whether it’s playing or practicing, time is constantly shuttling around us, But since you’ve all checked in, I’ll take you to review the MySQL data type in this short 5 minutes! #Common […]

  • [20200904]12c invisible column impdp segment_column_id.txt


    [20200904]12c invisible column impdp segment_column_id.txt –//12C provides a new feature to set hidden columns. This may cause some problems with select * from.. and even change the display order–//Therefore, select *. Is prohibited in general code in the program. If hidden columns are set, what happens to export and import? 1. Environment:[email protected]> @ ver1PORT_STRING                    VERSION        […]

  • Springboot integrates quartz to realize timing task


    1 demand In my lab management project with front-end and back-end separation, one function is student status statistics. My design is to count the proportion of each state by day. In order to facilitate calculation, at 0 o’clock every day, the system needs to reset the students’ status and insert a piece of data as […]

  • Thinkphpp6.0 export excel case


    (1) Environment configuration Basic environment System environment: windows10 x64 PHP integrated environment: phpenv7.1.5( https://www.phpenv.cn/ ) PHP7.4.4 MySQL8.0.19 Nginx1.16.1 Database management tool: Navicat premium 15.0.11 PHP dependency management tool: composer( https://getcomposer.org/Composer-Setup.exe ) (2) Install and configure thinkphpp6.0 (1) Installing thinkphpp6.0 composer create-project topthink/think tp2excel (2) Install the excel plug-in phpspreadsheet composer require phpoffice/phpspreadsheet (3) Configure site […]

  • Restrictions on MySQL table partition


    The first time I used MySQL table partition, I encountered many problems. Now I summarize the problems and solutions.   1. If the partition value type is not an integer value, the following error occurs: [Err] 1697 – VALUES value for partition ‘p0’ must have type INT Partition value must be an integer value. For […]

  • PLSQL project case


    Chapter 6 project case 1   Demand: 1. Set up a table bank of bank account_ Account with the following fields and constraints     2. Complete the basic crud of the table 3. Simulate the transfer process 4. Business rollback after simulation exception Development documents: 1. Build tables according to demand 2. Follow the coding […]

  • How to use OSS external table to read JSON data in maxcompute?


    1、 Open OSS and upload JSON file JSON file content display: {“id”:5644228109524316032,”sourceType”:1} {“id”:-736866360508848202,”sourceType”:3} 2、 Log in to dataworks and create an external table Table creation statement: CREATE EXTERNAL TABLE `json_table` ( `id` bigint, `sourcetype` int ) ROW FORMAT SERDE ‘org.apache.hive.hcatalog.data.JsonSerDe’ STORED AS TEXTFILE LOCATION ‘oss://oss-cn-beijing-internal.aliyuncs.com/gjt-demo/home/jsondata/’; 3、 Create a temporary query to view the data Flag […]