Skip to main content

All Questions

0 votes
0 answers
132 views

MySQL Partition table based on two columns

I have an events table which holds historical data of 10 year's with daily coming new data. Now the total rows in this table are 22560041. Table has column's id, title, status (1-4), start_date and I ...
Gurdeep Singh's user avatar
0 votes
0 answers
230 views

dropping partition in MySQL?

I am kinda lame in mysql, but I need it for running Zabbix. Due to large DB, I am using a partitioning, based on script below. https://bestmonitoringtools.com/zabbix-partitioning-tables-on-mysql-...
Padl3xx's user avatar
0 votes
2 answers
140 views

MySQL partition by foreign key

I have a chat database in MySQL. 'users' table user_id(PK), user_name 'chat' table chat_id(PK), user1_id(FK), user2_id(FK) 'messages' table message_id(PK), chat_id(FK), user_from(FK), ...
EddyG's user avatar
  • 2,139
1 vote
2 answers
2k views

Database Design for large datasets

I'm currently working on a database table desing where we will have a few hundred million records in it and I wonder what will be the best way of managing it. With these kind of datasets we will ...
Luk's user avatar
  • 431
1 vote
2 answers
3k views

Partitioning table on YEAR and create view in MYSQL

I have 2 problems with a partitioned table in mysql. My table has three columns id_row INT NOT NULL AUTO_INCREMENT name_element VARCHAR(45) NULL date_element DATETIME NOT NULL I modify the table to ...
eclipse's user avatar
  • 13
1 vote
1 answer
877 views

Change model's table name runtime

I am using Sequelize.js and need to save historical data till specific year and want to separate my tables by year's prefix for example prices_2010, prices_2011 e.g. I can create so tableName:"...
Aren Hovsepyan's user avatar
0 votes
0 answers
735 views

Partition on existing table with millions of records

I have table name builds it look likes CREATE TABLE `builds` ( `id` int(10) unsigned NOT NULL AUTO_INCREMENT, `testplan_id` int(10) unsigned NOT NULL DEFAULT '0', `name` varchar(100) NOT NULL ...
Anubhav Singh's user avatar
2 votes
1 answer
776 views

How does hash(row id + year) partition work?

I'm new to this with partitions. Didn't knew it existed but came aware when I tried to make our new 'url_hash' column unique in a table in our database. And got the error message: A UNIQUE INDEX ...
Peter Westerlund's user avatar
-1 votes
1 answer
189 views

Is there a benefit in creating a vertical partition of a table if only relevant columns are being selected anyway?

I am using MySQL 5.6. I have some tables that have upwards of 15-20 columns each. However, I am being careful to only select relevant columns in each of my queries. Would there still be some benefit ...
Ian Spangler's user avatar
0 votes
0 answers
345 views

Database partition - Better done by PHP or MySQL?

Let me explain the context first : I am building a visit tracker, with PHP and MySQL. So when a user visit a certain URL, his informations will be registered, then he will be redirected to a page. ...
hellimac's user avatar
  • 291
0 votes
2 answers
663 views

Mysql partition - How to do list partitioning of a table that contains unique column?

I am doing mysql list partitioning. my table data is as below ---------------------------------------- id | unique_token | city | student_name | ---------------------------------------- 1 | xyz ...
user2274074's user avatar
  • 1,087
0 votes
1 answer
100 views

MySQL - clarification on table partition / subpartition

I've a table with around 300 millions records in it (only for 60 days). The table structure is quite simple .. It has 12 columns, which 4 of them are Indexed: LogTime - DateTime RegionID - Integer ...
atari83's user avatar
  • 499
0 votes
2 answers
207 views

MySQL partitioning by table rows

I create a table as below CREATE TABLE `Archive_MasterLog` ( `LogID` INT(10) NOT NULL AUTO_INCREMENT, `LogDate` DATETIME NULL, `AssessorName` VARCHAR(255) NULL, `TblName` VARCHAR(100) NULL, ...
Quan Nguyen's user avatar
1 vote
1 answer
2k views

Partitions by null values with MySQL

I have a table: CREATE TABLE `NewTable` ( `IBLOCK_ELEMENT_ID` int(11) NOT NULL , `PROPERTY_1836` int(11) NULL DEFAULT NULL , `DESCRIPTION_1836` varchar(255) CHARACTER SET cp1251 ...
kot-6eremot's user avatar
1 vote
1 answer
1k views

Mysql: performance partitions in joining tables

I have a question with partitions and joining tables in MySQL. I have this sample schema: CREATE TABLE A ( `ID` BIGINT NOT NULL AUTO_INCREMENT, `NAME` varchar(50) DEFAULT NULL, PRIMARY KEY (`ID`), ...
yaki_nuka's user avatar
  • 812

15 30 50 per page