sql
stringlengths
6
1.05M
<reponame>dram/metasfresh<gh_stars>1000+ -- 2020-07-22T09:24:50.071Z -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator UPDATE AD_Ref_Table SET WhereClause='( -- product as component EXISTS(SELECT 1 from PP_Product_BOMLine pbl where pbl.PP_Product_BOM_ID = PP_Product_BOM.PP_Product_BOM_ID AND pbl.M_Product_ID = @M_Product_ID / -1@) OR -- product as finished good (PP_Product_BOM.M_Product_ID = @M_Product_ID / -1@) )',Updated=TO_TIMESTAMP('2020-07-22 12:24:50','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Reference_ID=541135 ; -- 2020-07-22T09:33:43.073Z -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator UPDATE AD_Table SET IsEnableRemoteCacheInvalidation='Y',Updated=TO_TIMESTAMP('2020-07-22 12:33:43','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Table_ID=53018 ; -- 2020-07-22T09:43:02.534Z -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator UPDATE AD_Ref_Table SET EntityType='D',Updated=TO_TIMESTAMP('2020-07-22 12:43:02','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Reference_ID=540272 ; -- 2020-07-22T10:01:57.375Z -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator UPDATE AD_Ref_Table SET WhereClause='( EXISTS(SELECT 1 from PP_Product_BOMLine pbl where pbl.PP_Product_BOM_ID = PP_Product_BOM.PP_Product_BOM_ID AND pbl.M_Product_ID = @M_Product_ID / -1@) OR (PP_Product_BOM.M_Product_ID = @M_Product_ID / -1@) )',Updated=TO_TIMESTAMP('2020-07-22 13:01:57','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Reference_ID=541135 ;
<reponame>Mariocoleguilla/Plainer -- phpMyAdmin SQL Dump -- version 4.9.5 -- https://www.phpmyadmin.net/ -- -- Servidor: localhost:3306 -- Tiempo de generación: 24-05-2021 a las 15:38:17 -- Versión del servidor: 10.4.11-MariaDB -- Versión de PHP: 7.3.23 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; /*!40101 SET NAMES utf8mb4 */; -- -- Base de datos: `id5412417_plainer` -- -- -------------------------------------------------------- -- -- Estructura de tabla para la tabla `users` -- CREATE TABLE `users` ( `user` varchar(30) COLLATE utf8_unicode_ci NOT NULL, `password` varchar(255) COLLATE utf8_unicode_ci NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Volcado de datos para la tabla `users` -- INSERT INTO `users` (`user`, `password`) VALUES ('admin', <PASSWORD>'); COMMIT; /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */; /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
DELIMITER / CREATE TABLE UNIT_FORMULATED_COST ( UNIT_FORMULATED_COST_ID DECIMAL(12,0), FORMULATED_TYPE_CODE VARCHAR(3) NOT NULL, UNIT_NUMBER VARCHAR(8) NOT NULL, UNIT_COST DECIMAL(12,2) NOT NULL, UPDATE_TIMESTAMP DATE NOT NULL, UPDATE_USER VARCHAR(60) NOT NULL, VER_NBR DECIMAL(8,0) DEFAULT 1 NOT NULL, OBJ_ID VARCHAR(36) NOT NULL ) / ALTER TABLE UNIT_FORMULATED_COST ADD CONSTRAINT PK_UNIT_FORMULATED_COST PRIMARY KEY (UNIT_FORMULATED_COST_ID) / DELIMITER ;
CREATE DATABASE spbank; \connect spbank; CREATE TABLE cliente( id INTEGER PRIMARY KEY, nombre VARCHAR(30), apellido_p VARCHAR(30), apellido_m VARCHAR(30), direccion VARCHAR(30), telefono VARCHAR(30), correo VARCHAR(30), contrasenia VARCHAR(30) ); CREATE TABLE cuenta( id INTEGER PRIMARY KEY, cliente_id INTEGER, fecha_apertura TIMESTAMP, fecha_cierre TIMESTAMP, credito FLOAT, debito FLOAT, saldo FLOAT, tipo_cuenta VARCHAR(30), FOREIGN KEY (cliente_id) REFERENCES cliente(id) ); CREATE TABLE movimiento( id INTEGER PRIMARY KEY, cliente_id INTEGER, cuenta_id INTEGER, monto FLOAT, fecha TIMESTAMP, referencia TIMESTAMP, estatus VARCHAR(30), tipo_movimiento VARCHAR(30), FOREIGN KEY (cliente_id) REFERENCES cliente(id), FOREIGN KEY (cuenta_id) REFERENCES cuenta(id) );
<reponame>bono-cms/Polls<filename>Storage/MySQL/schema.sql /* Categories */ DROP TABLE IF EXISTS `bono_module_polls_categories`; CREATE TABLE `bono_module_polls_categories` ( `id` INT NOT NULL PRIMARY KEY AUTO_INCREMENT, `lang_id` INT NOT NULL, `name` varchar(254) NOT NULL, `active` varchar(1) NOT NULL, `class` varchar(50) NOT NULL, FOREIGN KEY (lang_id) REFERENCES bono_module_cms_languages(id) ON DELETE CASCADE ) ENGINE = InnoDB DEFAULT CHARSET = UTF8; DROP TABLE IF EXISTS `bono_module_polls_answers`; CREATE TABLE `bono_module_polls_answers` ( `id` INT NOT NULL PRIMARY KEY AUTO_INCREMENT, `lang_id` INT NOT NULL, `category_id` INT NOT NULL COMMENT 'Associciated category id', `title` varchar(50) NOT NULL COMMENT 'Answer title`', `order` INT NOT NULL COMMENT 'Sorting order', `published` varchar(1) NOT NULL COMMENT 'Boolean value indicated published state', `votes` INT NOT NULL COMMENT 'Vote count', FOREIGN KEY (lang_id) REFERENCES bono_module_cms_languages(id) ON DELETE CASCADE, FOREIGN KEY (category_id) REFERENCES bono_module_polls_categories(id) ON DELETE CASCADE ) DEFAULT CHARSET=UTF8; DROP TABLE IF EXISTS `bono_module_polls_web_page_answers`; CREATE TABLE `bono_module_polls_web_page_answers` ( `id` INT NOT NULL PRIMARY KEY AUTO_INCREMENT, `lang_id` INT NOT NULL, `web_page_id` INT NOT NULL COMMENT 'Attached Web Page ID', `title` varchar(50) NOT NULL COMMENT 'Answer title', `order` INT NOT NULL COMMENT 'Sorting order', `published` BOOLEAN NOT NULL COMMENT 'Boolean value indicated published state', `votes` INT NOT NULL COMMENT 'Vote count', FOREIGN KEY (lang_id) REFERENCES bono_module_cms_languages(id) ON DELETE CASCADE, FOREIGN KEY (web_page_id) REFERENCES bono_module_cms_webpages(id) ON DELETE CASCADE ) DEFAULT CHARSET=UTF8 ENGINE = InnoDB; DROP TABLE IF EXISTS `bono_module_polls_web_page_votes`; CREATE TABLE `bono_module_polls_web_page_votes` ( `web_page_id` INT NOT NULL COMMENT 'Attached Web Page ID', `user_ip` varchar(30) NOT NULL, FOREIGN KEY (web_page_id) REFERENCES bono_module_cms_webpages(id) ON DELETE CASCADE ) DEFAULT CHARSET=UTF8 ENGINE = InnoDB; DROP TABLE IF EXISTS `bono_module_polls_web_page_settings`; CREATE TABLE `bono_module_polls_web_page_settings` ( `id` INT NOT NULL PRIMARY KEY AUTO_INCREMENT, `web_page_id` INT NOT NULL COMMENT 'Attached Web Page ID', `lang_id` INT NOT NULL COMMENT 'Attached language ID', `published` BOOLEAN NOT NULL COMMENT 'Whether this poll on the webpage is enabled', `name` varchar(255) NOT NULL COMMENT 'Poll name', FOREIGN KEY (web_page_id) REFERENCES bono_module_cms_webpages(id) ON DELETE CASCADE, FOREIGN KEY (lang_id) REFERENCES bono_module_cms_languages(id) ON DELETE CASCADE ) DEFAULT CHARSET=UTF8 ENGINE = InnoDB; DROP TABLE IF EXISTS `bono_module_polls_votes`; CREATE TABLE `bono_module_polls_votes` ( `category_id` INT NOT NULL, `user_ip` varchar(30) NOT NULL, FOREIGN KEY (category_id) REFERENCES bono_module_polls_categories(id) ON DELETE CASCADE ) ENGINE = InnoDB DEFAULT CHARSET = UTF8;
<gh_stars>0 create table if not exists b_workflow_document ( ID int(18) not null auto_increment, STATUS_ID int(18) not null default '0', DATE_ENTER datetime, DATE_MODIFY datetime, DATE_LOCK datetime, ENTERED_BY int(18), MODIFIED_BY int(18), LOCKED_BY int(18), FILENAME varchar(255) not null, SITE_ID char(2), TITLE varchar(255), BODY longtext, BODY_TYPE varchar(4) not null default 'html', PROLOG longtext, EPILOG longtext, COMMENTS text, primary key (ID)); create table if not exists b_workflow_file ( ID int(18) not null auto_increment, DOCUMENT_ID int(18) default '0', TIMESTAMP_X datetime, MODIFIED_BY int(18), TEMP_FILENAME varchar(255), FILENAME varchar(255), FILESIZE int(18), primary key (ID), unique IX_TEMP_FILENAME (TEMP_FILENAME)); create table if not exists b_workflow_log ( ID int(18) not null auto_increment, DOCUMENT_ID int(18) not null default '0', TIMESTAMP_X datetime, MODIFIED_BY int(18), TITLE varchar(255), FILENAME varchar(255), SITE_ID char(2), BODY longtext, BODY_TYPE varchar(4) not null default 'html', STATUS_ID int(18) not null default '0', COMMENTS text, primary key (ID), index IX_DOCUMENT_ID (DOCUMENT_ID)); create table if not exists b_workflow_move ( ID int(18) not null auto_increment, TIMESTAMP_X datetime not null default '0000-00-00 00:00:00', DOCUMENT_ID int(18), IBLOCK_ELEMENT_ID int(18), OLD_STATUS_ID int(18) not null default '0', STATUS_ID int(18) not null default '0', LOG_ID int(18), USER_ID int(18), primary key (ID), index IX_DOCUMENT_ID (DOCUMENT_ID)); create table if not exists b_workflow_preview ( ID int(18) not null auto_increment, DOCUMENT_ID int(18) not null default '0', TIMESTAMP_X datetime, FILENAME varchar(255), primary key (ID)); create table if not exists b_workflow_status ( ID int(18) not null auto_increment, TIMESTAMP_X timestamp, C_SORT int(18) default '100', ACTIVE char(1) not null default 'Y', TITLE varchar(255) not null, DESCRIPTION text, IS_FINAL char(1) not null default 'N', NOTIFY char(1) not null default 'Y', primary key (ID)); create table if not exists b_workflow_status2group ( ID int(18) not null auto_increment, STATUS_ID int(18) not null default '0', GROUP_ID int(18) not null default '0', PERMISSION_TYPE int(18) not null default '0', primary key (ID), index IX_STATUS_ID (STATUS_ID));
<gh_stars>0 create table PETCLINIC_CAT ( ID varchar(36) not null, -- CLAW_LENGTH integer, -- primary key (ID) );
<reponame>shinomontaz/techtree<filename>back/migrations/1_init.sql DROP TABLE IF EXISTS projects CASCADE; CREATE TABLE projects ( id SERIAL PRIMARY KEY, name VARCHAR(256) NOT NULL, created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); DROP TABLE IF EXISTS steps CASCADE; CREATE TABLE steps ( id SERIAL PRIMARY KEY, name VARCHAR(256) NOT NULL, fk_project INTEGER REFERENCES projects(id) ON DELETE CASCADE ON UPDATE CASCADE, fk_parent INTEGER REFERENCES steps(id) ON DELETE SET NULL, created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP, planned_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP, finished_at TIMESTAMP, is_finished BOOLEAN NOT NULL DEFAULT FALSE ); DROP TABLE IF EXISTS incomes CASCADE; CREATE TABLE incomes ( fk_project INTEGER REFERENCES projects(id) ON DELETE CASCADE ON UPDATE CASCADE, created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP, sum REAL ); DROP TABLE IF EXISTS activity CASCADE; CREATE TABLE activity ( fk_step INTEGER NOT NULL REFERENCES projects(id) ON DELETE CASCADE ON UPDATE CASCADE, created_at TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP, spent SMALLINT NOT NULL DEFAULT 0 );
USE ota; DROP TABLE IF EXISTS Zone; CREATE TABLE Zone ( -- Record ID ZoneId int unsigned AUTO_INCREMENT PRIMARY KEY, InstrumentId int unsigned NOT NULL, TimeframeId int unsigned NOT NULL, -- Zone Foreign Records BidAskId int unsigned NOT NULL, ColorChangeId int unsigned NOT NULL, FormationId int unsigned NOT NULL, SupplyDemandId int unsigned NOT NULL, -- Zone info FirstCandleStart DATETIME NOT NULL, LastCandleStart DATETIME NOT NULL, ZoneOpen decimal(9,5) NOT NULL, ZoneClose decimal(9,5) NOT NULL, ZoneHigh decimal(9,5) NOT NULL, ZoneLow decimal(9,5) NOT NULL, ZoneWidth int unsigned NOT NULL, Proximal decimal(9,5) NOT NULL, ProximalWickArea decimal(9,5) NOT NULL, Distal decimal(9,5) NOT NULL, DistalWickArea decimal(9,5) NOT NULL, ProximalBodyStdDev decimal(9,5) NOT NULL, ProximalWickStdDev decimal(9,5) NOT NULL, DistalBodyStdDev decimal(9,5) NOT NULL, DistalWickStdDev decimal(9,5) NOT NULL, -- Leg In LegInFirstCandleStart DATETIME NOT NULL, LegInLastCandleStart DATETIME NOT NULL, LegInDirectionId int unsigned NOT NULL, LegInOpen decimal(9,5) NOT NULL, LegInClose decimal(9,5) NOT NULL, LegInHigh decimal(9,5) NOT NULL, LegInLow decimal(9,5) NOT NULL, LegInWidth int unsigned NOT NULL, LegInBodyArea decimal(13,5) NOT NULL, LegInWickArea decimal(13,5) NOT NULL, LegInBodyHigh decimal(9,5) NOT NULL, LegInBodyLow decimal(9,5) NOT NULL, LegInVelocity decimal(11,5) NOT NULL, -- Base BaseFirstCandleStart DATETIME, BaseLastCandleStart DATETIME, BaseDirectionId int unsigned, BaseOpen decimal(9,5), BaseClose decimal(9,5), BaseHigh decimal(9,5), BaseLow decimal(9,5), BaseWidth int unsigned, BaseBodyArea decimal(13,5), BaseWickArea decimal(13,5), BaseBodyHigh decimal(9,5), BaseBodyLow decimal(9,5), BaseVelocity decimal(11,5), -- Leg Out LegOutFirstCandleStart DATETIME NOT NULL, LegOutLastCandleStart DATETIME NOT NULL, LegOutDirectionId int unsigned NOT NULL, LegOutOpen decimal(9,5) NOT NULL, LegOutClose decimal(9,5) NOT NULL, LegOutHigh decimal(9,5) NOT NULL, LegOutLow decimal(9,5) NOT NULL, LegOutWidth int unsigned NOT NULL, LegOutBodyArea decimal(13,5) NOT NULL, LegOutWickArea decimal(13,5) NOT NULL, LegOutBodyHigh decimal(9,5) NOT NULL, LegOutBodyLow decimal(9,5) NOT NULL, LegOutVelocity decimal(11,5) NOT NULL, -- LegInRangeSize decimal(11,5) NOT NULL, = LegInHigh - LegInLow -- LegInBodySize decimal(11,5) NOT NULL, = ABS(LegInOpen - LegInClose) -- LegInBodyPercent decimal(9,5) NOT NULL, = LegInBodySize / LegInRangeSize -- LegInWickSize decimal(9,5) NOT NULL, = LegInRangeSize - LegInBodySize -- LegInProximalWick decimal(9,5) NOT NULL, -- LegInDistalWick decimal(9,5) NOT NULL, -- LegInProximalWickArea decimal(13,5) NOT NULL, -- LegInDistalWickArea decimal(13,5) NOT NULL, -- LegInBodyAreaPercent decimal(9,5) NOT NULL, = LegInBodyArea / LegInRangeArea -- LegInWickAreaPercent decimal(9,5) NOT NULL, = LegInWickArea / LegInRangeArea -- LegInProximalWickAreaPercent decimal(9,5) NOT NULL, = LegInProximalWickArea / LegInRangeArea -- LegInDistalWickAreaPercent decimal(9,5) NOT NULL, = LegInDistalWickArea / LegInRangeArea -- LegInStart DATETIME NOT NULL, FOREIGN KEY (InstrumentId) REFERENCES Instrument(InstrumentId), FOREIGN KEY (TimeframeId) REFERENCES Timeframe(TimeframeId), FOREIGN KEY (FormationId) REFERENCES Formation(FormationId), FOREIGN KEY (SupplyDemandId) REFERENCES SupplyDemand(SupplyDemandId), FOREIGN KEY (ColorChangeId) REFERENCES ColorChange(ColorChangeId), FOREIGN KEY (LegInDirectionId) REFERENCES Direction(DirectionId), FOREIGN KEY (BaseDirectionId) REFERENCES Direction(DirectionId), FOREIGN KEY (LegOutDirectionId) REFERENCES Direction(DirectionId), INDEX(InstrumentId, TimeframeId, FirstCandleStart), INDEX(InstrumentId, TimeframeId, LastCandleStart) )
/* ################################################################################ Migration script to drop the STUDY_SNP table, a legacy table left over from the initial migration author: <NAME> date: January 25th 2017 version: 2.2.0.020 ################################################################################ */ -------------------------------------------------------- -- Remove STUDY_SNP -------------------------------------------------------- DROP TABLE STUDY_SNP;
<filename>fixtures/doctests/unaccent/004/input.sql SELECT unaccent('unaccent', 'H&ocirc;tel'); SELECT unaccent('H&ocirc;tel');
<filename>sql/_01_object/_08_primary_foreign_key/_002_alter/cases/1001.sql --add and drop primary key for created classes and select the class information and then drop classes create class aoo ( a int primary key, b int, c int ); create class boo ( a int , b int, c int, primary key(a,b)); create class coo ( a int not null primary key, b int, c int ); create class doo ( a int not null, b string not null, c int, primary key(a,b)); alter class aoo drop constraint pk_aoo_a; alter class boo drop constraint pk_boo_a_b; alter class coo drop constraint pk_coo_a; alter class doo drop constraint pk_doo_a_b; select attr_name, is_nullable from db_attribute where class_name = 'aoo' order by 1,2; select attr_name, is_nullable from db_attribute where class_name = 'boo' order by 1,2; select attr_name, is_nullable from db_attribute where class_name = 'coo' order by 1,2; select attr_name, is_nullable from db_attribute where class_name = 'doo' order by 1,2; select * from db_index where class_name = 'aoo' order by 1,2; select * from db_index where class_name = 'boo' order by 1,2; select * from db_index where class_name = 'coo' order by 1,2; select * from db_index where class_name = 'doo' order by 1,2; alter class aoo add primary key(a); alter class boo add primary key(a,b,c); select attr_name, is_nullable from db_attribute where class_name = 'aoo' order by 1,2; select * from db_index where class_name = 'aoo'; select attr_name, is_nullable from db_attribute where class_name = 'boo' order by 1,2; select * from db_index where class_name = 'boo' order by 1,2; alter class aoo drop constraint pk_aoo_a; alter class boo drop constraint pk_boo_a_b_c; select attr_name, is_nullable from db_attribute where class_name = 'aoo' order by 1,2; select * from db_index where class_name = 'aoo' order by 1,2; select attr_name, is_nullable from db_attribute where class_name = 'boo' order by 1,2; select * from db_index where class_name = 'boo' order by 1,2; drop aoo; drop boo; drop coo; drop doo;
<reponame>HY11053/yidiandian<filename>yidiandian.sql /* Navicat MySQL Data Transfer Source Server : 127 Source Server Type : MySQL Source Server Version : 50714 Source Host : localhost:3306 Source Schema : yidiandian Target Server Type : MySQL Target Server Version : 50714 File Encoding : 65001 Date: 25/12/2018 01:00:32 */ SET NAMES utf8mb4; SET FOREIGN_KEY_CHECKS = 0; -- ---------------------------- -- Table structure for ydd_acreagements -- ---------------------------- DROP TABLE IF EXISTS `ydd_acreagements`; CREATE TABLE `ydd_acreagements` ( `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, `type` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `created_at` timestamp(0) DEFAULT NULL, `updated_at` timestamp(0) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE, INDEX `acreagements_type_index`(`type`) USING BTREE ) ENGINE = MyISAM AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Table structure for ydd_admins -- ---------------------------- DROP TABLE IF EXISTS `ydd_admins`; CREATE TABLE `ydd_admins` ( `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, `name` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `email` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `password` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `remember_token` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `created_at` timestamp(0) DEFAULT NULL, `updated_at` timestamp(0) DEFAULT NULL, `type` int(11) NOT NULL DEFAULT 0, PRIMARY KEY (`id`) USING BTREE, UNIQUE INDEX `admins_email_unique`(`email`) USING BTREE ) ENGINE = MyISAM AUTO_INCREMENT = 2 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Records of ydd_admins -- ---------------------------- INSERT INTO `ydd_admins` VALUES (1, '梁李良', '<EMAIL>', '$<PASSWORD>', 'xUdbVYtPFo', '2018-12-16 23:00:28', '2018-12-16 23:00:28', 1); -- ---------------------------- -- Table structure for ydd_answers -- ---------------------------- DROP TABLE IF EXISTS `ydd_answers`; CREATE TABLE `ydd_answers` ( `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, `ask_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `content` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci, `goodpost` int(11) NOT NULL DEFAULT 0, `is_hidden` int(11) NOT NULL DEFAULT 0, `ip` varchar(45) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `created_at` timestamp(0) DEFAULT NULL, `updated_at` timestamp(0) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE, INDEX `answers_ask_id_index`(`ask_id`) USING BTREE, INDEX `answers_user_id_index`(`user_id`) USING BTREE, INDEX `answers_goodpost_index`(`goodpost`) USING BTREE, INDEX `answers_is_hidden_index`(`is_hidden`) USING BTREE, INDEX `answers_ip_index`(`ip`) USING BTREE ) ENGINE = MyISAM AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Table structure for ydd_archives -- ---------------------------- DROP TABLE IF EXISTS `ydd_archives`; CREATE TABLE `ydd_archives` ( `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, `typeid` int(11) NOT NULL, `ismake` int(11) NOT NULL, `brandid` int(11) DEFAULT NULL, `click` int(11) NOT NULL, `title` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `shorttitle` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `bdname` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `flags` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `tags` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `mid` int(11) NOT NULL DEFAULT 0, `keywords` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `description` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `write` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `editor` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `litpic` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `dutyadmin` smallint(6) NOT NULL, `editorid` smallint(6) DEFAULT NULL, `imagepics` mediumtext CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci, `body` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci, `published_at` timestamp(0) DEFAULT NULL, `created_at` timestamp(0) DEFAULT NULL, `updated_at` timestamp(0) DEFAULT NULL, `url` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE, UNIQUE INDEX `archives_url_unique`(`url`) USING BTREE, INDEX `archives_click_index`(`click`) USING BTREE, INDEX `archives_typeid_index`(`typeid`) USING BTREE, INDEX `archives_title_index`(`title`) USING BTREE, INDEX `archives_shorttitle_index`(`shorttitle`) USING BTREE, INDEX `archives_flags_index`(`flags`) USING BTREE, INDEX `archives_mid_index`(`mid`) USING BTREE, INDEX `archives_write_index`(`write`) USING BTREE, INDEX `archives_dutyadmin_index`(`dutyadmin`) USING BTREE, INDEX `archives_editorid_index`(`editorid`) USING BTREE, INDEX `archives_editor_index`(`editor`) USING BTREE, INDEX `archives_published_at_index`(`published_at`) USING BTREE, INDEX `archives_created_at_index`(`created_at`) USING BTREE ) ENGINE = MyISAM AUTO_INCREMENT = 2 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Records of ydd_archives -- ---------------------------- INSERT INTO `ydd_archives` VALUES (1, 1, 1, 0, 586, '232313213213', NULL, NULL, 'p', NULL, 0, '232313213213', '2545644', '梁李良', NULL, '/storage/uploads/2018/12/25/f08612d3bdf65d50e503d8da8361bbbd.png', 1, NULL, '', '<p>2545644</p><p><br/></p>', '2018-12-16 23:08:18', '2018-12-16 23:08:18', '2018-12-25 00:46:11', NULL); -- ---------------------------- -- Table structure for ydd_arctypes -- ---------------------------- DROP TABLE IF EXISTS `ydd_arctypes`; CREATE TABLE `ydd_arctypes` ( `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, `reid` int(11) NOT NULL DEFAULT 0, `topid` int(11) NOT NULL DEFAULT 0, `sortrank` int(11) DEFAULT NULL, `typename` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `typedir` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `title` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `description` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `keywords` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `dirposition` smallint(6) NOT NULL DEFAULT 1, `is_write` int(11) NOT NULL, `real_path` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `litpic` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `typeimages` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci, `contents` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci, `mid` int(11) NOT NULL DEFAULT 1, `created_at` timestamp(0) DEFAULT NULL, `updated_at` timestamp(0) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE, INDEX `arctypes_reid_index`(`reid`) USING BTREE, INDEX `arctypes_topid_index`(`topid`) USING BTREE, INDEX `arctypes_sortrank_index`(`sortrank`) USING BTREE, INDEX `arctypes_typename_index`(`typename`) USING BTREE, INDEX `arctypes_typedir_index`(`typedir`) USING BTREE, INDEX `arctypes_real_path_index`(`real_path`) USING BTREE ) ENGINE = MyISAM AUTO_INCREMENT = 14 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Records of ydd_arctypes -- ---------------------------- INSERT INTO `ydd_arctypes` VALUES (1, 0, 0, 1, '企业品牌', 'ppjs', '212', '3232', '121212', 1, 0, 'ppjs', '', NULL, '<p>dassssssssssssssssssssss</p>', 1, '2018-12-16 23:01:48', '2018-12-25 00:50:14'); INSERT INTO `ydd_arctypes` VALUES (2, 0, 0, 2, '产品中心', 'productions', '产品中心', '产品中心', '产品中心', 1, 1, 'productions', '', NULL, NULL, 0, '2018-12-24 23:54:53', '2018-12-24 23:54:53'); INSERT INTO `ydd_arctypes` VALUES (3, 0, 0, 3, '新闻动态', 'news', '新闻动态', '新闻动态', '新闻动态', 1, 1, 'news', '', NULL, NULL, 1, '2018-12-24 23:55:20', '2018-12-24 23:55:20'); INSERT INTO `ydd_arctypes` VALUES (4, 0, 0, 4, '店铺展示', 'mendian', '店铺展示', '店铺展示', '店铺展示', 1, 1, 'mendian', '', NULL, NULL, 0, '2018-12-24 23:56:04', '2018-12-24 23:56:04'); INSERT INTO `ydd_arctypes` VALUES (5, 0, 0, 5, '加盟案例', 'anlinews', '加盟案例', '加盟案例', '加盟案例', 1, 1, 'anlinews', '', NULL, NULL, 0, '2018-12-24 23:56:47', '2018-12-24 23:56:47'); INSERT INTO `ydd_arctypes` VALUES (6, 0, 0, 6, '加盟中心', 'jiameng', '加盟中心', '加盟中心', '加盟中心', 1, 1, 'jiameng', '', NULL, NULL, 0, '2018-12-24 23:57:20', '2018-12-24 23:57:20'); INSERT INTO `ydd_arctypes` VALUES (7, 0, 0, 7, '公司介绍', 'gsjs', '公司介绍', '公司介绍', '公司介绍', 1, 1, 'gsjs', '', NULL, NULL, 0, '2018-12-25 00:01:56', '2018-12-25 00:01:56'); INSERT INTO `ydd_arctypes` VALUES (8, 0, 0, 8, '投资分析', 'tznews', '投资分析', '投资分析', '投资分析', 1, 1, 'tznews', '', NULL, NULL, 0, '2018-12-25 00:03:39', '2018-12-25 00:03:39'); INSERT INTO `ydd_arctypes` VALUES (9, 0, 0, 9, '利润分析', 'lirunnews', '利润分析', '利润分析', '利润分析', 1, 1, 'lirunnews', '', NULL, NULL, 0, '2018-12-25 00:04:07', '2018-12-25 00:04:07'); INSERT INTO `ydd_arctypes` VALUES (10, 0, 0, 10, '加盟条件', 'jiamtj', '加盟条件', '加盟条件', '加盟条件', 1, 1, 'jiamtj', '', NULL, NULL, 0, '2018-12-25 00:06:02', '2018-12-25 00:06:02'); INSERT INTO `ydd_arctypes` VALUES (11, 0, 0, 11, '加盟流程', 'liucheng', '加盟流程', '加盟流程', '加盟流程', 1, 1, 'liucheng', '', NULL, NULL, 0, '2018-12-25 00:06:31', '2018-12-25 00:06:31'); INSERT INTO `ydd_arctypes` VALUES (12, 0, 0, 13, '加盟优势', 'youshi', '加盟优势', '加盟优势', '加盟优势', 1, 1, 'youshi', '', NULL, NULL, 0, '2018-12-25 00:06:53', '2018-12-25 00:06:53'); INSERT INTO `ydd_arctypes` VALUES (13, 0, 0, 14, '加盟费用', 'feiyong', '加盟费用', '加盟费用', '加盟费用', 1, 1, 'feiyong', '', NULL, NULL, 0, '2018-12-25 00:07:18', '2018-12-25 00:07:18'); -- ---------------------------- -- Table structure for ydd_areas -- ---------------------------- DROP TABLE IF EXISTS `ydd_areas`; CREATE TABLE `ydd_areas` ( `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, `parentid` int(11) NOT NULL, `regionname` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `type` int(11) NOT NULL, `created_at` timestamp(0) DEFAULT NULL, `updated_at` timestamp(0) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE, INDEX `areas_parentid_index`(`parentid`) USING BTREE, INDEX `areas_regionname_index`(`regionname`) USING BTREE, INDEX `areas_type_index`(`type`) USING BTREE ) ENGINE = MyISAM AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Table structure for ydd_asks -- ---------------------------- DROP TABLE IF EXISTS `ydd_asks`; CREATE TABLE `ydd_asks` ( `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, `user_id` int(11) NOT NULL, `title` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `body` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci, `viewnum` int(11) NOT NULL DEFAULT 0, `answernum` int(11) NOT NULL DEFAULT 0, `is_hidden` int(11) NOT NULL DEFAULT 0, `ip` varchar(45) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `tags` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `goodpost` int(11) NOT NULL DEFAULT 0, `mid` int(11) NOT NULL DEFAULT 0, `created_at` timestamp(0) DEFAULT NULL, `updated_at` timestamp(0) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE, INDEX `asks_user_id_index`(`user_id`) USING BTREE, INDEX `asks_viewnum_index`(`viewnum`) USING BTREE, INDEX `asks_answernum_index`(`answernum`) USING BTREE, INDEX `asks_is_hidden_index`(`is_hidden`) USING BTREE, INDEX `asks_goodpost_index`(`goodpost`) USING BTREE, INDEX `asks_mid_index`(`mid`) USING BTREE, INDEX `asks_ip_index`(`ip`) USING BTREE ) ENGINE = MyISAM AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Table structure for ydd_brand_types -- ---------------------------- DROP TABLE IF EXISTS `ydd_brand_types`; CREATE TABLE `ydd_brand_types` ( `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, `brandtype` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `brandname` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `created_at` timestamp(0) DEFAULT NULL, `updated_at` timestamp(0) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = MyISAM AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Table structure for ydd_brandarticles -- ---------------------------- DROP TABLE IF EXISTS `ydd_brandarticles`; CREATE TABLE `ydd_brandarticles` ( `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, `typeid` int(11) NOT NULL, `ismake` int(11) NOT NULL, `click` int(11) NOT NULL, `title` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `shorttitle` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `flags` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `tags` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `country` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `mid` int(11) NOT NULL, `keywords` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `description` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `write` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `litpic` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `dutyadmin` smallint(6) NOT NULL, `body` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci, `brandname` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `brandtime` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `brandorigin` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `brandnum` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `brandpay` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `brandarea` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `brandmap` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `brandperson` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `brandattch` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `brandapply` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `brandchat` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `brandgroup` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `brandaddr` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `brandduty` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `imagepics` mediumtext CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci, `acreage` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `genre` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `licenseno` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `registeredcapital` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `decorationpay` int(11) NOT NULL DEFAULT 0, `quartersrent` int(11) NOT NULL DEFAULT 0, `equipmentcost` int(11) NOT NULL DEFAULT 0, `workingcapital` int(11) NOT NULL DEFAULT 0, `laborquarter` int(11) NOT NULL DEFAULT 0, `miscellaneous` int(11) NOT NULL DEFAULT 0, `dailyvolume` int(11) NOT NULL DEFAULT 0, `unitprice` int(11) NOT NULL DEFAULT 0, `watercoal` int(11) NOT NULL DEFAULT 0, `ppjstitle` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `brandphone` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `brandpsp` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `published_at` timestamp(0) DEFAULT NULL, `created_at` timestamp(0) DEFAULT NULL, `updated_at` timestamp(0) DEFAULT NULL, `tzid` int(11) DEFAULT NULL, `indexpic` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `url` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `editor` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `editor_id` int(11) NOT NULL DEFAULT 0, `received_at` timestamp(0) DEFAULT NULL, `isedit` int(11) NOT NULL DEFAULT 0, PRIMARY KEY (`id`) USING BTREE, UNIQUE INDEX `brandarticles_id_unique`(`id`) USING BTREE, UNIQUE INDEX `brandarticles_url_unique`(`url`) USING BTREE, INDEX `brandarticles_brandname_index`(`brandname`) USING BTREE, INDEX `brandarticles_brandnum_index`(`brandnum`) USING BTREE, INDEX `brandarticles_brandpay_index`(`brandpay`) USING BTREE, INDEX `brandarticles_brandattch_index`(`brandattch`) USING BTREE, INDEX `brandarticles_brandapply_index`(`brandapply`) USING BTREE, INDEX `brandarticles_brandchat_index`(`brandchat`) USING BTREE, INDEX `brandarticles_tzid_index`(`tzid`) USING BTREE, INDEX `brandarticles_editor_index`(`editor`) USING BTREE, INDEX `brandarticles_editor_id_index`(`editor_id`) USING BTREE ) ENGINE = MyISAM AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Table structure for ydd_charge_histories -- ---------------------------- DROP TABLE IF EXISTS `ydd_charge_histories`; CREATE TABLE `ydd_charge_histories` ( `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, `score` int(11) NOT NULL, `group` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `operater` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `ip` varchar(45) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `created_at` timestamp(0) DEFAULT NULL, `updated_at` timestamp(0) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = MyISAM AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Table structure for ydd_comment_reversions -- ---------------------------- DROP TABLE IF EXISTS `ydd_comment_reversions`; CREATE TABLE `ydd_comment_reversions` ( `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, `comment_id` int(11) NOT NULL, `archive_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `goodpost` int(11) NOT NULL DEFAULT 0, `is_hidden` int(11) NOT NULL DEFAULT 0, `content` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `ip` varchar(45) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `created_at` timestamp(0) DEFAULT NULL, `updated_at` timestamp(0) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE, INDEX `comment_reversions_comment_id_index`(`comment_id`) USING BTREE, INDEX `comment_reversions_archive_id_index`(`archive_id`) USING BTREE, INDEX `comment_reversions_user_id_index`(`user_id`) USING BTREE, INDEX `comment_reversions_goodpost_index`(`goodpost`) USING BTREE, INDEX `comment_reversions_is_hidden_index`(`is_hidden`) USING BTREE, INDEX `comment_reversions_ip_index`(`ip`) USING BTREE ) ENGINE = MyISAM AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Table structure for ydd_comments -- ---------------------------- DROP TABLE IF EXISTS `ydd_comments`; CREATE TABLE `ydd_comments` ( `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, `archive_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `goodpost` int(11) NOT NULL DEFAULT 0, `is_hidden` int(11) NOT NULL DEFAULT 0, `content` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci, `ip` varchar(45) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `created_at` timestamp(0) DEFAULT NULL, `updated_at` timestamp(0) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE, INDEX `comments_archive_id_index`(`archive_id`) USING BTREE, INDEX `comments_user_id_index`(`user_id`) USING BTREE, INDEX `comments_goodpost_index`(`goodpost`) USING BTREE, INDEX `comments_is_hidden_index`(`is_hidden`) USING BTREE, INDEX `comments_ip_index`(`ip`) USING BTREE ) ENGINE = MyISAM AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Table structure for ydd_flinks -- ---------------------------- DROP TABLE IF EXISTS `ydd_flinks`; CREATE TABLE `ydd_flinks` ( `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, `weburl` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `webname` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `note` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `address` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `created_at` timestamp(0) DEFAULT NULL, `updated_at` timestamp(0) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = MyISAM AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Table structure for ydd_industrynews -- ---------------------------- DROP TABLE IF EXISTS `ydd_industrynews`; CREATE TABLE `ydd_industrynews` ( `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, `typeid` int(11) NOT NULL, `ismake` int(11) NOT NULL, `click` int(11) NOT NULL, `title` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `url` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `flags` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `keywords` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `description` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `write` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `litpic` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `dutyadmin` smallint(6) NOT NULL, `body` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci, `created_at` timestamp(0) DEFAULT NULL, `updated_at` timestamp(0) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE, INDEX `industrynews_click_index`(`click`) USING BTREE, INDEX `industrynews_typeid_index`(`typeid`) USING BTREE, INDEX `industrynews_title_index`(`title`) USING BTREE ) ENGINE = MyISAM AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Table structure for ydd_investment_types -- ---------------------------- DROP TABLE IF EXISTS `ydd_investment_types`; CREATE TABLE `ydd_investment_types` ( `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, `type` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `created_at` timestamp(0) DEFAULT NULL, `updated_at` timestamp(0) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE, INDEX `investment_types_type_index`(`type`) USING BTREE ) ENGINE = MyISAM AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Table structure for ydd_migrations -- ---------------------------- DROP TABLE IF EXISTS `ydd_migrations`; CREATE TABLE `ydd_migrations` ( `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, `migration` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `batch` int(11) NOT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = MyISAM AUTO_INCREMENT = 28 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Records of ydd_migrations -- ---------------------------- INSERT INTO `ydd_migrations` VALUES (1, '2014_10_12_000000_create_users_table', 1); INSERT INTO `ydd_migrations` VALUES (2, '2014_10_12_100000_create_password_resets_table', 1); INSERT INTO `ydd_migrations` VALUES (3, '2017_02_08_083651_create_archives_table', 1); INSERT INTO `ydd_migrations` VALUES (4, '2017_02_09_053555_create_arctypes_table', 1); INSERT INTO `ydd_migrations` VALUES (5, '2017_02_09_062157_create_areas_table', 1); INSERT INTO `ydd_migrations` VALUES (6, '2017_02_23_171322_create_admins_table', 1); INSERT INTO `ydd_migrations` VALUES (7, '2017_02_26_215410_create_flinks_table', 1); INSERT INTO `ydd_migrations` VALUES (8, '2017_02_28_171018_create_asks_table', 1); INSERT INTO `ydd_migrations` VALUES (9, '2017_02_28_171427_create_answers_table', 1); INSERT INTO `ydd_migrations` VALUES (10, '2017_02_28_172310_create_comments_table', 1); INSERT INTO `ydd_migrations` VALUES (11, '2017_03_03_170645_create_phonemanages_table', 1); INSERT INTO `ydd_migrations` VALUES (12, '2017_03_07_225001_create_notifications_table', 1); INSERT INTO `ydd_migrations` VALUES (13, '2017_03_26_152406_create_reversions_table', 1); INSERT INTO `ydd_migrations` VALUES (14, '2017_03_26_153436_create_comment_reversions_table', 1); INSERT INTO `ydd_migrations` VALUES (15, '2018_04_02_155121_create_brandarticles_table', 1); INSERT INTO `ydd_migrations` VALUES (16, '2018_04_13_112434_add_type_to_admins_table', 1); INSERT INTO `ydd_migrations` VALUES (17, '2018_04_19_140506_create_brand_types_table', 1); INSERT INTO `ydd_migrations` VALUES (18, '2018_04_23_175643_create_investment_types_table', 1); INSERT INTO `ydd_migrations` VALUES (19, '2018_05_11_151359_add_tzid_to_brandarticles_table', 1); INSERT INTO `ydd_migrations` VALUES (20, '2018_08_04_143727_create_acreagements_table', 1); INSERT INTO `ydd_migrations` VALUES (21, '2018_09_18_135309_add_indexpic_to_brandarticles_table', 1); INSERT INTO `ydd_migrations` VALUES (22, '2018_10_08_175528_create_charge_histories_table', 1); INSERT INTO `ydd_migrations` VALUES (23, '2018_11_22_113843_create_industrynews_table', 1); INSERT INTO `ydd_migrations` VALUES (24, '2018_11_23_171855_add_url_to_brandarticles_table', 1); INSERT INTO `ydd_migrations` VALUES (25, '2018_11_26_144458_add_editor_to_brandarticles_table', 1); INSERT INTO `ydd_migrations` VALUES (26, '2018_11_27_104444_add_url_to_archives_table', 1); INSERT INTO `ydd_migrations` VALUES (27, '2018_11_27_134243_add_isedit_to_brandarticles_table', 1); -- ---------------------------- -- Table structure for ydd_notifications -- ---------------------------- DROP TABLE IF EXISTS `ydd_notifications`; CREATE TABLE `ydd_notifications` ( `id` char(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `type` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `notifiable_id` int(10) UNSIGNED NOT NULL, `notifiable_type` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `data` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `read_at` timestamp(0) DEFAULT NULL, `created_at` timestamp(0) DEFAULT NULL, `updated_at` timestamp(0) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE, INDEX `notifications_notifiable_id_notifiable_type_index`(`notifiable_id`, `notifiable_type`) USING BTREE ) ENGINE = MyISAM CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Records of ydd_notifications -- ---------------------------- INSERT INTO `ydd_notifications` VALUES ('65d13451-66e9-48d5-9eae-43785ccf2c82', 'App\\Notifications\\ArticlePublishedNofication', 1, 'App\\AdminModel\\Admin', '{\"title\":\"232313213213\",\"write\":\"\\u6881\\u674e\\u826f\",\"time\":{\"date\":\"2018-12-16 23:08:18.000000\",\"timezone_type\":3,\"timezone\":\"PRC\"}}', NULL, '2018-12-16 23:08:18', '2018-12-16 23:08:18'); -- ---------------------------- -- Table structure for ydd_password_resets -- ---------------------------- DROP TABLE IF EXISTS `ydd_password_resets`; CREATE TABLE `ydd_password_resets` ( `email` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `token` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `created_at` timestamp(0) DEFAULT NULL, INDEX `password_resets_email_index`(`email`) USING BTREE, INDEX `password_resets_token_index`(`token`) USING BTREE ) ENGINE = MyISAM CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Table structure for ydd_phonemanages -- ---------------------------- DROP TABLE IF EXISTS `ydd_phonemanages`; CREATE TABLE `ydd_phonemanages` ( `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, `phoneno` varchar(500) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `name` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `gender` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT '', `address` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT '', `ip` varchar(45) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `note` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `host` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `referer` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci, `category` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci, `cid` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci, `brandname` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci, `created_at` timestamp(0) DEFAULT NULL, `updated_at` timestamp(0) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE, INDEX `phonemanages_phoneno_index`(`phoneno`(250)) USING BTREE ) ENGINE = MyISAM AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Table structure for ydd_reversions -- ---------------------------- DROP TABLE IF EXISTS `ydd_reversions`; CREATE TABLE `ydd_reversions` ( `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, `ask_id` int(11) NOT NULL, `answer_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `content` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `goodpost` int(11) NOT NULL, `is_hidden` int(11) NOT NULL DEFAULT 0, `created_at` timestamp(0) DEFAULT NULL, `updated_at` timestamp(0) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE, INDEX `reversions_ask_id_index`(`ask_id`) USING BTREE, INDEX `reversions_answer_id_index`(`answer_id`) USING BTREE, INDEX `reversions_user_id_index`(`user_id`) USING BTREE, INDEX `reversions_goodpost_index`(`goodpost`) USING BTREE, INDEX `reversions_is_hidden_index`(`is_hidden`) USING BTREE ) ENGINE = MyISAM AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Table structure for ydd_users -- ---------------------------- DROP TABLE IF EXISTS `ydd_users`; CREATE TABLE `ydd_users` ( `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, `name` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `email` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `password` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL, `mobilephone` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `group` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `brandname` varchar(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `score` int(11) NOT NULL DEFAULT 0, `remain_score` int(11) NOT NULL DEFAULT 0, `total_score` int(11) NOT NULL DEFAULT 0, `remember_token` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, `created_at` timestamp(0) DEFAULT NULL, `updated_at` timestamp(0) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE, UNIQUE INDEX `users_email_unique`(`email`) USING BTREE ) ENGINE = MyISAM AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic; SET FOREIGN_KEY_CHECKS = 1;
-- phpMyAdmin SQL Dump -- version 4.7.0 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: 17 Nov 2019 pada 05.08 -- Versi Server: 10.1.22-MariaDB -- PHP Version: 7.1.4 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; /*!40101 SET NAMES utf8mb4 */; -- -- Database: `db_monitoringspbu` -- -- -------------------------------------------------------- -- -- Struktur dari tabel `admin_control` -- CREATE TABLE `admin_control` ( `id` int(5) NOT NULL, `nama` varchar(100) NOT NULL, `jabatan` int(5) NOT NULL, `userId` varchar(10) NOT NULL, `password` varchar(50) NOT NULL, `createdBy` int(5) NOT NULL, `createdDate` datetime NOT NULL, `modifiedBy` int(5) NOT NULL, `modifiedDate` datetime NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=latin1; -- -- Dumping data untuk tabel `admin_control` -- INSERT INTO `admin_control` (`id`, `nama`, `jabatan`, `userId`, `password`, `createdBy`, `createdDate`, `modifiedBy`, `modifiedDate`) VALUES (1, 'ican', 1, 'ican', '<PASSWORD>', 0, '2019-11-14 00:00:00', 0, '2019-11-14 00:00:00'); -- -------------------------------------------------------- -- -- Struktur dari tabel `admin_hakaksescontrol` -- CREATE TABLE `admin_hakaksescontrol` ( `id` int(5) NOT NULL, `idAdmin` int(5) NOT NULL, `idMenu` int(5) NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=latin1; -- -------------------------------------------------------- -- -- Struktur dari tabel `mst_dispenser` -- CREATE TABLE `mst_dispenser` ( `id` int(5) NOT NULL, `idBahanBakar` int(5) NOT NULL, `namaDispenser` varchar(20) NOT NULL, `createdBy` int(5) NOT NULL, `createdDate` datetime NOT NULL, `modifiedBy` int(5) NOT NULL, `modifiedDate` datetime NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=latin1; -- -- Dumping data untuk tabel `mst_dispenser` -- INSERT INTO `mst_dispenser` (`id`, `idBahanBakar`, `namaDispenser`, `createdBy`, `createdDate`, `modifiedBy`, `modifiedDate`) VALUES (1, 1, 'mesin 1a', 0, '2019-11-14 00:00:00', 0, '2019-11-14 00:00:00'); -- -------------------------------------------------------- -- -- Struktur dari tabel `mst_jabatan` -- CREATE TABLE `mst_jabatan` ( `id` int(5) NOT NULL, `jabatan` varchar(20) NOT NULL, `createdBy` int(5) NOT NULL, `createdDate` datetime NOT NULL, `modifiedBy` int(5) NOT NULL, `modifiedDate` datetime NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=latin1; -- -- Dumping data untuk tabel `mst_jabatan` -- INSERT INTO `mst_jabatan` (`id`, `jabatan`, `createdBy`, `createdDate`, `modifiedBy`, `modifiedDate`) VALUES (1, 'super admin', 0, '2019-11-14 00:00:00', 0, '2019-11-14 00:00:00'); -- -------------------------------------------------------- -- -- Struktur dari tabel `mst_jenisbahanbakar` -- CREATE TABLE `mst_jenisbahanbakar` ( `id` int(5) NOT NULL, `namaBahanBakar` varchar(20) NOT NULL, `status` int(5) NOT NULL, `createdBy` int(5) NOT NULL, `createdDate` datetime NOT NULL, `modifiedBy` int(5) NOT NULL, `modifiedDate` datetime NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=latin1; -- -- Dumping data untuk tabel `mst_jenisbahanbakar` -- INSERT INTO `mst_jenisbahanbakar` (`id`, `namaBahanBakar`, `status`, `createdBy`, `createdDate`, `modifiedBy`, `modifiedDate`) VALUES (1, 'pertamax', 1, 0, '2019-11-14 00:00:00', 0, '2019-11-14 00:00:00'); -- -------------------------------------------------------- -- -- Struktur dari tabel `mst_karyawan` -- CREATE TABLE `mst_karyawan` ( `id` int(5) NOT NULL, `nama` varchar(100) NOT NULL, `jenisKelamin` varchar(10) NOT NULL, `alamat` text NOT NULL, `agama` varchar(10) NOT NULL, `pendidikanTerakhir` varchar(10) NOT NULL, `tanggalLahir` date NOT NULL, `tanggalMulaiKerja` datetime NOT NULL, `tanggalBerhentiKerja` datetime NOT NULL, `status` int(5) NOT NULL, `createdBy` int(5) NOT NULL, `createdDate` datetime NOT NULL, `modifiedBy` int(5) NOT NULL, `modifiedDate` datetime NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=latin1; -- -- Dumping data untuk tabel `mst_karyawan` -- INSERT INTO `mst_karyawan` (`id`, `nama`, `jenisKelamin`, `alamat`, `agama`, `pendidikanTerakhir`, `tanggalLahir`, `tanggalMulaiKerja`, `tanggalBerhentiKerja`, `status`, `createdBy`, `createdDate`, `modifiedBy`, `modifiedDate`) VALUES (1, 'karyawan 1', 'Laki-Laki', 'gadog', 'islam', 'SMA', '2019-11-01', '2019-11-02 00:00:00', '2019-11-03 00:00:00', 1, 0, '2019-11-02 00:00:00', 0, '2019-11-03 00:00:00'); -- -------------------------------------------------------- -- -- Struktur dari tabel `mst_menu` -- CREATE TABLE `mst_menu` ( `id` int(5) NOT NULL, `namaMenu` varchar(20) NOT NULL, `parentMenu` int(5) NOT NULL, `childMenu` int(5) NOT NULL, `createdBy` int(5) NOT NULL, `createdDate` datetime NOT NULL, `modifiedBy` int(5) NOT NULL, `modifiedDate` datetime NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=latin1; -- -------------------------------------------------------- -- -- Struktur dari tabel `tr_dispenser` -- CREATE TABLE `tr_dispenser` ( `id` int(5) NOT NULL, `idDispenser` int(5) NOT NULL, `idStokGudang` int(5) NOT NULL, `jumlahLiter` decimal(20,0) NOT NULL, `hargaJual` decimal(20,0) NOT NULL, `idShiftKerja` int(5) NOT NULL, `tanggalKerja` datetime NOT NULL, `literTerjual` decimal(20,0) NOT NULL, `hargaLiterTerjual` decimal(20,0) NOT NULL, `createdBy` int(5) NOT NULL, `createdDate` datetime NOT NULL, `modifiedBy` int(5) NOT NULL, `modifiedDate` datetime NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=latin1; -- -------------------------------------------------------- -- -- Struktur dari tabel `tr_stokgudang` -- CREATE TABLE `tr_stokgudang` ( `id` int(5) NOT NULL, `idStokGudang` int(5) NOT NULL, `tanggalMasuk` datetime NOT NULL, `jumlahLiter` decimal(20,0) NOT NULL, `stokTangkiLama` decimal(20,0) NOT NULL, `stokTangki` decimal(20,0) NOT NULL, `hargaMentah` decimal(20,0) NOT NULL, `hargaMentahTotal` decimal(20,0) NOT NULL, `hargaJual` decimal(20,0) NOT NULL, `createdBy` int(5) NOT NULL, `createdDate` datetime NOT NULL, `modifiedBy` int(5) NOT NULL, `modifiedDate` datetime NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=latin1; -- -- Indexes for dumped tables -- -- -- Indexes for table `admin_control` -- ALTER TABLE `admin_control` ADD PRIMARY KEY (`id`), ADD UNIQUE KEY `userId` (`userId`); -- -- Indexes for table `admin_hakaksescontrol` -- ALTER TABLE `admin_hakaksescontrol` ADD PRIMARY KEY (`id`); -- -- Indexes for table `mst_dispenser` -- ALTER TABLE `mst_dispenser` ADD PRIMARY KEY (`id`); -- -- Indexes for table `mst_jabatan` -- ALTER TABLE `mst_jabatan` ADD PRIMARY KEY (`id`); -- -- Indexes for table `mst_jenisbahanbakar` -- ALTER TABLE `mst_jenisbahanbakar` ADD PRIMARY KEY (`id`) USING BTREE; -- -- Indexes for table `mst_karyawan` -- ALTER TABLE `mst_karyawan` ADD PRIMARY KEY (`id`); -- -- Indexes for table `mst_menu` -- ALTER TABLE `mst_menu` ADD PRIMARY KEY (`id`); -- -- Indexes for table `tr_dispenser` -- ALTER TABLE `tr_dispenser` ADD PRIMARY KEY (`id`); -- -- Indexes for table `tr_stokgudang` -- ALTER TABLE `tr_stokgudang` ADD PRIMARY KEY (`id`); -- -- AUTO_INCREMENT for dumped tables -- -- -- AUTO_INCREMENT for table `admin_control` -- ALTER TABLE `admin_control` MODIFY `id` int(5) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; -- -- AUTO_INCREMENT for table `admin_hakaksescontrol` -- ALTER TABLE `admin_hakaksescontrol` MODIFY `id` int(5) NOT NULL AUTO_INCREMENT; -- -- AUTO_INCREMENT for table `mst_dispenser` -- ALTER TABLE `mst_dispenser` MODIFY `id` int(5) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; -- -- AUTO_INCREMENT for table `mst_jabatan` -- ALTER TABLE `mst_jabatan` MODIFY `id` int(5) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; -- -- AUTO_INCREMENT for table `mst_jenisbahanbakar` -- ALTER TABLE `mst_jenisbahanbakar` MODIFY `id` int(5) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; -- -- AUTO_INCREMENT for table `mst_karyawan` -- ALTER TABLE `mst_karyawan` MODIFY `id` int(5) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; -- -- AUTO_INCREMENT for table `mst_menu` -- ALTER TABLE `mst_menu` MODIFY `id` int(5) NOT NULL AUTO_INCREMENT; -- -- AUTO_INCREMENT for table `tr_dispenser` -- ALTER TABLE `tr_dispenser` MODIFY `id` int(5) NOT NULL AUTO_INCREMENT; -- -- AUTO_INCREMENT for table `tr_stokgudang` -- ALTER TABLE `tr_stokgudang` MODIFY `id` int(5) NOT NULL AUTO_INCREMENT;COMMIT; /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */; /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
<filename>database/init/cities/city.list067.sql insert into city values (2926941,"Fichtenwalde","DE",12.88349,52.28038), (2941403,"Burgebrach","DE",10.75,49.833328), (6552268,"Grande","DE",10.3833,53.583302), (2918121,"Grande","DE",10.38333,53.583328), (6549867,"Dankmarshausen","DE",10.0167,50.9333), (2939009,"Dankmarshausen","DE",10.01667,50.933331), (2807161,"Witzlhof","DE",11.83333,49.466671), (2920006,"Glehn","DE",6.6,50.599998), (2809726,"Widdau","DE",6.3,50.549999), (6556234,"Türkenfeld","DE",11.0833,48.116699), (2820756,"Tuerkenfeld","DE",11.08333,48.116669), (2811150,"Wengen","DE",9.91667,47.75), (2853988,"Pflugscheid","DE",6.93333,49.299999), (2944649,"Breitenborn","DE",9.26667,50.166672), (2908059,"Heide","DE",7.46667,50.883331), (2866187,"Neuberg","DE",12.4,50.48333), (6556264,"Prittriching","DE",10.9167,48.200001), (2851977,"Prittriching","DE",10.91667,48.200001), (6550204,"Geraberg","DE",10.85,50.733299), (2921228,"Geraberg","DE",10.85,50.73333), (2919917,"Glienecke","DE",12.38333,52.283329), (2953060,"Ballenstedt","DE",11.23333,51.716671), (2908877,"Hausen","DE",7.96667,50.349998), (6554374,"Sehlem","DE",6.83333,49.900002), (2833492,"Sehlem","DE",6.83333,49.900002), (6555273,"Grolsheim","DE",7.91667,49.900002), (2917157,"Grolsheim","DE",7.91667,49.900002), (2822113,"Tintrup","DE",9.0566,51.914101), (6554553,"Irrhausen","DE",6.2,50.0667), (2895764,"Irrhausen","DE",6.2,50.066669), (6554955,"Imsbach","DE",7.88333,49.583302), (2896189,"Imsbach","DE",7.88333,49.583328), (2950967,"Benteler","DE",8.33333,51.75), (2834019,"Seebach","DE",8.3,48.416672), (2891305,"Ketternschwalbach","DE",8.15,50.26667), (6552685,"Neetze","DE",10.62134,53.265202), (2866682,"Neetze","DE",10.62134,53.265209), (3208093,"Mittenaar","DE",8.33333,50.700001), (2870490,"Mittenaar","DE",8.38333,50.700001), (6552667,"Amelinghausen","DE",10.21274,53.12397), (2956584,"Amelinghausen","DE",10.21274,53.12397), (6557009,"Biebelried","DE",10.0833,49.766701), (2949276,"Biebelried","DE",10.08333,49.76667), (2927782,"Farschweiler","DE",6.81667,49.716671), (2857076,"Orlen","DE",8.18333,50.183331), (2841619,"<NAME>","DE",8.33333,48.133331), (2906269,"Heppendorf","DE",6.63333,50.916672), (2919630,"Göbitz","DE",12.18333,51.083328), (2879964,"Lauter","DE",12.73333,50.566669), (2864530,"Neumolkenberg","DE",12.21122,52.684448), (2833990,"<NAME>","DE",14.2,53.933331), (6557015,"Rödelsee","DE",10.25,49.733299), (2846084,"Rodelsee","DE",10.25,49.73333), (2875696,"Lövenich","DE",6.66667,50.683331), (6552128,"Rickling","DE",10.1667,54.016701), (2847429,"Rickling","DE",10.16667,54.01667), (6549759,"Breitenworbis","DE",10.3433,51.449902), (2944516,"Breitenworbis","DE",10.41667,51.400002), (2879994,"<NAME>","DE",14.06667,51.466671), (2829967,"Staad","DE",9.21667,47.683331), (2865396,"<NAME>","DE",12.88333,50.666672), (2913433,"Gustrow","DE",12.17337,53.797199), (6556619,"Illschwang","DE",11.694,49.458801), (2896523,"Illschwang","DE",11.68333,49.450001), (2842215,"Salow","DE",13.48333,53.683331), (2861670,"Nündorf","DE",13.19535,48.317619), (2943855,"Broitzem","DE",10.47718,52.234631), (6552934,"Georgsdorf","DE",7.08333,52.5667), (2921252,"Georgsdorf","DE",7.08333,52.566669), (2905215,"Hettingen","DE",9.23169,48.216011), (2919713,"Gnadau","DE",11.78333,51.98333), (2853397,"Platkow","DE",14.32282,52.584332), (2911987,"Haidlfing","DE",12.71667,48.73333), (2911250,"Hamich","DE",6.31667,50.783329), (2927958,"Falkenhain","DE",13.6,51.933331), (2882260,"Kusey","DE",11.08333,52.566669), (2862988,"Niederpoyritz","DE",13.84058,51.032269), (2883026,"Kugelreuth","DE",12.11667,50.333328), (6555455,"Deggingen","DE",9.71882,48.597191), (2938538,"Deggingen","DE",9.71891,48.597099), (6555879,"Eimeldingen","DE",7.6,47.633301), (2931827,"Eimeldingen","DE",7.6,47.633331), (2835481,"<NAME>","DE",9.73908,49.111271), (2859615,"Oberndorf","DE",7.81667,49.716671), (2925170,"Freidorf","DE",13.7,52.066669), (2907667,"Heilbrunn","DE",12.56587,49.046589), (6556694,"Thalmassing","DE",12.1667,48.916698), (2823045,"Thalmassing","DE",12.155,48.911671), (2859690,"Obernau","DE",7.61667,50.783329), (2803723,"Zulpich","DE",6.65,50.700001), (2807594,"Wipperfurth","DE",7.4,51.116669), (2848621,"Reisbach","DE",12.63333,48.566669), (2810728,"Wertach","DE",10.4,47.599998), (2923396,"Gadenstedt","DE",10.21634,52.246281), (6554249,"Müschenbach","DE",7.78333,50.6833), (2867402,"Muschenbach","DE",7.78333,50.683331), (2903818,"Hirnstetten","DE",11.28333,48.966671), (2875626,"Lubbecke","DE",8.61667,52.299999), (2920186,"Glasbach","DE",8.3,48.049999), (6555255,"Appenheim","DE",8.03333,49.93), (2955732,"Appenheim","DE",8.03333,49.93), (6554252,"Niederahr","DE",7.85,50.483299), (2863678,"Niederahr","DE",7.85,50.48333), (6553531,"Rehborn","DE",7.68333,49.733299), (2849386,"Rehborn","DE",7.68333,49.73333), (2953535,"<NAME>","DE",9.78985,50.308529), (2825916,"Strelow","DE",12.96421,54.047401), (6557056,"Euerbach","DE",10.1333,50.0667), (2928520,"Euerbach","DE",10.13695,50.061989), (3221012,"<NAME>","DE",10.41806,51.909721), (2814549,"Wallmoden","DE",10.26667,52.01667), (2947105,"Bodenstein","DE",10.22346,51.997459), (2882334,"<NAME>","DE",14.7,50.849998), (6552926,"Walchum","DE",7.28333,52.9333), (2815218,"Walchum","DE",7.28325,52.92717), (2867986,"Mühlheim","DE",8.28333,49.700001), (2959847,"Abenheim","DE",8.28111,49.677219), (2860205,"Oberholzgünz","DE",10.26667,48.01667), (2928754,"Eßleben","DE",11.46667,51.150002), (3208692,"Ganzow","DE",12.36667,53.216671), (6553512,"Mandel","DE",7.76667,49.849998), (2873989,"Mandel","DE",7.76667,49.849998), (2806914,"Wolfenbuttel","DE",10.55,52.166672), (2841375,"Sasbachwalden","DE",8.13333,48.616669), (6555781,"Fischerbach","DE",8.11667,48.283298), (2926557,"Fischerbach","DE",8.11667,48.316669), (2803768,"Zuckelhausen","DE",12.45,51.299999), (6552993,"Ostercappeln","DE",8.23333,52.349998), (2856629,"Ostercappeln","DE",8.23333,52.349998), (6552674,"<NAME>","DE",10.4333,53.200001), (2937809,"<NAME>","DE",10.43333,53.200001), (3208999,"Audenhain","DE",12.85,51.5), (2871649,"Mesenich","DE",6.51667,49.73333), (2848773,"Reinhartshausen","DE",10.73333,48.25), (2855231,"Pätz","DE",13.65,52.23333), (6548544,"Theuma","DE",12.2167,50.466702), (2822822,"Theuma","DE",12.22195,50.47007), (2835587,"Schuttorf","DE",7.23333,52.316669), (2896279,"Immenhausen","DE",9.48017,51.427631), (2948194,"Bisten","DE",6.7,49.25), (2843617,"Retz","DE",12.53333,49.349998), (6551764,"Probsteierhagen","DE",10.2833,54.366699), (2851946,"Probsteierhagen","DE",10.28333,54.366669), (6553015,"Spiekeroog","DE",7.69593,53.7705), (2830534,"Spiekeroog","DE",7.7,53.76667), (2958505,"Algershofen","DE",9.62836,48.2295), (6555729,"Auggen","DE",7.6,47.783298), (2954197,"Auggen","DE",7.6,47.783329), (2939443,"Dahlem","DE",6.68333,49.98333), (6553124,"Augustdorf","DE",8.7473,51.910999), (2954164,"Augustdorf","DE",8.73173,51.909439), (2941739,"Bult","DE",9.68333,53.116669), (2899289,"Hooksiel","DE",8.01667,53.633331), (6554659,"Rockeskyll","DE",6.7,50.25), (2846209,"Rockeskyll","DE",6.7,50.25), (6552537,"Warmsen","DE",8.85097,52.4548), (2814066,"Warmsen","DE",8.84949,52.456951), (2944939,"Brede","DE",8.85,52.333328), (6556865,"Gremsdorf","DE",10.83389,49.697948), (2917714,"Gremsdorf","DE",10.83218,49.695061), (6555688,"Enzklösterle","DE",8.48333,48.666698), (2929892,"Enzklosterle","DE",8.48333,48.666672), (2806134,"Wormsthal","DE",9.26667,52.25), (2952960,"Bandenitz","DE",11.28333,53.48333), (2829116,"Stegh","DE",6.11667,50.933331), (6549937,"Niederdorla","DE",10.45,51.150002), (2863516,"Niederdorla","DE",10.45,51.150002), (2916893,"Großburgwedel","DE",9.85757,52.49271), (6553109,"Nordwalde","DE",7.48333,52.083302), (2861847,"Nordwalde","DE",7.48333,52.083328), (2930580,"Emerkam","DE",12.43333,48.283329), (2821420,"Trebs","DE",11.11667,53.283329), (2923371,"Gagelow","DE",11.89639,53.685581), (2866238,"Neubau","DE",11.85,50.01667), (2900182,"Holteyberg","DE",7.1,51.416672), (2940447,"Byfang","DE",7.1,51.400002), (2853961,"Pfreimd","DE",12.17944,49.4925), (6553222,"Greifenstein","DE",8.3,50.616699), (2917793,"Greifenstein","DE",8.3,50.616669), (2899859,"Holzham","DE",12.16667,48.116669), (2916604,"Großenlupnitz","DE",10.41667,51), (2832240,"Siglhof","DE",12.56667,48.549999), (6554881,"Wallertheim","DE",8.05139,49.835602), (2814591,"Wallertheim","DE",8.05139,49.83556), (2865844,"<NAME>","DE",14.01667,52.200001), (6557100,"Theilheim","DE",10.0333,49.75), (2822903,"Theilheim","DE",10.03333,49.75), (2855445,"Parchen","DE",12.1,52.349998), (6548578,"Gornsdorf","DE",12.8833,50.700001), (2918951,"Gornsdorf","DE",12.88333,50.700001), (6547810,"Bartow","DE",13.35,53.8167), (2952345,"Bartow","DE",13.35,53.816669), (2898077,"Hude","DE",10.45,53.816669), (2916290,"<NAME>","DE",8.63333,53.283329), (2882093,"Laasow","DE",14.08333,51.716671), (2867571,"Munnerstadt","DE",10.18333,50.25), (2854966,"Penk","DE",12.11667,48.400002), (6548348,"Ganzlin","DE",12.25,53.383301), (2922610,"Ganzlin","DE",12.25,53.383331), (2913224,"<NAME>","DE",11.83333,48.466671), (2899264,"Hopen","DE",9.13333,54), (6550377,"Lindig","DE",11.6,50.783298), (2877158,"Lindig","DE",11.6,50.783329), (3205518,"Burgrain","DE",11.1,47.51667), (2846824,"Riethberg","DE",11.66667,52.883331), (6552715,"Basdahl","DE",9,53.450001), (2952304,"Basdahl","DE",9.00025,53.445019), (2959179,"Ahlsen","DE",8.66667,52.299999), (2877098,"Lindwerder","DE",13.03333,51.833328), (2869100,"Moschelmühle","DE",7.63333,49.283329), (2829339,"Stauf","DE",8.0275,49.551109), (2851523,"Quakenbruck","DE",7.95,52.683331), (3232585,"Hansaland","DE",10.76667,54.066669), (6548783,"Beilrode","DE",13.0667,51.5667), (2951352,"Beilrode","DE",13.06667,51.566669), (6552143,"Sülfeld","DE",10.2333,53.799999), (2824907,"Sulfeld","DE",10.23333,53.799999), (6555520,"Ittlingen","DE",8.93083,49.1908), (2895574,"Ittlingen","DE",8.93083,49.19083), (6552956,"Nortmoor","DE",7.56667,53.233299), (2861807,"Nortmoor","DE",7.56667,53.23333), (6555536,"Wüstenrot","DE",9.4661,49.096199), (2805497,"Wustenrot","DE",9.46056,49.08083), (2885020,"Kräft","DE",10.6,49.450001), (6553034,"Rheurdt","DE",6.46667,51.466702), (2847586,"Rheurdt","DE",6.46667,51.466671), (6559318,"Greimerath","DE",6.69401,49.59362), (2917776,"Greimerath","DE",6.68333,49.566669), (6556654,"Etzenricht","DE",12.1,49.633301), (2928564,"Etzenricht","DE",12.1,49.633331), (2924406,"Friesack","DE",12.57969,52.73764), (6554136,"Hartenfels","DE",7.78333,50.583302), (2910181,"Hartenfels","DE",7.78333,50.583328), (2813110,"Weida","DE",12.06667,50.76667), (2937531,"Diefenbach","DE",6.53333,50.48333), (2876846,"Lissa","DE",12.28333,51.5), (2943238,"Brunken","DE",7.76667,50.73333), (2832982,"Senzig","DE",13.66667,52.283329), (2837447,"Schneeren","DE",9.33333,52.533329), (6554068,"Mudershausen","DE",8.03333,50.283298), (2868851,"Mudershausen","DE",8.03333,50.283329), (6548763,"Großpösna","DE",12.5,51.266701), (2915173,"Grossposna","DE",12.5,51.26667), (6552021,"Grundhof","DE",9.65,54.783298), (2914347,"Grundhof","DE",9.65,54.783329), (6547805,"Wittenbeck","DE",11.7833,54.116699), (2807355,"Wittenbeck","DE",11.78333,54.116669), (6555906,"Dettighofen","DE",8.48333,47.616699), (2937906,"Dettighofen","DE",8.48333,47.616669), (2924307,"Frohlinde","DE",7.35,51.533329), (6555662,"Heddesbach","DE",8.82806,49.480301), (2908400,"Heddesbach","DE",8.82806,49.480282), (6554725,"Damflos","DE",6.98333,49.666698), (2939214,"Damflos","DE",6.98333,49.666672), (2951070,"Benken","DE",12.46667,52.166672), (2807452,"Wissel","DE",6.28333,51.76667), (6554887,"Altleiningen","DE",8.07333,49.5075), (2957040,"Altleiningen","DE",8.07333,49.5075), (6553623,"Oberhambach","DE",7.16667,49.6833), (2860488,"Oberhambach","DE",7.16667,49.683331), (2856958,"Orxhausen","DE",9.96667,51.866669), (2957688,"Altenfurt","DE",11.28333,48.549999), (2832104,"Sildemow","DE",12.13333,54.049999), (6548718,"Laußnitz","DE",13.8833,51.25), (2880001,"Laussnitz","DE",13.88333,51.25), (2807345,"<NAME>","DE",12.80528,51.812222), (6548946,"Klöden","DE",12.8333,51.766701), (2887599,"Kloden","DE",12.83169,51.76178), (2856075,"Ottensen","DE",9.91667,53.549999), (2880205,"Laudenbach","DE",9.92833,49.45472), (2918925,"Gorsleben","DE",11.75,51.533329), (6553513,"Martinstein","DE",7.53333,49.799999), (2873108,"Martinstein","DE",7.53333,49.799999), (6548676,"Hainewalde","DE",14.7,50.916698), (2911833,"Hainewalde","DE",14.7,50.916672), (2810431,"Westerbeverstedt","DE",8.75,53.433331), (6555965,"Asselfingen","DE",10.19154,48.529652), (2955025,"Asselfingen","DE",10.19166,48.529591), (2867863,"Mulda","DE",13.41667,50.799999), (6552957,"Ostrhauderfehn","DE",7.61667,53.133301), (2856213,"Ostrhauderfehn","DE",7.61667,53.133331), (2814765,"Waldthurn","DE",12.32919,49.672211), (2895285,"Jahnsdorf","DE",13.18333,50.716671), (2954989,"Asten","DE",12.11667,47.700001), (2840049,"Scheibe","DE",13.21667,50.650002), (6555842,"Gunningen","DE",8.7,48.049999), (2913631,"Gunningen","DE",8.7,48.049999), (2814841,"Waldorf","DE",6.61667,50.383331), (6553774,"Nickenich","DE",7.33333,50.416698), (2863732,"Nickenich","DE",7.32728,50.414211), (6557148,"Nordendorf","DE",10.8333,48.599998), (2862106,"Nordendorf","DE",10.8,48.599998), (2853278,"Plech","DE",11.46667,49.650002), (2904600,"Hiltpoltstein","DE",11.31667,49.666672), (2895746,"Irsching","DE",11.58333,48.76667), (2928957,"Esebeck","DE",9.85,51.566669), (6555538,"Bretzfeld","DE",9.43833,49.179401), (2944178,"Bretzfeld","DE",9.43833,49.17944), (2865913,"<NAME>","DE",11.05,53.150002), (2891041,"Kienitz","DE",14.43887,52.6731), (2818658,"Unterspiesheim","DE",10.26667,49.950001), (2950457,"Berghäuser","DE",12.33333,50.299999), (2888900,"Kleinfreden","DE",9.9,51.933331), (2923946,"Fuchshain","DE",12.53333,51.283329), (6554549,"Harspelt","DE",6.16667,50.133301), (2910273,"Harspelt","DE",6.16667,50.133331), (6547404,"Gröden","DE",13.5667,51.400002), (2917194,"Groden","DE",13.56667,51.400002), (6551743,"Kletkamp","DE",10.6333,54.25), (2887858,"Kletkamp","DE",10.63333,54.25), (6553420,"Nauroth","DE",7.86667,50.700001), (2866851,"Nauroth","DE",7.86667,50.700001), (6554477,"Niederweis","DE",6.46667,49.866699), (2862741,"Niederweis","DE",6.46717,49.869968), (2846987,"Riemke","DE",7.83333,51.383331), (2805182,"Zaschendorf","DE",13.91391,51.017429), (2852582,"Porstendorf","DE",11.93333,50.76667), (6555529,"Offenau","DE",9.16056,49.2458), (2857810,"Offenau","DE",9.16056,49.245831), (6552493,"Coppengrave","DE",9.73333,51.983299), (2939860,"Coppengrave","DE",9.73333,51.98333), (2953769,"Babenried","DE",11.16667,48.166672), (2865381,"<NAME>","DE",13.05,52.450001), (2859991,"Oberlaindern","DE",11.74001,47.875542), (2913890,"Gudensberg","DE",9.36667,51.183331), (2820211,"Ulsenheim","DE",10.3,50.566669), (6548234,"Zierow","DE",11.3667,53.9333), (2804285,"Zierow","DE",11.36667,53.933331), (2943879,"Broich","DE",6.18333,50.849998), (2813719,"Wassermungenau","DE",10.88333,49.216671), (2959855,"Abenberg","DE",10.96401,49.242821), (6553671,"Bullay","DE",7.13333,50.0667), (2941826,"Bullay","DE",7.13333,50.066669), (2864398,"Neuoelsa","DE",13.66667,50.950001), (2955269,"Aschara","DE",10.68333,51.049999), (6553160,"Rimbach","DE",8.76306,49.625), (2846754,"Rimbach","DE",8.76306,49.625), (2954168,"Augsdorf","DE",11.56667,51.599998), (2834663,"Schwatzen","DE",9.73333,47.599998), (2848199,"Rennebaum","DE",7.3,51.349998), (2824285,"Tambach-Dietharz","DE",10.61667,50.799999), (2853035,"Pogez","DE",10.93333,53.76667), (6550399,"Rothenstein","DE",11.6,50.849998), (2843978,"Rothenstein","DE",11.6,50.849998), (6552538,"Warpe","DE",9.10518,52.740398), (2814031,"Warpe","DE",9.1,52.73333), (2894958,"Jessenitz","DE",11.08744,53.26963), (2813480,"Weddersleben","DE",11.08333,51.76667), (2839394,"Schierlhof","DE",12.65,48.799999), (2847835,"Reute","DE",9.21667,47.883331), (2845903,"Rodt","DE",6.58333,49.549999), (6553212,"Rockenberg","DE",8.73333,50.4333), (2846235,"Rockenberg","DE",8.73688,50.4305), (2816062,"Vormwald","DE",9.26667,50.066669), (6551780,"Stoltenberg","DE",10.35,54.349998), (2826511,"Stoltenberg","DE",10.35,54.349998), (2868789,"Muhl","DE",7.05,49.683331), (6556547,"Kollnburg","DE",12.8667,49.049999), (2886285,"Kollnburg","DE",12.86121,49.046638), (6555341,"Merzalben","DE",7.73333,49.25), (2871703,"Merzalben","DE",7.73077,49.244671), (6553601,"Hettenrodt","DE",7.25,49.733299), (2905225,"Hettenrodt","DE",7.25,49.73333), (2820517,"Ückesdorf","DE",7.08333,50.700001), (2953502,"Badenborn","DE",6.52262,49.90691), (6555816,"Villingendorf","DE",8.58333,48.200001), (2817222,"Villingendorf","DE",8.58333,48.200001), (6557116,"Merching","DE",10.9833,48.25), (2871835,"Merching","DE",10.9853,48.245941), (2880189,"Lauenau","DE",9.36928,52.27393), (2863635,"Niederaußem","DE",6.66667,50.98333), (2843554,"Rubenow","DE",13.547,53.732059), (2852269,"Preilack","DE",14.41667,51.883331), (6554977,"Ramsen","DE",8.01333,49.5369), (2850566,"Ramsen","DE",8.01333,49.536942), (2851491,"Quassel","DE",11.08333,53.333328), (2818539,"Unterthürheim","DE",10.71667,48.599998), (2870805,"Mittelberg","DE",7.25,51.083328), (3302158,"<NAME>","DE",12.06806,52.334171), (6549333,"Biederitz","DE",11.7365,52.145401), (2949221,"Biederitz","DE",11.71667,52.150002), (2808436,"Wilsdruff","DE",13.53333,51.049999), (6556841,"Gerolfingen","DE",10.5167,49.049999), (2920969,"Gerolfingen","DE",10.51667,49.049999), (6557312,"Ofterschwang","DE",10.2333,47.5), (2857753,"Ofterschwang","DE",10.23333,47.5), (2953520,"<NAME>","DE",8.53333,48.01667), (6553483,"Dorsheim","DE",7.86667,49.916698), (2935535,"Dorsheim","DE",7.86667,49.916672), (2872824,"Mauel","DE",6.51667,50.566669), (6556473,"Hinterschmiding","DE",13.6,48.8167), (2903991,"Hinterschmiding","DE",13.6,48.816669), (6555661,"Eschelbronn","DE",8.86528,49.319401), (2929112,"Eschelbronn","DE",8.86528,49.319439), (6553921,"Lautzenhausen","DE",7.26667,49.9333), (2879861,"Lautzenhausen","DE",7.26667,49.933331), (2838201,"Schluchtern","DE",9.52532,50.348911), (2852608,"Porbitz-Poppitz","DE",12.06667,51.299999), (2891599,"Kenoden","DE",12.75,48.51667), (6553044,"Hünxe","DE",6.78333,51.650002), (2897283,"Hunxe","DE",6.78333,51.650002), (6552896,"Hilkenbrook","DE",7.7,52.983299), (2904735,"Hilkenbrook","DE",7.7,52.98333), (6552027,"Hürup","DE",9.53333,54.75), (2897211,"Hurup","DE",9.53333,54.75), (6554987,"Stahlberg","DE",7.78333,49.666698), (2829678,"Stahlberg","DE",7.78333,49.666672), (2829673,"Stahle","DE",9.42919,51.834721), (6556432,"Huglfing","DE",11.1667,47.766701), (2897991,"Huglfing","DE",11.16667,47.76667), (2943978,"Brockhagen","DE",8.35,51.98333), (6551659,"Ratekau","DE",10.7333,53.950001), (2850235,"Ratekau","DE",10.73333,53.950001), (6555676,"Reilingen","DE",8.5649,49.292252), (2848867,"Reilingen","DE",8.56417,49.298328), (2875107,"Lunen","DE",7.51667,51.616669), (6556129,"Reichersbeuern","DE",11.6333,47.766701), (2849047,"Reichersbeuern","DE",11.63333,47.76667), (6551899,"Osterrönfeld","DE",9.7018,54.283699), (2856390,"Osterronfeld","DE",9.7,54.283329), (2913838,"Guglingen","DE",8.99444,49.069721), (2949289,"Bickenriede","DE",10.35,51.25), (2809411,"Wierenkamp","DE",9.96667,53.883331), (6553278,"Oberaula","DE",9.4559,50.856499), (2861358,"Oberaula","DE",9.46667,50.849998), (2871128,"Mildstedthof","DE",9.1,54.466671), (2875983,"Lonnerstadt","DE",10.76667,49.700001), (2862893,"Niederschona","DE",13.41667,50.966671), (2874993,"Lüsse","DE",12.66667,52.150002), (2948306,"Bischofferode","DE",9.76667,51.133331), (2898341,"Hovestadt","DE",8.15,51.666672), (2926328,"Fleckl","DE",11.81667,50.01667), (6550010,"Fambach","DE",10.3601,50.754799), (2927850,"Fambach","DE",10.36667,50.73333), (2886849,"Köddingen","DE",9.2,50.616669), (2828277,"Steindamm","DE",10.56667,54), (6554788,"Riveris","DE",6.76667,49.716702), (2846307,"Riveris","DE",6.76667,49.716671), (2873481,"Marienthal","DE",13.27852,53.05468), (2890412,"Kirchmatting","DE",12.61145,48.81218), (2828121,"Steinfels","DE",12,49.666672), (6554729,"Fell","DE",6.78333,49.766701), (2927273,"Fell","DE",6.78333,49.76667), (6556780,"Effeltrich","DE",11.0908,49.662201), (2933287,"Effeltrich","DE",11.09319,49.65929), (2947817,"Bleischmelz","DE",6.7,49.833328), (2925943,"Folge","DE",14.65,50.950001), (2888635,"Kleinkorbetha","DE",12.05,51.25), (6555539,"Dörzbach","DE",9.70715,49.383461), (2935488,"Dorzbach","DE",9.70732,49.383549), (2921522,"Gelenau","DE",12.98333,50.700001), (2959330,"Afholderbach","DE",8.13333,50.933331), (6557133,"Emersacker","DE",10.6667,48.5), (2930575,"Emersacker","DE",10.66667,48.5), (2949452,"Beyersdorf","DE",12.18333,51.599998), (6555376,"Kleinsteinhausen","DE",7.46667,49.200001), (2888172,"Kleinsteinhausen","DE",7.46667,49.200001), (6553771,"Münk","DE",7.03333,50.299999), (2867583,"Munk","DE",7.03333,50.299999), (2804689,"Zetta","DE",13.33333,51.116669), (6555212,"Ramberg","DE",8.00833,49.2603), (2850722,"Ramberg","DE",8.00833,49.260281), (2911965,"Haig","DE",11.27644,50.281551), (2921346,"Genholt","DE",6.18333,51.25), (6548748,"Zschepplin","DE",12.6,51.5), (2803827,"Zschepplin","DE",12.6,51.5), (6552659,"Wulfsen","DE",10.15,53.299999), (2805891,"Wulfsen","DE",10.15,53.299999), (6551532,"Bondelum","DE",9.26667,54.5667), (2946488,"Bondelum","DE",9.26667,54.566669), (2805086,"Zeestow","DE",12.95923,52.573009), (3220802,"<NAME> an der Aisch-Bad Windsheim","DE",10.47722,49.569172), (6556901,"Ergersheim","DE",10.3333,49.516701), (2929658,"Ergersheim","DE",10.33333,49.51667), (6555956,"Ratshausen","DE",8.79511,48.193642), (2850165,"Ratshausen","DE",8.7952,48.193729), (2882366,"<NAME>","DE",11.28333,50.200001), (2851791,"Puch","DE",11.21667,48.183331), (6554132,"Girod","DE",7.91667,50.450001), (2920291,"Girod","DE",7.91667,50.450001), (6555256,"Aspisheim","DE",7.98333,49.900002), (2955053,"Aspisheim","DE",7.98333,49.900002), (2807992,"Winkelhaid","DE",10.83333,49.23333), (6553245,"Flieden","DE",9.5649,50.417099), (2926226,"Flieden","DE",9.5666,50.423889), (6551967,"Idstedt","DE",9.51667,54.583302), (2896739,"Idstedt","DE",9.51667,54.583328), (6557216,"Jengen","DE",10.7333,48), (2895034,"Jengen","DE",10.72575,47.99934), (6551902,"Owschlag","DE",9.6,54.383301), (2855820,"Owschlag","DE",9.6,54.383331), (2835359,"Schwalheim","DE",8.76667,50.349998), (2844434,"<NAME>","DE",9.71667,50.98333), (2941150,"Burgstadt","DE",12.81667,50.916672), (2867996,"Muhlhausen","DE",10.45,51.216671), (2858017,"Ödinghausen","DE",7.55,50.900002), (6554878,"Vendersheim","DE",8.06861,49.866402), (2817659,"Vendersheim","DE",8.06861,49.86639), (6555658,"Brühl","DE",8.5381,49.402699), (2943321,"Bruhl","DE",8.53361,49.397221), (6553173,"Büttelborn","DE",8.5216,49.903301), (2940633,"Buttelborn","DE",8.52333,49.903332), (2827988,"<NAME>","DE",9.28333,48.966671), (6553038,"Jüchen","DE",6.5095,51.099098), (2894637,"Juchen","DE",6.5,51.099998), (2930205,"Engelthal","DE",11.39943,49.471809), (2874768,"Lutzelbach","DE",8.7675,49.7425), (2812497,"Weilmunster","DE",8.36667,50.433331), (2820256,"Ulm","DE",9.99155,48.398411), (2812799,"Weiher","DE",12.66667,49.26667), (2857217,"Oos","DE",6.58333,50.23333), (6548768,"Belgershain","DE",12.55,51.233299), (2951254,"Belgershain","DE",12.55,51.23333), (2953398,"<NAME>","DE",6.76667,50.549999), (2841674,"<NAME>","DE",7.86667,49.683331), (2936974,"<NAME>","DE",10.48333,48.566669), (2846181,"Roda","DE",11.45,50.549999), (2843395,"<NAME>","DE",7.92183,49.978409), (2918143,"Gramschatz","DE",9.97139,49.928059), (2876185,"Lohne","DE",8.23333,52.666672), (2933210,"Egenried","DE",11.23333,47.76667), (2811111,"Wenigmünchen","DE",11.21667,48.26667), (2905504,"Herzberg","DE",13.22016,51.68692), (2927316,"Feldolling","DE",11.85571,47.894939), (2819401,"Unterhausen","DE",11.15,47.866669), (2881650,"<NAME>","DE",12.69316,48.672489), (2928729,"Esterhofen","DE",11.45,48.366669), (6548287,"Loissin","DE",13.5333,54.116699), (2876065,"Loissin","DE",13.53333,54.116669), (2820643,"Twistringen","DE",8.65,52.799999), (2818736,"Unterschöneberg","DE",10.58413,48.445492), (6556620,"Kümmersbruck","DE",11.8883,49.419201), (2882529,"Kummersbruck","DE",11.88833,49.41917), (2807446,"Wisselsdorf","DE",12.81667,48.666672), (2815421,"Wahles","DE",10.38333,50.76667), (2950622,"Bergen","DE",9.96374,52.808369), (2890479,"<NAME>","DE",11.75563,48.176559), (6552069,"Freienwill","DE",9.5,54.733299), (2925134,"Freienwill","DE",9.5,54.73333), (2810777,"Wernsdorf","DE",13.71667,52.366669), (2911960,"Haigerloch","DE",8.80357,48.366138), (6556094,"Sauldorf","DE",9.1,47.9333), (2841128,"Sauldorf","DE",9.1,47.933331), (2882439,"Kunzelsau","DE",9.68889,49.28194), (2956787,"Altusried","DE",10.21667,47.799999), (2814463,"Walsmühlen","DE",11.26667,53.566669), (2898461,"Hösseringen","DE",10.41658,52.859081), (2878484,"Lessien","DE",10.8,52.566669), (2866698,"Neermoor","DE",7.43333,53.299999), (2947053,"Boekzetelerfehn","DE",7.51667,53.333328), (2806971,"Wold","DE",7.6,53.650002), (6552953,"Jemgum","DE",7.38333,53.266701), (2895051,"Jemgum","DE",7.38333,53.26667), (2949926,"Berolzheim","DE",9.54,49.474998), (6555621,"Oberhausen-Rheinhausen","DE",8.47167,49.273899), (2860400,"Oberhausen-Rheinhausen","DE",8.47167,49.273891), (2877871,"Liedering","DE",12.33333,48.01667), (6556269,"Pürgen","DE",10.9167,48.033298), (2851664,"Purgen","DE",10.92213,48.024719), (2867726,"Munchberg","DE",11.78333,50.200001), (6555664,"Heiligkreuzsteinach","DE",8.795,49.483299), (2907501,"Heiligkreuzsteinach","DE",8.795,49.48333), (6555503,"Plüderhausen","DE",9.5946,48.799301), (2853107,"Pluderhausen","DE",9.59587,48.798752), (6552841,"Dörverden","DE",9.2711,52.845901), (2935491,"Dorverden","DE",9.23333,52.849998), (2890114,"Klagebach","DE",7.53333,51.23333), (2872306,"Meiersberg","DE",7.26667,51.049999), (2886159,"<NAME>","DE",13.50675,52.853951), (2918321,"Grafenhainichen","DE",12.45,51.73333), (2892623,"Kartzow","DE",12.98333,52.5), (6552142,"Stuvenborn","DE",10.1333,53.849998), (2825266,"Stuvenborn","DE",10.13333,53.849998), (2905348,"Hesseldorf","DE",9.30765,50.270691), (6554133,"Goddert","DE",7.73333,50.549999), (2919598,"Goddert","DE",7.73333,50.549999), (2904709,"Hillensberg","DE",5.91644,50.981529), (2875417,"Ludinghausen","DE",7.46667,51.76667), (6557275,"Deiningen","DE",10.5667,48.866699), (2938439,"Deiningen","DE",10.56667,48.866669), (2942073,"Budingen","DE",9.11667,50.299999), (3272461,"Linkenheim-Hochstetten","DE",8.41244,49.131969), (2868998,"Motrich","DE",11.68333,53.033329), (2953348,"<NAME>","DE",8.06667,50.133331), (2863711,"Nideggen","DE",6.48333,50.700001), (2929804,"Erbach","DE",9.88752,48.328411), (2852566,"<NAME>","DE",7.05,50.883331), (2867542,"Munster","DE",10.08333,52.98333), (2933429,"Edenbüttel","DE",8.61667,53.150002), (6552392,"Edemissen","DE",10.2667,52.383301), (2933442,"Edemissen","DE",10.2614,52.38702), (2943408,"Bruckmuhl","DE",11.91667,47.883331), (2843771,"Rottau","DE",12.41667,47.799999), (2920070,"Glaslern","DE",11.93333,48.383331), (6556409,"<NAME>","DE",12.5281,47.658699), (2848382,"<NAME>","DE",12.47086,47.677292), (2874695,"Lychen","DE",13.3,53.200001), (2842835,"Rutenberg","DE",13.30676,53.251759), (2805176,"Zaschwitz","DE",11.81667,51.583328), (6556695,"Wenzenbach","DE",12.1942,49.0756), (2811013,"Wenzenbach","DE",12.19417,49.075562), (2888435,"<NAME>","DE",9.96667,54.316669), (2900236,"Holtdorf","DE",9.73333,54.183331), (6552785,"Beckdorf","DE",9.61667,53.416698), (2951725,"Beckdorf","DE",9.61667,53.416672), (2891981,"Keelbek","DE",9.41667,54.650002), (2947047,"Böelschuby","DE",9.68333,54.650002), (2919763,"Gluckstadt","DE",9.41667,53.783329), (2875542,"Luchow","DE",11.15,52.966671), (2844012,"Rothenkirchen","DE",12.5,50.533329), (2955456,"Arnsdorf","DE",13.86667,51.433331), (2817469,"Viehbig","DE",14.58333,51.01667), (2922264,"Gaulis","DE",12.4,51.183331), (2872619,"Mechelgrün","DE",12.23333,50.48333), (2807678,"Winterstein","DE",10.45,50.883331), (2888926,"Kleinfahner","DE",10.85,51.033329), (6550460,"Oppurg","DE",11.65117,50.710918), (2857134,"Oppurg","DE",11.65289,50.710651), (2884767,"Kranich","DE",12,50.683331), (2902768,"Hof","DE",11.91667,50.316669), (2936642,"Döberein","DE",11.88333,49.916672), (2809606,"Wiedenbrück","DE",8.31667,51.833328), (2803564,"Zwesten","DE",9.18333,51.049999), (2815524,"Wagenfeld","DE",8.58333,52.549999), (2815523,"Wagenfeld","DE",8.58333,52.549999), (2935326,"Dransfeld","DE",9.76667,51.5), (6553145,"Erndtebrück","DE",8.26667,50.983299), (2929370,"Erndtebruck","DE",8.26667,50.98333), (3207806,"Mulheim-Karlich","DE",7.5,50.383331), (2867843,"Mülheim","DE",7.5,50.383331), (2803468,"Zyfflich","DE",5.96667,51.816669), (2879210,"Leinach","DE",10.41667,50.23333), (6557101,"Thüngersheim","DE",9.84917,49.8783), (2822563,"Thungersheim","DE",9.84917,49.87833), (6557085,"Güntersleben","DE",9.905,49.869701), (2913587,"Guntersleben","DE",9.905,49.86972), (2857484,"Olbernhau","DE",13.33333,50.666672), (2861158,"Oberbürg","DE",11.15,49.466671), (2923471,"Gabelbach","DE",10.56782,48.379971), (6555689,"Gechingen","DE",8.82957,48.695438), (2922136,"Gechingen","DE",8.82915,48.695271), (2925189,"<NAME>","DE",9.2024,48.931961), (2882091,"<NAME>","DE",8.4,50.933331), (2845186,"Röppisch","DE",11.68333,50.51667), (6555078,"Börsborn","DE",7.4,49.4333), (2946025,"Borsborn","DE",7.4,49.433331), (2944743,"Breiten","DE",7.16667,49.466671), (2860447,"Oberhatzkofen","DE",12,48.700001), (6552975,"<NAME>","DE",8.413,52.317501), (2953464,"<NAME>","DE",8.33333,52.316669), (2878676,"Leopoldshafen","DE",8.39999,49.096241), (2935042,"Drensteinfurt","DE",7.73815,51.795349), (6547410,"Hohenbucko","DE",13.4667,51.766701), (2901861,"Hohenbucko","DE",13.46667,51.76667), (6551557,"Horstedt","DE",9.06667,54.533298), (2898607,"Horstedt","DE",9.06667,54.533329), (2936886,"Dinkelsbuhl","DE",10.31985,49.06942), (6553099,"Senden","DE",7.5,51.849998), (2833079,"Senden","DE",7.5,51.849998), (6554078,"Oberneisen","DE",8.08333,50.3167), (2859593,"Oberneisen","DE",8.08333,50.316669), (2822924,"Theener","DE",7.3,53.666672), (2946286,"Börgerwald","DE",7.53662,52.973042), (6552942,"Quendorf","DE",7.18333,52.333302), (3204963,"Quendorf","DE",7.18333,52.333328), (6554544,"Gransdorf","DE",6.68333,50.016701), (2918091,"Gransdorf","DE",6.68333,50.01667), (6554662,"Saxler","DE",6.9,50.133301), (2841050,"Saxler","DE",6.9,50.133331), (6557143,"Kutzenhausen","DE",10.7,48.333302), (2882192,"Kutzenhausen","DE",10.7,48.333328), (2838629,"Schlettach","DE",10.86667,50.26667), (2879032,"Leitersdorf","DE",12.31667,48.75), (2952977,"Bamling","DE",12.88333,48.716671), (2890388,"Kirchschönbach","DE",10.38333,49.816669), (2911360,"Hambach","DE",6.45,50.900002), (2843923,"Rothhausen","DE",10.33333,50.183331), (6555450,"Bad Überkingen","DE",9.79624,48.599941), (2953322,"Bad Uberkingen","DE",9.79586,48.599911), (6555310,"Zornheim","DE",8.22472,49.889999), (2803882,"Zornheim","DE",8.22472,49.889999), (2865705,"Neuenhaßlau","DE",9.09101,50.162048), (2927516,"Feil","DE",7.8,49.76667), (6554845,"Flonheim","DE",8.04,49.785), (2926135,"Flonheim","DE",8.04,49.785), (2815417,"<NAME>","DE",8.23333,49.866669), (2957012,"Altmannsdorf","DE",10.43333,49.933331), (2956234,"Anderbeck","DE",10.93333,51.98333), (2871077,"Miltern","DE",11.93321,52.558609), (2811326,"Wenddorf","DE",11.75,52.383331), (2915511,"Grossheubach","DE",9.22528,49.727219), (2953389,"Bad Neustadt an der Saale","DE",10.21667,50.333328), (6556972,"Bastheim","DE",10.2,50.400002), (2952238,"Bastheim","DE",10.2,50.400002), (2923901,"Fuchsstadt","DE",9.97,49.698891), (2947573,"Blume","DE",9.66667,51.416672), (2892357,"Katlenburg-Duhm","DE",10.1,51.683331), (2826737,"Stöckheim","DE",9.93333,51.75), (6552513,"Kirchbrak","DE",9.58333,51.966702), (2890635,"Kirchbrak","DE",9.5751,51.965851), (6555410,"Altenriet","DE",9.22171,48.591358), (2957499,"Altenriet","DE",9.22186,48.5914), (2816553,"Vollochhof","DE",9.56667,48.066669), (2899200,"Hopferbach","DE",9.61667,48), (2920924,"Gershasen","DE",7.95,50.566669), (2927647,"Fechenbach","DE",9.34278,49.772221), (6557027,"Mömlingen","DE",9.0912,49.846199), (2869934,"Momlingen","DE",9.08333,49.859718), (2816671,"Volkersbrunn","DE",9.26833,49.896389), (6557055,"Donnersdorf","DE",10.4167,49.966702), (2936210,"Donnersdorf","DE",10.41667,49.966671), (2804865,"Zell am Main","DE",9.86972,49.810001), (2864836,"Neuhückeswagen","DE",7.35,51.150002), (6553092,"Südlohn","DE",6.86667,51.9333), (2824998,"Sudlohn","DE",6.86667,51.933331), (2845833,"Rogglfing","DE",12.06667,48.283329), (2842816,"Ruthen","DE",8.43596,51.490898), (2907609,"Heiligenborn","DE",13.01667,51.066669), (2941202,"<NAME>","DE",7.86518,49.929901), (2881835,"Laimering","DE",11.08701,48.388889), (2845366,"Romatsried","DE",10.51667,47.900002), (2894575,"Jühnsdorf","DE",13.38333,52.299999), (3305812,"<NAME>","DE",14.08056,50.950562), (6548705,"Dorfhain","DE",13.5667,50.9333), (2936089,"Dorfhain","DE",13.56667,50.933331), (2928856,"Espenscheid","DE",7.9,50.116669), (6552928,"Werpeloh","DE",7.5,52.883301), (2810763,"Werpeloh","DE",7.5,52.883331), (2863772,"<NAME>","DE",13.75,52.366669), (6552592,"Kirchwistedt","DE",8.9,53.416698), (2890330,"Kirchwistedt","DE",8.89043,53.4235), (6552577,"Cadenberge","DE",9.0679,53.764999), (2940430,"Cadenberge","DE",9.06269,53.76926), (2857148,"Oppershofen","DE",8.74512,50.41782), (6547548,"Friedrichswalde","DE",13.7167,53.033298), (2924443,"Friedrichswalde","DE",13.70682,53.02919), (2891564,"Kerkow","DE",13.98834,53.037289), (2954742,"Aubenham","DE",12.38333,48.299999), (6555053,"Oberarnbach","DE",7.58333,49.383301), (2861407,"Oberarnbach","DE",7.58333,49.383331), (2868979,"Motzen","DE",8.56667,53.166672), (6555323,"Geiselberg","DE",7.7,49.333302), (2921746,"Geiselberg","DE",7.7,49.333328), (2900216,"Holtendorf","DE",14.9,51.150002), (6554877,"Udenheim","DE",8.17167,49.8647), (2820499,"Udenheim","DE",8.17167,49.864719), (2943049,"Brunsbuttel","DE",9.15,53.900002), (2893529,"Kaltensondheim","DE",10.08854,49.729469), (2821326,"Trennewurth","DE",9.01667,54.01667), (2821330,"Trennewurth","DE",9.03333,54), (6552789,"Deinste","DE",9.43333,53.533298), (2938430,"Deinste","DE",9.43333,53.533329), (2953809,"Baalborn","DE",7.83333,49.5), (2826315,"Straberg","DE",6.762,51.093391), (6548453,"Glasow","DE",14.2667,53.383301), (2920063,"Glasow","DE",14.26667,53.383331), (2804009,"Ziswingen","DE",10.58704,48.78606), (2853057,"Podelsatz","DE",11.7,50.883331), (6554312,"Eckfeld","DE",6.85,50.116699), (2933587,"Eckfeld","DE",6.85,50.116669), (2938956,"Danstedt","DE",10.88333,51.900002), (6548554,"Grünhainichen","DE",13.1667,50.766701), (2914186,"Grunhainichen","DE",13.16667,50.76667), (6552705,"Hambergen","DE",8.83333,53.3167), (2911322,"Hambergen","DE",8.83333,53.316669), (2923658,"Furstenau","DE",7.71667,52.51667), (2956185,"<NAME>","DE",7.58333,52.51667), (2881276,"Langen","DE",8.59509,53.605541), (2841910,"Sandbostel","DE",9.1293,53.409328), (2924618,"Friedrichsfehn","DE",8.11667,53.116669), (2845235,"Rönnebeck","DE",8.55,53.183331), (2829999,"Sprockhof","DE",9.71689,52.60857), (2936937,"Dingelbe","DE",10.13386,52.173409), (6552772,"Grethem","DE",9.58333,52.716702), (2917596,"Grethem","DE",9.57253,52.727139), (2915540,"<NAME>","DE",9.3976,52.804321), (6552553,"Eicklingen","DE",10.1867,52.5462), (2931985,"Eicklingen","DE",10.18333,52.549999), (2810296,"Westerhusen","DE",7.18333,53.416672), (2957192,"Altgaude","DE",7.56667,53.583328), (2945861,"Bösinghausen","DE",10.06667,51.566669), (6552299,"Adenbüttel","DE",10.45,52.383301), (2959482,"Adenbuttel","DE",10.45,52.383331), (2809630,"Wiedelah","DE",10.58333,51.966671), (2813498,"Weddel","DE",10.61667,52.26667), (2852751,"Pommoissel","DE",10.86737,53.164059), (6552665,"Zernien","DE",10.8833,53.0667), (2804729,"Zernien","DE",10.88325,53.068451), (2879276,"Leiferde","DE",10.50842,52.204449), (2826749,"Stöckheim","DE",10.52216,52.210548), (2939983,"Clenze","DE",10.95,52.933331), (2949512,"Bevenrode","DE",10.58333,52.333328), (2804860,"Zellberg","DE",10.53333,52.383331), (2933733,"Eckardtsheim","DE",8.56667,51.933331), (6552995,"Voltlage","DE",7.75,52.4333), (2816527,"Voltlage","DE",7.75,52.433331), (6552461,"Stemshorn","DE",8.36667,52.450001), (2827481,"Stemshorn","DE",8.36667,52.450001), (2810316,"Westerholte","DE",7.86667,52.5), (6552438,"Brockum","DE",8.41667,52.466702), (2943945,"Brockum","DE",8.41667,52.466671), (2927226,"Felsberg","DE",9.41667,51.133331), (6553265,"Fuldabrück","DE",9.48333,51.266701), (2923820,"Fuldabruck","DE",9.48333,51.26667), (2952039,"Baumbach","DE",9.66667,51.033329), (2917362,"Grifte","DE",9.45,51.216671), (2931826,"Eimelrod","DE",8.7,51.299999), (2866673,"Negast","DE",13.03047,54.255951), (2915358,"<NAME>","DE",12.26667,54.116669), (2856193,"<NAME>","DE",11.75,54.150002), (2937545,"Diedrichshagen","DE",12.03333,54.166672), (2814055,"Warnemuende","DE",12.08402,54.176701), (2809111,"Wiethagen","DE",12.23688,54.184738), (2925488,"Franzburg","DE",12.88333,54.183331), (6548117,"Gransebieth","DE",12.8833,54.0667), (2918090,"Gransebieth","DE",12.88267,54.064781), (6548337,"Banzkow","DE",11.5167,53.533298), (2952857,"Banzkow","DE",11.51667,53.533329), (2907960,"Heidekaten","DE",11.53333,53.98333), (2939739,"Crivitz","DE",11.65,53.583328), (2938300,"Demern","DE",10.98333,53.73333), (6548362,"Karrenzin","DE",11.8,53.333302), (2892668,"Karrenzin","DE",11.8,53.333328), (6551491,"Rondeshagen","DE",10.6333,53.75), (2845258,"Rondeshagen","DE",10.63333,53.75), (6552281,"Mönkhagen","DE",10.55,53.900002), (2869775,"Monkhagen","DE",10.55,53.900002), (2851594,"Puttgarden","DE",11.21667,54.5), (2862592,"Niendorf","DE",11.21667,54.466671), (6551489,"Ritzerau","DE",10.5667,53.666698), (2846333,"Ritzerau","DE",10.56667,53.666672), (6551496,"Schiphorst","DE",10.4667,53.700001), (2839102,"Schiphorst","DE",10.46667,53.700001), (6551426,"Duvensee","DE",10.5667,53.700001), (2934167,"Duvensee","DE",10.56667,53.700001), (2875399,"Ludwigsaue","DE",12.99923,52.8456), (6552279,"Lütjensee","DE",10.3667,53.650002), (2874902,"Lutjensee","DE",10.36667,53.650002), (6551748,"Laboe","DE",10.2299,54.400249), (2882059,"Laboe","DE",10.21667,54.400002), (2875924,"Lopshop","DE",9.21667,54.299999), (6551601,"Schwabstedt","DE",9.18333,54.400002), (2835467,"Schwabstedt","DE",9.18646,54.397049), (6551594,"Ramstedt","DE",9.16667,54.400002), (2850544,"Ramstedt","DE",9.16667,54.400002), (6551829,"Elsdorf-Westermühlen","DE",9.51667,54.266701), (2930771,"Elsdorf-Westermuhlen","DE",9.51667,54.26667), (6551308,"Bunsoh","DE",9.33333,54.166698), (2941628,"Bunsoh","DE",9.33333,54.166672), (6551815,"Breiholz","DE",9.53333,54.200001), (2944812,"Breiholz","DE",9.53333,54.200001), (6551616,"Tetenbüll","DE",8.83333,54.349998), (2823403,"Tetenbull","DE",8.82794,54.352139), (6551398,"Wrohm","DE",9.4,54.216702), (2805988,"Wrohm","DE",9.4,54.216671), (6551831,"Emkendorf","DE",9.85,54.266701), (2930550,"Emkendorf","DE",9.85,54.26667), (6552148,"Travenhorst","DE",10.45,54.016701), (2821478,"Travenhorst","DE",10.45,54.01667), (6551913,"Schierensee","DE",9.98333,54.25), (2839413,"Schierensee","DE",9.98333,54.25), (6551927,"Techelsdorf","DE",10.05,54.216702), (2823740,"Techelsdorf","DE",10.05,54.216671), (6551768,"Rendswühren","DE",10.1833,54.083302), (2848243,"Rendswuhren","DE",10.18333,54.083328), (6551918,"Seefeld","DE",9.46667,54.099998), (2833859,"Seefeld","DE",9.46667,54.099998), (6552655,"Vierhöfen","DE",10.2167,53.266701), (2817346,"Vierhofen","DE",10.21667,53.26667), (6551698,"Langeln","DE",9.85,53.799999), (2881301,"Langeln","DE",9.85,53.799999), (6552043,"Nordhackstedt","DE",9.16667,54.733299), (2861996,"Nordhackstedt","DE",9.16667,54.73333), (2820396,"Uhlebüll","DE",8.85,54.799999), (6551977,"Lürschau","DE",9.5,54.549999), (2875027,"Lurschau","DE",9.5,54.549999), (6551971,"Klappholz","DE",9.55,54.616699), (2890066,"Klappholz","DE",9.55,54.616669), (2846933,"Riesbriek","DE",9.1,54.700001), (2810683,"Weseby","DE",9.71667,54.5), (2940530,"Büttjebüll","DE",8.9,54.650002), (2886333,"Kollerup","DE",9.56667,54.716671), (2887651,"Klintum","DE",8.95,54.75), (6552061,"Tarp","DE",9.4,54.666698), (2823978,"Tarp","DE",9.4,54.666672), (6551529,"Bargum","DE",8.95,54.700001), (2952630,"Bargum","DE",8.95,54.700001), (2830916,"Sörupholz","DE",9.7,54.700001), (6551628,"Westre","DE",8.98333,54.849998), (2810058,"Westre","DE",8.98333,54.849998), (6551621,"Utersum","DE",8.4,54.716702), (2818066,"Utersum","DE",8.40609,54.71431), (2856525,"Osterholm","DE",9.76667,54.75), (6551947,"Bollingstedt","DE",9.41667,54.599998), (2946610,"Bollingstedt","DE",9.41667,54.599998), (2922758,"Gammellund","DE",9.45,54.583328), (7602403,"Ülsby","DE",9.6,54.633331), (2820214,"Ulsby","DE",9.6,54.633331), (2946720,"Boldixum","DE",8.55595,54.69492), (2881982,"Ladelundfeld","DE",9.01667,54.849998), (2847417,"Riddorf","DE",8.98333,54.616669), (6551572,"Lexgaard","DE",8.93333,54.833302), (2878204,"Lexgaard","DE",8.93333,54.833328), (6551637,"Galmsbüll","DE",8.75,54.75), (3208545,"Galmsbull","DE",8.75,54.75), (2821756,"Torsballig","DE",9.55,54.666672), (2874675,"Maasbüll","DE",8.81667,54.75), (3208571,"Sylt-Ost","DE",8.35,54.883331), (2820714,"Tuszshing","DE",12.6,48.216671), (6556399,"Grabenstätt","DE",12.5475,47.842201), (2918434,"Grabenstatt","DE",12.55,47.849998), (6556107,"Unterneukirchen","DE",12.6167,48.166698), (2818999,"Unterneukirchen","DE",12.61667,48.166672), (2944780,"<NAME>","DE",12.40039,47.88953), (2852396,"Poxau","DE",12.55,48.566669), (2954898,"Atting","DE",12.11667,48.349998), (2841270,"Sattlern","DE",12.86667,48.583328), (2923389,"Gadham","DE",13.31667,48.5), (2858770,"Obertrennbach","DE",12.56667,48.48333), (2918658,"Gottfriedingerschwaige","DE",12.53333,48.650002), (6556477,"Mauth","DE",13.5833,48.883301), (2872697,"Mauth","DE",13.58459,48.889721), (2885302,"Chostlarn","DE",13.11667,48.366669), (2931511,"Eisenbernreut","DE",13.45,48.76667), (2839587,"Scheuereck","DE",13.31667,48.533329), (2847313,"Ried","DE",12.25,48.783329), (6556671,"Alteglofsheim","DE",12.2,48.916698), (2957938,"Alteglofsheim","DE",12.2,48.916672), (6556676,"Brennberg","DE",12.4,49.0667), (2944288,"Brennberg","DE",12.4,49.066669), (6556703,"Guteneck","DE",12.2833,49.450001), (2913394,"Guteneck","DE",12.28333,49.450001), (2957640,"Altenhammer","DE",12.31667,49.400002), (2904671,"Hillohe","DE",11.9,49.033329), (2880597,"Langquaid","DE",12.05,48.816669), (6556680,"Hagelstadt","DE",12.2167,48.900002), (2912646,"Hagelstadt","DE",12.21667,48.900002), (2947439,"Bobrach","DE",12.88333,48.933331), (2876841,"Lissenthau","DE",12.13333,49.450001), (2872908,"Mattenkofen","DE",12.73599,48.780972), (2890544,"Kirchenlamitz","DE",11.95,50.150002), (2835019,"<NAME>","DE",11.61667,50.283329), (2918767,"Gossweinstein","DE",11.33333,49.76667), (2929783,"Erbendorf","DE",12.04472,49.840279), (2818825,"Unterröslau","DE",11.98333,50.083328), (2864020,"Neusteinreuth","DE",11.93333,49.883331), (2930751,"Elsenberg","DE",11.11667,49.700001), (6556838,"Diebach","DE",10.1833,49.299999), (2937632,"Diebach","DE",10.18333,49.299999), (2903013,"Hochstadt am Main","DE",11.17116,50.150089), (2807021,"Wohnbach","DE",10.25,49.299999), (2914655,"<NAME>","DE",11.01667,50.23333), (2817740,"Veitsaurach","DE",10.88333,49.299999), (2873302,"Marktgraitz","DE",11.2,50.183331), (2808144,"Windischletten","DE",10.99319,49.99659), (2888745,"Kleinhöbing","DE",11.3,49.066669), (2885091,"Kotzendorf","DE",11.18333,49.933331), (2911301,"Hambühl","DE",10.53333,49.616669), (2810813,"Wernfels","DE",10.86667,49.200001), (2809201,"Wiesentfels","DE",11.21667,49.950001), (2827264,"Stettberg","DE",10.33333,49.383331), (2841481,"<NAME>","DE",11.74816,47.727661), (6556224,"Kottgeisering","DE",11.1333,48.116699), (3208350,"Kottgeisering","DE",11.13333,48.116669), (6556217,"Egenhofen","DE",11.1667,48.283298), (2933212,"Egenhofen","DE",11.16667,48.283329), (6556233,"Schöngeising","DE",11.2,48.133301), (2836615,"Schongeising","DE",11.2,48.133331), (2956814,"Altstetten","DE",11.28333,48.299999), (2828090,"Steingaden","DE",10.33333,47.666672), (2852444,"Pottenau","DE",11.96667,48.433331), (6556351,"Pörnbach","DE",11.4667,48.616699), (2852599,"Pornbach","DE",11.46667,48.616669), (2875377,"Ludwigshafen","DE",9.06667,47.816669), (2895553,"Itzlishofen","DE",10.66667,48.26667), (2839767,"Schempach","DE",10.65,48.366669), (6557281,"Hainsfarth","DE",10.6167,48.966702), (2911769,"Hainsfarth","DE",10.61667,48.966671), (2958813,"Aislingen","DE",10.45778,48.506481), (2899811,"Holzhausen","DE",10.81667,48.433331), (2819281,"Unterjoch","DE",10.43333,47.549999), (2899633,"Holzleute","DE",10,47.599998), (2874582,"Maderhalm","DE",10.26667,47.450001), (2943358,"Brugg","DE",9.98333,47.650002), (6555983,"Oberdischingen","DE",9.83333,48.299999), (2861094,"Oberdischingen","DE",9.83333,48.299999), (2829647,"Staig","DE",9.8,47.783329), (2824545,"Sussen","DE",9.75534,48.67934), (2888147,"Kleinsüßen","DE",9.76539,48.683929), (2951985,"Baumgarten","DE",9.5,47.799999), (6556031,"Ummendorf","DE",9.83333,48.0667), (2820179,"Ummendorf","DE",9.83333,48.066669), (6556012,"Erlenmoos","DE",9.98333,48.0667), (2929452,"Erlenmoos","DE",9.98333,48.066669), (6555839,"Egesheim","DE",8.86667,48.116699), (2933190,"Egesheim","DE",8.86667,48.116669), (6555897,"Utzenfeld","DE",7.91667,47.799999), (2817996,"Utzenfeld","DE",7.91667,47.799999), (6555876,"Böllen","DE",7.85,47.799999);
<filename>media/db/mysql_upgrade_kalkun_0.7.sql -- -------------------------------------------------------- -- -- Table structure for table `user_filters` -- CREATE TABLE IF NOT EXISTS `user_filters` ( `id_filter` int(11) NOT NULL AUTO_INCREMENT, `id_user` int(11) NOT NULL, `from` varchar(15) NOT NULL, `has_the_words` varchar(50) NOT NULL, `id_folder` int(11) NOT NULL, PRIMARY KEY (`id_filter`) ) DEFAULT CHARSET=utf8mb4 AUTO_INCREMENT=1 ;
# We want to enforce SSL on all users, but in case MySQL/RDS creates admin without this # fix it. # # Note the user of Flyway placeholder variables. If the env var FLYWAY_PLACEHOLDERS_ROOT_PASSWORD # is present then Flyway will preprocess this migration and replace the variable with the value # the env var. This is how you allow for different passwords in different environments without # hardcoding any passwords into your SQL migrations. # # See the `migrate.sh` script for an example of how this variable is set. # See https://flywaydb.org/documentation/placeholders # ALTER USER 'root' IDENTIFIED WITH mysql_native_password BY '${<PASSWORD>}'; ALTER USER 'root' REQUIRE SSL;
<reponame>vgulaev/slack_analyzer CREATE TABLE channel_history ( id uuid PRIMARY KEY DEFAULT uuid_generate_v4(), channel_id character varying(255), "user" character varying(255), bot_id character varying(255), reply_count INTEGER, subtype character varying(255), ts NUMERIC(20, 6), msg_date_time timestamp without time zone, created_at timestamp without time zone, parsed boolean, raw json );
use [DB1-Project] go create or alter view activePropertiesUsersRelations as select u.Id as UserId, u.Username, u.UserType, u.Password, p.Id as PropertyId, p.Address as PropertyAddress, p.PropertyNumber as PropertyNumber, p.Value as PropertyValue, p.AccumulatedM3 as AccumulatedM3, p.AccumulatedLRM3 as AccumulatedLRM3, pu.RelationId as RelationId from activePropertiesUsers as pu inner join activeProperties as p on pu.PropertyId = p.Id inner join activeUsers as u on pu.UserId = u.Id go
<filename>src/Financier.DataAccess/DataBase/Scripts/alter/20100504_0020_add_notification_options_to_transaction.sql ALTER TABLE transactions ADD COLUMN notification_options text;
<filename>src/main/resources/data.sql DROP TABLE IF EXISTS student; CREATE TABLE student ( id INT AUTO_INCREMENT PRIMARY KEY, first_name VARCHAR(250) NOT NULL, last_name VARCHAR(250) NOT NULL, class INTEGER NOT NULL );
select t.machine_id, round(avg(t.end_time-t.start_time), 3) processing_time from ( select machine_id, process_id, max(case when activity_type='start' then timestamp else null end) start_time, max(case when activity_type='end' then timestamp else null end) end_time from activity group by machine_id, process_id ) t group by t.machine_id;
CREATE DATABASE IF NOT EXISTS `tccscapucminasbackendapimonitoramentobarragens` /*!40100 DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci */ /*!80016 DEFAULT ENCRYPTION='N' */; USE `tccscapucminasbackendapimonitoramentobarragens`; -- MySQL dump 10.13 Distrib 8.0.18, for Win64 (x86_64) -- -- Host: 127.0.0.1 Database: tccscapucminasbackendapimonitoramentobarragens -- ------------------------------------------------------ -- Server version 8.0.19 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; /*!50503 SET NAMES utf8 */; /*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */; /*!40103 SET TIME_ZONE='+00:00' */; /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */; /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */; /*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */; -- -- Table structure for table `afetado` -- DROP TABLE IF EXISTS `afetado`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!50503 SET character_set_client = utf8mb4 */; CREATE TABLE `afetado` ( `id` bigint NOT NULL AUTO_INCREMENT, `nome` varchar(60) NOT NULL, `email` varchar(130) NOT NULL, `telefone_principal` varchar(16) NOT NULL, `telefone_reserva` varchar(16) NOT NULL, `barragem_id` bigint NOT NULL, PRIMARY KEY (`id`), KEY `fk_afetado_barragem_id` (`barragem_id`), CONSTRAINT `fk_afetado_barragem_id` FOREIGN KEY (`barragem_id`) REFERENCES `barragem` (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `afetado` -- LOCK TABLES `afetado` WRITE; /*!40000 ALTER TABLE `afetado` DISABLE KEYS */; INSERT INTO `afetado` VALUES (1,'Afetado 01','<EMAIL>','+5599999999999','+5599999999999',6),(2,'Afetado 02','<EMAIL>','+5599999999999','+5599999999999',6); /*!40000 ALTER TABLE `afetado` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `barragem` -- DROP TABLE IF EXISTS `barragem`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!50503 SET character_set_client = utf8mb4 */; CREATE TABLE `barragem` ( `id` bigint NOT NULL AUTO_INCREMENT, `nome` varchar(60) NOT NULL, `capacidade_metros_cubicos` decimal(21,2) NOT NULL, `latitude` double DEFAULT NULL, `longitude` double DEFAULT NULL, `grau_risco` varchar(255) NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `barragem` -- LOCK TABLES `barragem` WRITE; /*!40000 ALTER TABLE `barragem` DISABLE KEYS */; INSERT INTO `barragem` VALUES (1,'Barragem Mina Engenho',46621.00,15231,74024,'ALTO'),(2,'Barragem II Mina Engenho',44599.00,61992,38776,'ALTO'),(3,'Barragem B1/B4',34264.00,58502,47486,'BAIXO'),(4,'Barragem de Água do Igarapé Bahia',70038.00,47468,36973,'ALTO'),(5,'Barragem de Rejeitos',30034.00,60684,61352,'BAIXO'),(6,'Norte/Laranjeiras',47142.00,67704,80903,'MEDIO'),(7,'BACIA DE REJEITOS 14/15',95813.00,7740,62150,'MEDIO'),(8,'Barragem B1-Auxiliar - Mina Tico-Tico',14569.00,94944,81939,'BAIXO'),(9,'Barragem de Água do Igarapé Bahia',9976.00,18856,17317,'MEDIO'),(10,'Barragem do Mirante I e II',33372.00,78971,78701,'MEDIO'); /*!40000 ALTER TABLE `barragem` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `databasechangelog` -- DROP TABLE IF EXISTS `databasechangelog`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!50503 SET character_set_client = utf8mb4 */; CREATE TABLE `databasechangelog` ( `ID` varchar(255) NOT NULL, `AUTHOR` varchar(255) NOT NULL, `FILENAME` varchar(255) NOT NULL, `DATEEXECUTED` datetime NOT NULL, `ORDEREXECUTED` int NOT NULL, `EXECTYPE` varchar(10) NOT NULL, `MD5SUM` varchar(35) DEFAULT NULL, `DESCRIPTION` varchar(255) DEFAULT NULL, `COMMENTS` varchar(255) DEFAULT NULL, `TAG` varchar(255) DEFAULT NULL, `LIQUIBASE` varchar(20) DEFAULT NULL, `CONTEXTS` varchar(255) DEFAULT NULL, `LABELS` varchar(255) DEFAULT NULL, `DEPLOYMENT_ID` varchar(10) DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `databasechangelog` -- LOCK TABLES `databasechangelog` WRITE; /*!40000 ALTER TABLE `databasechangelog` DISABLE KEYS */; INSERT INTO `databasechangelog` VALUES ('00000000000001','jhipster','config/liquibase/changelog/00000000000000_initial_schema.xml','2020-04-10 15:26:49',1,'EXECUTED','8:9bf75aca02e1c4157cc1268a96e34b65','createTable tableName=jhi_persistent_audit_event; createTable tableName=jhi_persistent_audit_evt_data; addPrimaryKey tableName=jhi_persistent_audit_evt_data; createIndex indexName=idx_persistent_audit_event, tableName=jhi_persistent_audit_event; c...','',NULL,'3.8.7',NULL,NULL,'6532408365'),('20200409180500-1','jhipster','config/liquibase/changelog/20200409180500_added_entity_Barragem.xml','2020-04-10 15:26:49',2,'EXECUTED','8:b0503ea9b9e6bb2812a37361c72fcc9b','createTable tableName=barragem','',NULL,'3.8.7',NULL,NULL,'6532408365'),('20200409180500-1-relations','jhipster','config/liquibase/changelog/20200409180500_added_entity_Barragem.xml','2020-04-10 15:26:49',3,'EXECUTED','8:d41d8cd98f00b204e9800998ecf8427e','empty','',NULL,'3.8.7',NULL,NULL,'6532408365'),('20200409180500-1-data','jhipster','config/liquibase/changelog/20200409180500_added_entity_Barragem.xml','2020-04-10 15:26:49',4,'EXECUTED','8:2d75f40ade516e65ee95162394795ac2','loadData tableName=barragem','',NULL,'3.8.7','faker',NULL,'6532408365'),('20200409180600-1','jhipster','config/liquibase/changelog/20200409180600_added_entity_Sensor.xml','2020-04-10 15:26:49',5,'EXECUTED','8:11be12a4270c8aeaa90c357df25fe8ee','createTable tableName=sensor','',NULL,'3.8.7',NULL,NULL,'6532408365'),('20200409180600-1-relations','jhipster','config/liquibase/changelog/20200409180600_added_entity_Sensor.xml','2020-04-10 15:26:49',6,'EXECUTED','8:d41d8cd98f00b204e9800998ecf8427e','empty','',NULL,'3.8.7',NULL,NULL,'6532408365'),('20200409180600-1-data','jhipster','config/liquibase/changelog/20200409180600_added_entity_Sensor.xml','2020-04-10 15:26:49',7,'EXECUTED','8:b360bb3e1cb18ffc38485fccb424ebf3','loadData tableName=sensor','',NULL,'3.8.7','faker',NULL,'6532408365'),('20200409180700-1','jhipster','config/liquibase/changelog/20200409180700_added_entity_EventoMedicao.xml','2020-04-10 15:26:49',8,'EXECUTED','8:94ea8c97423fd83cdf7195f2e73465d6','createTable tableName=evento_medicao; dropDefaultValue columnName=data, tableName=evento_medicao','',NULL,'3.8.7',NULL,NULL,'6532408365'),('20200409180700-1-relations','jhipster','config/liquibase/changelog/20200409180700_added_entity_EventoMedicao.xml','2020-04-10 15:26:49',9,'EXECUTED','8:d41d8cd98f00b204e9800998ecf8427e','empty','',NULL,'3.8.7',NULL,NULL,'6532408365'),('20200409180700-1-data','jhipster','config/liquibase/changelog/20200409180700_added_entity_EventoMedicao.xml','2020-04-10 15:26:49',10,'EXECUTED','8:b1f63c3256e9b99e46b540e72c4c4078','loadData tableName=evento_medicao','',NULL,'3.8.7','faker',NULL,'6532408365'),('20200409180800-1','jhipster','config/liquibase/changelog/20200409180800_added_entity_Incidente.xml','2020-04-10 15:26:49',11,'EXECUTED','8:96b80f80d04d4250dad185fff71d9cff','createTable tableName=incidente; dropDefaultValue columnName=data, tableName=incidente','',NULL,'3.8.7',NULL,NULL,'6532408365'),('20200409180800-1-relations','jhipster','config/liquibase/changelog/20200409180800_added_entity_Incidente.xml','2020-04-10 15:26:49',12,'EXECUTED','8:d41d8cd98f00b204e9800998ecf8427e','empty','',NULL,'3.8.7',NULL,NULL,'6532408365'),('20200409180800-1-data','jhipster','config/liquibase/changelog/20200409180800_added_entity_Incidente.xml','2020-04-10 15:26:49',13,'EXECUTED','8:a22736a34fc06ca182d72357bdeca001','loadData tableName=incidente','',NULL,'3.8.7','faker',NULL,'6532408365'),('20200409180900-1','jhipster','config/liquibase/changelog/20200409180900_added_entity_Afetado.xml','2020-04-10 15:26:50',14,'EXECUTED','8:15365825ea04ec4d4a9fd0abcda6f474','createTable tableName=afetado','',NULL,'3.8.7',NULL,NULL,'6532408365'),('20200409180900-1-relations','jhipster','config/liquibase/changelog/20200409180900_added_entity_Afetado.xml','2020-04-10 15:26:50',15,'EXECUTED','8:d41d8cd98f00b204e9800998ecf8427e','empty','',NULL,'3.8.7',NULL,NULL,'6532408365'),('20200409180900-1-data','jhipster','config/liquibase/changelog/20200409180900_added_entity_Afetado.xml','2020-04-10 15:26:50',16,'EXECUTED','8:0cd2bedc0a78e4e207a2dec8ef17279a','loadData tableName=afetado','',NULL,'3.8.7','faker',NULL,'6532408365'),('20200409180600-1','jhipster','config/liquibase/changelog/20200409180600_added_entity_EventoMedicaoClassificacaoAlerta.xml','2020-04-10 15:26:50',17,'EXECUTED','8:2333a7022c489fb7f01cbc25fefb64b5','createTable tableName=evento_medicao_classificacao_alerta','',NULL,'3.8.7',NULL,NULL,'6532408365'),('20200409180600-1-relations','jhipster','config/liquibase/changelog/20200409180600_added_entity_EventoMedicaoClassificacaoAlerta.xml','2020-04-10 15:26:50',18,'EXECUTED','8:d41d8cd98f00b204e9800998ecf8427e','empty','',NULL,'3.8.7',NULL,NULL,'6532408365'),('20200409180600-1-data','jhipster','config/liquibase/changelog/20200409180600_added_entity_EventoMedicaoClassificacaoAlerta.xml','2020-04-10 15:26:50',19,'EXECUTED','8:cd8153243047b791c114b15a549fc20d','loadData tableName=evento_medicao_classificacao_alerta','',NULL,'3.8.7','faker',NULL,'6532408365'),('20200409180700-1','jhipster','config/liquibase/changelog/20200409180700_added_entity_IncidenteResultadoProcessamento.xml','2020-04-10 15:26:50',20,'EXECUTED','8:c31587f14695fbaad530e31b8f3ffa0f','createTable tableName=incidente_resultado_processamento; dropDefaultValue columnName=data, tableName=incidente_resultado_processamento','',NULL,'3.8.7',NULL,NULL,'6532408365'),('20200409180700-1-relations','jhipster','config/liquibase/changelog/20200409180700_added_entity_IncidenteResultadoProcessamento.xml','2020-04-10 15:26:50',21,'EXECUTED','8:d41d8cd98f00b204e9800998ecf8427e','empty','',NULL,'3.8.7',NULL,NULL,'6532408365'),('20200409180700-1-data','jhipster','config/liquibase/changelog/20200409180700_added_entity_IncidenteResultadoProcessamento.xml','2020-04-10 15:26:50',22,'EXECUTED','8:4b9a264b1cda5443241cb462c722d8ed','loadData tableName=incidente_resultado_processamento','',NULL,'3.8.7','faker',NULL,'6532408365'),('20200409180600-2','jhipster','config/liquibase/changelog/20200409180600_added_entity_constraints_Sensor.xml','2020-04-10 15:26:51',23,'EXECUTED','8:92e4925920d0975aaeaf0ecf468e8490','addForeignKeyConstraint baseTableName=sensor, constraintName=fk_sensor_barragem_id, referencedTableName=barragem','',NULL,'3.8.7',NULL,NULL,'6532408365'),('20200409180800-2','jhipster','config/liquibase/changelog/20200409180800_added_entity_constraints_Incidente.xml','2020-04-10 15:26:51',24,'EXECUTED','8:0e07e1bf189ea7d08e4bb7a9ea9803ae','addForeignKeyConstraint baseTableName=incidente, constraintName=fk_incidente_barragem_id, referencedTableName=barragem','',NULL,'3.8.7',NULL,NULL,'6532408365'),('20200409180900-2','jhipster','config/liquibase/changelog/20200409180900_added_entity_constraints_Afetado.xml','2020-04-10 15:26:51',25,'EXECUTED','8:7310de9f092ddb2e07f6f616cc4055fb','addForeignKeyConstraint baseTableName=afetado, constraintName=fk_afetado_barragem_id, referencedTableName=barragem','',NULL,'3.8.7',NULL,NULL,'6532408365'); /*!40000 ALTER TABLE `databasechangelog` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `databasechangeloglock` -- DROP TABLE IF EXISTS `databasechangeloglock`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!50503 SET character_set_client = utf8mb4 */; CREATE TABLE `databasechangeloglock` ( `ID` int NOT NULL, `LOCKED` bit(1) NOT NULL, `LOCKGRANTED` datetime DEFAULT NULL, `LOCKEDBY` varchar(255) DEFAULT NULL, PRIMARY KEY (`ID`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `databasechangeloglock` -- LOCK TABLES `databasechangeloglock` WRITE; /*!40000 ALTER TABLE `databasechangeloglock` DISABLE KEYS */; INSERT INTO `databasechangeloglock` VALUES (1,_binary '\0',NULL,NULL); /*!40000 ALTER TABLE `databasechangeloglock` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `evento_medicao` -- DROP TABLE IF EXISTS `evento_medicao`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!50503 SET character_set_client = utf8mb4 */; CREATE TABLE `evento_medicao` ( `id` bigint NOT NULL AUTO_INCREMENT, `identificador` varchar(36) NOT NULL, `sensor_identificador` varchar(36) NOT NULL, `tipo` varchar(255) NOT NULL, `data` datetime NOT NULL, `intensidade` int NOT NULL, PRIMARY KEY (`id`), UNIQUE KEY `ux_evento_medicao_identificador` (`identificador`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `evento_medicao` -- LOCK TABLES `evento_medicao` WRITE; /*!40000 ALTER TABLE `evento_medicao` DISABLE KEYS */; /*!40000 ALTER TABLE `evento_medicao` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `evento_medicao_classificacao_alerta` -- DROP TABLE IF EXISTS `evento_medicao_classificacao_alerta`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!50503 SET character_set_client = utf8mb4 */; CREATE TABLE `evento_medicao_classificacao_alerta` ( `id` bigint NOT NULL AUTO_INCREMENT, `tipo` varchar(255) NOT NULL, `intensidade` int NOT NULL, `disparar_alertas` bit(1) NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `evento_medicao_classificacao_alerta` -- LOCK TABLES `evento_medicao_classificacao_alerta` WRITE; /*!40000 ALTER TABLE `evento_medicao_classificacao_alerta` DISABLE KEYS */; INSERT INTO `evento_medicao_classificacao_alerta` VALUES (1,'GENERICO',40,_binary ''),(2,'PRESSAO',40,_binary ''),(3,'TREMORES',40,_binary ''),(4,'TREMORES',60,_binary ''),(5,'NIVEL_ARMAZENAMENTO',40,_binary ''),(6,'NIVEL_ARMAZENAMENTO',60,_binary ''),(7,'NIVEL_ARMAZENAMENTO',80,_binary ''),(8,'NIVEL_ARMAZENAMENTO',100,_binary ''),(9,'NIVEL_ARMAZENAMENTO',150,_binary ''),(10,'NIVEL_ARMAZENAMENTO',90,_binary '\0'); /*!40000 ALTER TABLE `evento_medicao_classificacao_alerta` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `incidente` -- DROP TABLE IF EXISTS `incidente`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!50503 SET character_set_client = utf8mb4 */; CREATE TABLE `incidente` ( `id` bigint NOT NULL AUTO_INCREMENT, `identificador` varchar(36) NOT NULL, `data` datetime NOT NULL, `classificacao` int NOT NULL, `barragem_id` bigint NOT NULL, PRIMARY KEY (`id`), KEY `fk_incidente_barragem_id` (`barragem_id`), CONSTRAINT `fk_incidente_barragem_id` FOREIGN KEY (`barragem_id`) REFERENCES `barragem` (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `incidente` -- LOCK TABLES `incidente` WRITE; /*!40000 ALTER TABLE `incidente` DISABLE KEYS */; /*!40000 ALTER TABLE `incidente` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `incidente_resultado_processamento` -- DROP TABLE IF EXISTS `incidente_resultado_processamento`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!50503 SET character_set_client = utf8mb4 */; CREATE TABLE `incidente_resultado_processamento` ( `id` bigint NOT NULL AUTO_INCREMENT, `incidente_identificador` varchar(36) NOT NULL, `incidente_classificacao` int NOT NULL, `sucesso` bit(1) NOT NULL, `data` datetime NOT NULL, `mensagem` varchar(10000) NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `incidente_resultado_processamento` -- LOCK TABLES `incidente_resultado_processamento` WRITE; /*!40000 ALTER TABLE `incidente_resultado_processamento` DISABLE KEYS */; /*!40000 ALTER TABLE `incidente_resultado_processamento` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `jhi_persistent_audit_event` -- DROP TABLE IF EXISTS `jhi_persistent_audit_event`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!50503 SET character_set_client = utf8mb4 */; CREATE TABLE `jhi_persistent_audit_event` ( `event_id` bigint NOT NULL AUTO_INCREMENT, `principal` varchar(50) NOT NULL, `event_date` timestamp NULL DEFAULT NULL, `event_type` varchar(255) DEFAULT NULL, PRIMARY KEY (`event_id`), KEY `idx_persistent_audit_event` (`principal`,`event_date`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `jhi_persistent_audit_event` -- LOCK TABLES `jhi_persistent_audit_event` WRITE; /*!40000 ALTER TABLE `jhi_persistent_audit_event` DISABLE KEYS */; /*!40000 ALTER TABLE `jhi_persistent_audit_event` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `jhi_persistent_audit_evt_data` -- DROP TABLE IF EXISTS `jhi_persistent_audit_evt_data`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!50503 SET character_set_client = utf8mb4 */; CREATE TABLE `jhi_persistent_audit_evt_data` ( `event_id` bigint NOT NULL, `name` varchar(150) NOT NULL, `value` varchar(255) DEFAULT NULL, PRIMARY KEY (`event_id`,`name`), KEY `idx_persistent_audit_evt_data` (`event_id`), CONSTRAINT `fk_evt_pers_audit_evt_data` FOREIGN KEY (`event_id`) REFERENCES `jhi_persistent_audit_event` (`event_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `jhi_persistent_audit_evt_data` -- LOCK TABLES `jhi_persistent_audit_evt_data` WRITE; /*!40000 ALTER TABLE `jhi_persistent_audit_evt_data` DISABLE KEYS */; /*!40000 ALTER TABLE `jhi_persistent_audit_evt_data` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `sensor` -- DROP TABLE IF EXISTS `sensor`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!50503 SET character_set_client = utf8mb4 */; CREATE TABLE `sensor` ( `id` bigint NOT NULL AUTO_INCREMENT, `identificador` varchar(36) NOT NULL, `nome` varchar(60) NOT NULL, `tipo` varchar(255) NOT NULL, `observacoes` varchar(255) DEFAULT NULL, `barragem_id` bigint NOT NULL, PRIMARY KEY (`id`), UNIQUE KEY `ux_sensor_identificador` (`identificador`), KEY `fk_sensor_barragem_id` (`barragem_id`), CONSTRAINT `fk_sensor_barragem_id` FOREIGN KEY (`barragem_id`) REFERENCES `barragem` (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `sensor` -- LOCK TABLES `sensor` WRITE; /*!40000 ALTER TABLE `sensor` DISABLE KEYS */; INSERT INTO `sensor` VALUES (1,'bec517b7-ee25-4466-8bd9-f9462cf879f0','Sensor Analógicodo Nível de Pressão 01','PRESSAO','Sensor Analógicodo Nível de Pressão 01 - Alimentação Passivo (Piezômetro)',1),(2,'e6c9cb82-99f9-4bea-9c73-b7c1a98c9b6c','Sensor Digital do Nível de Armazenamento Rejeitos 01','NIVEL_ARMAZENAMENTO','Sensor Digital do Nível de Armazenamento Rejeitos 01 - Alimentação Ativo (Piezômetro elétrico)',2),(3,'020deb12-6c33-4198-936b-25c6431f0703','Sensor Digital de tremores/Entorno Barragem 01','TREMORES','Sensor Digital de tremores/Entorno Barragem 01 - Alimentação Ativo (Sonda inclinométrica)',3),(4,'d8318bbc-19a1-428f-9fba-c6cdd70c52b7','Sensor Analógico de tremores/Entorno Barragem 02','TREMORES','Sensor Analógico de tremores/Entorno Barragem 02 - Alimentação Passivo (Sonda inclinométrica)',4),(5,'575048d1-ec28-4c66-90b8-fd7f3709ce0b','Sensor Analógico de medição Genérico 01','GENERICO','Sensor Analógico de medição Genérico 01 - Alimentação Ativo (Piezômetro pneumático)',5),(6,'241d60e0-1bc6-4dbd-a462-a9c2aed7dbf0','Sensor Digital do Nível de Armazenamento Rejeitos 02','NIVEL_ARMAZENAMENTO','Sensor Digital do Nível de Armazenamento Rejeitos 02 - Alimentação Ativo ((Piezômetro elétrico))',6),(7,'f3ba7b02-85c5-4963-8e53-fa7f488a53c6','Sensor Digital de medição Genérico 02','GENERICO','Sensor Digital de medição Genérico 02 - Alimentação Ativo (Célula de pressão)',7),(8,'c5e087db-de23-4d76-84cf-bfb15bfce608','Sensor Digital de medição Genérico 03','GENERICO','Sensor Digital de medição Genérico 03 - Alimentação Ativo (Medidor de vazão)',8),(9,'4eb7e55b-b2a1-41fd-8e5d-4b6d85c0f210','Sensor Analógico de medição Genérico 04','GENERICO','Sensor Analógico de medição Genérico 04 - Alimentação Passivo (Marco de referência com teodolito)',9),(10,'8dd03afc-7622-4a4c-9832-a221e310f390','Sensor Digital de tremores/Entorno Barragem 03','TREMORES','Sensor Digital de tremores/Entorno Barragem 03 - Alimentação Passivo (Marco topográfico)',10); /*!40000 ALTER TABLE `sensor` ENABLE KEYS */; UNLOCK TABLES; -- -- Dumping events for database 'tccscapucminasbackendapimonitoramentobarragens' -- -- -- Dumping routines for database 'tccscapucminasbackendapimonitoramentobarragens' -- /*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */; /*!40101 SET SQL_MODE=@OLD_SQL_MODE */; /*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */; /*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */; /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */; /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */; /*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */; -- Dump completed on 2020-04-10 11:29:29
<gh_stars>1-10  update Variable set Name = substring(name, 0, 28) + '.Presence' where Name like 'Philips%.Presence'
<gh_stars>10-100 DROP VIEW IF EXISTS bebyggelser_view CASCADE; CREATE VIEW bebyggelser_view AS ( SELECT s.id, sn.navn, s.hovedtype, s.undertype AS type, sn.navnestatus, bebyggelseskode AS kode, s.visueltcenter, s.ændret, s.geo_ændret, s.geo_version, s.geom FROM steder s JOIN stednavne sn ON s.id = sn.stedid AND sn.brugsprioritet = 'primær' WHERE s.hovedtype = 'Bebyggelse' );
CREATE TABLE IF NOT EXISTS public.pose_data ( msg_id VARCHAR(36), camera_location VARCHAR(20), msg_type VARCHAR(20), identified_action VARCHAR(40), event_time TIMESTAMP, event_time_qs VARCHAR(20), person_count SMALLINT, s3uri VARCHAR(150)) DISTKEY(camera_location) SORTKEY(event_time_qs);
<reponame>DanielHeath/activefacts-compositions vocabulary Ternary; Thing is written as Thing; // Two uniqueness constraints over the same Ternary // Check that the computed indices work correctly: each Ternary is where some first- Thing with some second- Thing relates to one third- Thing, that third Thing holds that second Thing for one first-Thing;
alter table "public"."transactions" add column "address" text null;
ALTER TABLE vetd.enums
<gh_stars>100-1000 -- bind.test -- -- db eval {DELETE FROM t4} DELETE FROM t4
<gh_stars>100-1000 -- fts3near.test -- -- execsql { -- SELECT docid FROM t1 WHERE content MATCH '"one three" NEAR/0 "four five"' -- } SELECT docid FROM t1 WHERE content MATCH '"one three" NEAR/0 "four five"'
USE [perpetuumsa] GO ------------------------------------------------------------ --Beta 1 Pitboss loot updates --Updated quantities and new entries for smooth and higher quantity loot drops -- --Date modified: 2020/05/15 ------------------------------------------------------------ --BETA 1 PITBOSS:LOOT DROP TABLE IF EXISTS #NPCLOOTS; CREATE TABLE #NPCLOOTS ( defName VARCHAR(100) NOT NULL, probability float NOT NULL, minQuantity int NOT NULL, maxQuantity int NOT NULL, dontDmg bit NOT NULL, repackaged bit NOT NULL, ); INSERT INTO #NPCLOOTS (defName, probability, minQuantity, maxQuantity, dontDmg, repackaged) VALUES ('def_common_reactor_plasma', 1.0, 80000, 200000, 1, 1), ('def_pelistal_reactor_plasma', 1.0, 80000, 200000, 1, 1), ('def_nuimqol_reactor_plasma', 1.0, 80000, 200000, 1, 1), ('def_thelodica_reactor_plasma', 1.0, 80000, 200000, 1, 1), ('def_kernel_pelistal', 1.0, 75000, 125000, 1, 1), ('def_kernel_thelodica', 1.0, 75000, 125000, 1, 1), ('def_kernel_nuimqol', 1.0, 75000, 125000, 1, 1), ('def_kernel_common', 1.0, 75000, 125000, 1, 1), ('def_kernel_hitech', 1.0, 15000, 25000, 1, 1), ('def_robotshard_common_basic', 1.0, 500, 2000, 1, 1), ('def_robotshard_common_advanced', 1.0, 500, 2000, 1, 1), ('def_robotshard_common_expert', 1.0, 500, 2000, 1, 1), ('def_robotshard_nuimqol_basic', 1.0, 500, 2000, 1, 1), ('def_robotshard_nuimqol_advanced', 1.0, 500, 2000, 1, 1), ('def_robotshard_nuimqol_expert', 1.0, 500, 2000, 1, 1), ('def_robotshard_pelistal_basic', 1.0, 500, 2000, 1, 1), ('def_robotshard_pelistal_advanced', 1.0, 500, 2000, 1, 1), ('def_robotshard_pelistal_expert', 1.0, 500, 2000, 1, 1), ('def_robotshard_thelodica_basic', 1.0, 500, 2000, 1, 1), ('def_robotshard_thelodica_advanced', 1.0, 500, 2000, 1, 1), ('def_robotshard_thelodica_expert', 1.0, 500, 2000, 1, 1), ('def_research_kit_9', 1.0, 2, 5, 1, 1), ('def_research_kit_10', 1.0, 2, 5, 1, 1), ('def_boost_ep_t0', 1.0, 2, 5, 1, 1), ('def_boost_ep_t1', 1.0, 1, 2, 1, 1), ('def_reactore_core_runner', 1.0, 1, 2, 1, 1), ('def_reactore_core_assault', 1.0, 1, 2, 1, 1), ('def_reactore_core_mech', 1.0, 1, 2, 1, 1), ('def_reactore_core_heavymech', 1.0, 1, 2, 1, 1), --Add 3x entries to get 3x 25% chance to get CT ('def_scarab_mk2_A_CT_capsule', 0.25, 1, 1, 1, 1), ('def_gropho_mk2_A_CT_capsule', 0.25, 1, 1, 1, 1), ('def_mesmer_mk2_A_CT_capsule', 0.25, 1, 1, 1, 1), ('def_seth_mk2_A_CT_capsule', 0.25, 1, 1, 1, 1), ('def_scarab_mk2_A_CT_capsule', 0.25, 1, 1, 1, 1), ('def_gropho_mk2_A_CT_capsule', 0.25, 1, 1, 1, 1), ('def_mesmer_mk2_A_CT_capsule', 0.25, 1, 1, 1, 1), ('def_seth_mk2_A_CT_capsule', 0.25, 1, 1, 1, 1), ('def_scarab_mk2_A_CT_capsule', 0.25, 1, 1, 1, 1), ('def_gropho_mk2_A_CT_capsule', 0.25, 1, 1, 1, 1), ('def_mesmer_mk2_A_CT_capsule', 0.25, 1, 1, 1, 1), ('def_seth_mk2_A_CT_capsule', 0.25, 1, 1, 1, 1), --Add 3x entries to get 3x 11% chance to get nexus modules ('def_named2_gang_assist_speed_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_information_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_industry_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_siege_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_defense_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_ewar_range_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_shared_dataprocessing_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_coordinated_maneuvering_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_maintance_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_precision_firing_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_core_management_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_fast_extraction_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_shield_calculation_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_speed_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_information_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_industry_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_siege_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_defense_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_ewar_range_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_shared_dataprocessing_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_coordinated_maneuvering_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_maintance_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_precision_firing_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_core_management_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_fast_extraction_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_shield_calculation_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_speed_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_information_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_industry_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_siege_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_defense_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_ewar_range_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_shared_dataprocessing_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_coordinated_maneuvering_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_maintance_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_precision_firing_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_core_management_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_fast_extraction_module', 0.11, 1, 1, 0, 1), ('def_named2_gang_assist_shield_calculation_module', 0.11, 1, 1, 0, 1); DECLARE @definitionID int; SET @definitionID = (SELECT TOP 1 definition from entitydefaults WHERE [definitionname] = 'def_npc_beta1_pitboss' ORDER BY definition DESC); PRINT N'BETA 1 PITBOSS:LOOT'; PRINT N'Delete old loot'; DELETE FROM npcloot WHERE definition=@definitionID; PRINT N'Add loot'; INSERT INTO npcloot ([definition],[lootdefinition],[quantity],[probability],[repackaged],[dontdamage],[minquantity]) SELECT @definitionID, (SELECT TOP 1 definition FROM entitydefaults WHERE definitionname=defName), maxQuantity, probability, repackaged, dontDmg, minQuantity FROM #NPCLOOTS; DROP TABLE IF EXISTS #NPCLOOTS; GO
CREATE DATABASE IF NOT EXISTS ocr_project; USE ocr_project; CREATE TABLE IF NOT EXISTS `owner` ( `OWNER_ID` int unsigned NOT NULL, `FIRST_NAME` varchar(50) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '', `LAST_NAME` varchar(50) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '', `ADDRESS` varchar(50) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '', `CITY` varchar(50) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '', `STATE` varchar(50) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '', `ZIP_CODE` int unsigned NOT NULL, `PHONE_NUMBER` varchar(14) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '', PRIMARY KEY (`OWNER_ID`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; CREATE TABLE IF NOT EXISTS `vehicle` ( `VIN_ID` varchar(20) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '', `VEHICLE_BRAND` varchar(20) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '', `MODEL` varchar(50) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '', `COLOR` varchar(20) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '', `TYPE` varchar(20) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '', `OWNER_ID` int unsigned NOT NULL, PRIMARY KEY (`VIN_ID`), KEY `FK_vehicle_OWNER_ID` (`OWNER_ID`), CONSTRAINT `FK_vehicle_OWNER_ID` FOREIGN KEY (`OWNER_ID`) REFERENCES `owner` (`OWNER_ID`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; CREATE TABLE IF NOT EXISTS `license` ( `LICENSE_ID` varchar(20) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '', `OWNER_ID` int unsigned NOT NULL, `VIN_ID` varchar(17) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '', `ISSUE_DATE` date NOT NULL, `EXPIRATION_DATE` date NOT NULL, `LICENSE_FEE` int unsigned NOT NULL, PRIMARY KEY (`LICENSE_ID`), KEY `FK_license_OWNER_ID` (`OWNER_ID`), KEY `FK_license_VIN_ID` (`VIN_ID`), CONSTRAINT `FK_license_OWNER_ID` FOREIGN KEY (`OWNER_ID`) REFERENCES `owner` (`OWNER_ID`), CONSTRAINT `FK_license_VIN_ID` FOREIGN KEY (`VIN_ID`) REFERENCES `vehicle` (`VIN_ID`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; CREATE TABLE IF NOT EXISTS `vehiclehistory` ( `EVENT_ID` int unsigned NOT NULL, `VIN_ID` varchar(17) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '', `EVENT_DATE` date NOT NULL, `EVENT_DESC` mediumtext CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL, PRIMARY KEY (`EVENT_ID`), KEY `FK_vehiclehistory_VIN_ID` (`VIN_ID`), CONSTRAINT `FK_vehiclehistory_VIN_ID` FOREIGN KEY (`VIN_ID`) REFERENCES `vehicle` (`VIN_ID`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; CREATE TABLE IF NOT EXISTS `emission` ( `INSPECTION_ID` int unsigned NOT NULL, `VIN_ID` varchar(17) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '', `EMISSION_LEVEL_ACC` bool NOT NULL, `INSPECTION_DATE` date NOT NULL, PRIMARY KEY (`INSPECTION_ID`), KEY `FK_emission_VIN_ID` (`VIN_ID`), CONSTRAINT `FK_emission_VIN_ID` FOREIGN KEY (`VIN_ID`) REFERENCES `vehicle` (`VIN_ID`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; CREATE TABLE IF NOT EXISTS `insurance` ( `INSURANCE_ID` varchar(15) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '', `OWNER_ID` int unsigned NOT NULL, `VIN_ID` varchar(17) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL, `EFFECTIVE_DATE` date NOT NULL, `IN_EXPIRATION_DATE` date NOT NULL, `IN_TYPE` varchar(15) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '', PRIMARY KEY (`INSURANCE_ID`), KEY `FK_insurance_OWNER_ID` (`OWNER_ID`), KEY `FK_insurance_VIN_ID` (`VIN_ID`), CONSTRAINT `FK_insurance_OWNER_ID` FOREIGN KEY (`OWNER_ID`) REFERENCES `owner` (`OWNER_ID`), CONSTRAINT `FK_insurance_VIN_ID` FOREIGN KEY (`VIN_ID`) REFERENCES `vehicle` (`VIN_ID`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
<filename>dbt-greenery/models/example/fact_events.sql {{ config( materialized='table' ) }} {% set event_types = ['add_to_cart','checkout','page_view','delete_from_cart','account_created','package_shipped'] %} select session_id, created_at, user_id {% for event_type in event_types %}, sum(CASE WHEN event_type = '{{event_type}}' THEN 1 ELSE 0 END) as {{event_type}}_count {% endfor %} FROM {{ ref('stg_events') }} GROUP BY 1,2,3
<gh_stars>10-100 CREATE TABLE EDWIN_TEAM_CFG ( OWNER_TEAM_CODE NVARCHAR2(50) , EMAIL_TO_LIST VARCHAR2(255) , SMS_MAIL_TO VARCHAR2(255) , SMS_MAIL_TITLE NVARCHAR2(255) , PHONE_MAIL_TO VARCHAR2(255) , PHONE_MAIL_TITLE NVARCHAR2(255) ); ALTER TABLE EDWIN_TEAM_CFG ADD CONSTRAINT PK_EDWIN_TEAM_CFG PRIMARY KEY (OWNER_TEAM_CODE); CREATE TABLE EDWIN_CHECK_ITM_CFG ( ITM_CODE NVARCHAR2(50) not null ,ITM_TITLE NVARCHAR2(50) not null ,ITM_CATEGORY NVARCHAR2(50) not null ,ENABLED_FLAG CHAR(1) default 'Y' not null ,HOST NVARCHAR2(50) --only for reference ,CHECK_SCRIPT NVARCHAR2(255) --only for reference ,CHECK_INTERVAL_MINUTE NUMBER not null --, -1 for one that need not check outdated ,CHECK_VALUE_IS_NUMBER CHAR(1) default 'N' not null ,DESCRIPTION NVARCHAR2(255) ,OWNER_TEAM_LIST NVARCHAR2(150) NOT NULL -- team_code list, delimited by ; or , symbol ,WARNING_LIMIT NUMBER -- mandatory column if CHECK_VALUE_IS_NUMBER=Y ,CRITICAL_LIMIT NUMBER -- mandatory column if CHECK_VALUE_IS_NUMBER=Y ,SHADOW_DATA VARCHAR2(150) -- we can use this column to store any data. The value will copy to EDWIN_CHECK_ITM_LOG table when checking result recorded ,WARNING_MAIL_CC VARCHAR2(255) ,CRITICAL_MAIL_CC VARCHAR2(255) ,CRITICAL_SMS_FLAG CHAR(1) default 'N' NOT NULL ,CRITICAL_CALL_FLAG CHAR(1) default 'N' NOT NULL ,ALLOW_REPEATED_SMS_ALARM CHAR(1) default 'N' NOT NULL ,ALLOW_REPEATED_CALL_ALARM CHAR(1) default 'N' NOT NULL ,ALLOW_REPEATED_MAIL_ALARM CHAR(1) default 'N' NOT NULL ) ; ALTER TABLE EDWIN_CHECK_ITM_CFG ADD CONSTRAINT PK_EDWIN_CHECK_ITM_CFG PRIMARY KEY (ITM_CODE); create table EDWIN_PAGE ( PAGE_CODE NVARCHAR2(50) not null, PAGE_TITLE NVARCHAR2(50) not null, DISPLAY_FLAG CHAR(1) default 'Y' not null, DESCRIPTION NVARCHAR2(255) ) ; ALTER TABLE EDWIN_PAGE ADD CONSTRAINT PK_EDWIN_PAGE PRIMARY KEY (PAGE_CODE); create table EDWIN_PAGELET ( PAGELET_CODE NVARCHAR2(50) not null, PAGELET_TITLE NVARCHAR2(50) not null, PAGE_CODE VARCHAR2(50) not null, DISPLAY_ORDER NUMBER not null, DISPLAY_FLAG CHAR(1) default 'Y' not null, DESCRIPTION NVARCHAR2(255) ) ; ALTER TABLE EDWIN_PAGELET ADD CONSTRAINT PK_EDWIN_PAGELET PRIMARY KEY (PAGELET_CODE); create table EDWIN_PAGELET_CHECK_LIST ( PAGELET_CODE NVARCHAR2(50) not null, CHECK_ITM_CODE NVARCHAR2(50) not null, DISPLAY_ORDER NUMBER not null, DISPLAY_FLAG CHAR(1) default 'Y' not null ) ; ALTER TABLE EDWIN_PAGELET_CHECK_LIST ADD CONSTRAINT PK_EDWIN_PAGELET_CHECK_LIST PRIMARY KEY (PAGELET_CODE,CHECK_ITM_CODE); CREATE TABLE EDWIN_CALENDAR_DAY ( DATE_ID VARCHAR2(8) ,WEEK_ID VARCHAR2(10) ,MONTH_ID VARCHAR2(6) ,YEAR_ID VARCHAR2(4) ) ; ALTER TABLE EDWIN_CALENDAR_DAY ADD CONSTRAINT PK_EDWIN_CALENDAR_DAY PRIMARY KEY (DATE_ID); CREATE TABLE EDWIN_CHECK_ITM_STATUS ( ITM_CODE NVARCHAR2(50) not null, LAST_CHECK_TIMESTAMP VARCHAR2(30), LAST_STATUS VARCHAR2(10), LAST_VALUE NUMBER, LAST_DETAIL_MSG nclob, LAST_NOTIFICATION_MSG nclob, IS_WARNING_EVENT CHAR(1), IS_CRITICAL_EVENT CHAR(1), IS_NEW_CRITICAL_EVENT CHAR(1), IS_NEW_WARNING_EVENT CHAR(1) ) ; ALTER TABLE EDWIN_CHECK_ITM_STATUS ADD CONSTRAINT PK_EDWIN_CHECK_ITM_STATUS PRIMARY KEY (ITM_CODE); CREATE TABLE EDWIN_CHECK_ITM_LOG ( ITM_CODE NVARCHAR2(50) not null ,CHECK_DATE VARCHAR2(10) NOT NULL --format is '2014-01-17' ,CHECK_TIMESTAMP VARCHAR2(30) not NULL --format is '2014-01-17 16:20:27.783999' ,CHECK_STATUS VARCHAR2(50) not NULL ,CHECK_VALUE NUMBER ,CHECK_DETAIL_MSG nclob ,CHECK_NOTIFICATION_MSG nclob ,WARNING_LIMIT NUMBER ,CRITICAL_LIMIT NUMBER ,SHADOW_DATA VARCHAR2(150) ,IS_WARNING_EVENT CHAR(1) DEFAULT 'N' NOT NULL ,IS_CRITICAL_EVENT CHAR(1) DEFAULT 'N' NOT NULL ,IS_NEW_CRITICAL_EVENT CHAR(1) DEFAULT 'N' NOT NULL ,IS_NEW_WARNING_EVENT CHAR(1) DEFAULT 'N' NOT NULL ,ALARM_SEND_STATUS VARCHAR2(10) NOT NULL ,ALARM_SEND_BEGIN_TIME VARCHAR2(30) ,ALARM_SEND_END_TIME VARCHAR2(30) ) ; create index IDX_EDWIN_CHECK_ITM_LOG_1 on EDWIN_CHECK_ITM_LOG (ITM_CODE); create index IDX_EDWIN_CHECK_ITM_LOG_2 on EDWIN_CHECK_ITM_LOG (CHECK_DATE); create index IDX_EDWIN_CHECK_ITM_LOG_3 on EDWIN_CHECK_ITM_LOG (CHECK_TIMESTAMP);
/* OneFileModule module : ExcelReader by Thierry (Tiptopweb) Updated 13. sep 2005 This patch introduces the following changes to the db: - Inserts entry in table rb_GeneralModuleDefinitions - Inserts entry in table rb_ModuleDefinitions Deinstalling: First remove the module from all pages then run this script (in module Database Tool): DELETE FROM rb_GeneralModuleDefinitions WHERE FriendlyName = 'ExcelReader (OneFileModule)' */ USE [Appleseed] GO -- If you install using module "Admin - Database Tool" then copy all lines from below: DECLARE @GeneralModDefID uniqueidentifier DECLARE @FriendlyName nvarchar(128) DECLARE @DesktopSrc nvarchar(256) DECLARE @MobileSrc nvarchar(256) DECLARE @AssemblyName varchar(50) DECLARE @ClassName nvarchar(128) DECLARE @Admin bit DECLARE @Searchable bit SET @GeneralModDefID = NEWID() -- Or if you want full control: = '{1E03D793-5A01-4f35-811D-5D23EF66618D}' SET @FriendlyName = 'ExcelReader (OneFileModule)' -- You enter the module UI name here SET @DesktopSrc = 'DesktopModules/ExcelReader.ascx' -- You enter actual filename here SET @MobileSrc = '' SET @AssemblyName = 'Appleseed.Modules.OneFileModule.dll' SET @ClassName = 'Appleseed.Content.Web.ModulesOneFileModule' SET @Admin = 0 SET @Searchable = 0 IF NOT EXISTS (SELECT DesktopSrc FROM rb_GeneralModuleDefinitions WHERE DesktopSrc = @DesktopSrc) BEGIN -- Installs module EXEC [rb_AddGeneralModuleDefinitions] @GeneralModDefID, @FriendlyName, @DesktopSrc, @MobileSrc, @AssemblyName, @ClassName, @Admin, @Searchable -- Install it for default portal EXEC [rb_UpdateModuleDefinitions] @GeneralModDefID, 0, 1 END
select sub.repo_group, round(count(distinct sub.sha) / {{n}}, 2) as commits from ( select 'commits,' || coalesce(ecf.repo_group, r.repo_group) as repo_group, c.sha from gha_repos r, gha_commits c left join gha_events_commits_files ecf on ecf.event_id = c.event_id where r.name = c.dup_repo_name and c.dup_created_at >= '{{from}}' and c.dup_created_at < '{{to}}' and (lower(c.dup_actor_login) {{exclude_bots}}) ) sub where sub.repo_group is not null group by sub.repo_group order by commits desc, repo_group asc ;
DROP TABLE IF EXISTS `qq_group`; CREATE TABLE `qq_group` ( `id` bigint unsigned AUTO_INCREMENT NOT NULL COMMENT 'id', `name` char(255) NOT NULL COMMENT 'QQ群名', `number` char(255) NOT NULL COMMENT 'QQ群号', `build_year` year COMMENT 'QQ群建立年', `description` char(255) COMMENT '描述', `pic` json COMMENT '图片', `link` char(255) COMMENT '加群链接', `qty` int unsigned NOT NULL DEFAULT 0 COMMENT '群里人员', `ordering` int NOT NULL DEFAULT 0 COMMENT '排序', PRIMARY KEY (`id`), UNIQUE KEY (`number`) ) ENGINE=INNODB COMMENT 'QQ群';
<filename>sqlserver/test/test_proc.sql IF EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[GetDatadogMetricsTest]') AND type in (N'P', N'PC')) DROP PROCEDURE [dbo].[GetDatadogMetricsTest] GO SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO -- ======================================================================================= -- Description: Gets metrics for Datadog -- ======================================================================================= CREATE PROCEDURE [dbo].[GetDatadogMetricsTest] AS BEGIN set transaction isolation level read uncommitted set nocount on -- if the DB is read only then we must be a secondary so don't report any data IF (SELECT CONVERT(sysname,DatabasePropertyEx(DB_NAME(),'Updateability'))) = 'READ_ONLY' RETURN CREATE TABLE #Datadog ( [metric] varchar(255) not null, [type] varchar(50) not null, [value] float not null, [tags] varchar(255) ) INSERT INTO #Datadog (metric, type, value, tags) VALUES ('sql.test.gauge', 'gauge', 5, 'tag:test') ,('sql.test.rate', 'rate', 500, null) ,('sql.test.histogram', 'histogram', FLOOR(RAND()*20), null) SELECT * FROM #Datadog END GO GRANT EXECUTE ON [dbo].[GetDatadogMetricsTest] To Public GO
-- @testpoint: 创建行存分区表,分区字段设为name -- @modified at: 2020-11-13 drop table if exists name_12; CREATE TABLE name_12 (c1 clob,c2 int) WITH (orientation=row, compression=no) PARTITION BY RANGE (c1) ( PARTITION P1 VALUES LESS THAN('g'), PARTITION P2 VALUES LESS THAN('n'), PARTITION P3 VALUES LESS THAN('q'), PARTITION P4 VALUES LESS THAN('t'), PARTITION P5 VALUES LESS THAN('z') ); insert into name_12 values ('i',1); select * from name_12; drop table name_12;
-- @testpoint: opengauss关键字Implementation(非保留),作为同义词对象名,部分测试点合理报错 --前置条件 drop table if exists explain_test; create table explain_test(id int,name varchar(10)); --关键字不带引号-成功 drop synonym if exists Implementation; create synonym Implementation for explain_test; insert into Implementation values (1,'ada'),(2, 'bob'); update Implementation set Implementation.name='cici' where Implementation.id=2; select * from Implementation; --关键字带双引号-成功 drop synonym if exists "Implementation"; create synonym "Implementation" for explain_test; --关键字带单引号-合理报错 drop synonym if exists 'Implementation'; create synonym 'Implementation' for explain_test; insert into 'Implementation' values (1,'ada'),(2, 'bob'); update 'Implementation' set 'Implementation'.name='cici' where 'Implementation'.id=2; select * from 'Implementation'; --关键字带反引号-合理报错 drop synonym if exists `Implementation`; create synonym `Implementation` for explain_test; insert into `Implementation` values (1,'ada'),(2, 'bob'); update `Implementation` set `Implementation`.name='cici' where `Implementation`.id=2; select * from `Implementation`; --清理环境 drop synonym if exists implementation; drop synonym if exists "Implementation"; drop table if exists explain_test;
-- -- Nested loop join with index scan on CO table, test for MPP-17658 -- create schema co_nestloop_idxscan; create table co_nestloop_idxscan.foo (id bigint, data text) with (appendonly=true, orientation=column) distributed by (id); create table co_nestloop_idxscan.bar (id bigint) distributed by (id); -- Changing the text to be smaller doesn't repro the issue insert into co_nestloop_idxscan.foo select 1, repeat('xxxxxxxxxx', 100000); insert into co_nestloop_idxscan.bar values (1); create index foo_id_idx on co_nestloop_idxscan.foo(id); -- test with hash join explain select f.id from co_nestloop_idxscan.foo f, co_nestloop_idxscan.bar b where f.id = b.id; select f.id from co_nestloop_idxscan.foo f, co_nestloop_idxscan.bar b where f.id = b.id; -- test with nested loop join set enable_hashjoin=off; explain select f.id from co_nestloop_idxscan.foo f, co_nestloop_idxscan.bar b where f.id = b.id; select f.id from co_nestloop_idxscan.foo f, co_nestloop_idxscan.bar b where f.id = b.id; -- test with nested loop join and index scan set enable_seqscan = off; explain select f.id from co_nestloop_idxscan.foo f, co_nestloop_idxscan.bar b where f.id = b.id; select f.id from co_nestloop_idxscan.foo f, co_nestloop_idxscan.bar b where f.id = b.id; drop schema co_nestloop_idxscan cascade;
-- Create entities (tables) CREATE TABLE "Booking"( id SERIAL NOT NULL PRIMARY KEY, table_number INTEGER NOT NULL, customer_fname VARCHAR(64) NOT NULL, customer_lname VARCHAR(64), customer_email VARCHAR(128), customer_phone_no VARCHAR(20) NOT NULL, date_booked TIMEsTAMP WITH TIME ZONE NOT NULL, date_booked_for TIMEsTAMP WITH TIME ZONE NOT NULL, status VARCHAR(15) NOT NULL ); CREATE TABLE "Table"( t_number SERIAL NOT NULL PRIMARY KEY, details VARCHAR(50) ); CREATE TABLE "Order"( id SERIAL NOT NULL PRIMARY KEY, booking_id INTEGER NOT NULL, table_number INTEGER NOT NULL, order_date TIMESTAMP WITH TIME ZONE NOT NULL ); CREATE TABLE "Order_menu_item"( id SERIAL NOT NULL PRIMARY KEY, order_id INTEGER NOT NULL, menu_item_id INTEGER NOT NULL, quantity DECIMAL(12) NOT NULL, comments VARCHAR(128) ); CREATE TABLE "Menu_item"( id SERIAL NOT NULL PRIMARY KEY, menu_id INTEGER NOT NULL, name VARCHAR(80) NOT NULL, price DECIMAL(12) NOT NULL, link VARCHAR(2048) NOT NULL, description VARCHAR(512) ); CREATE TABLE "Menu"( id SERIAL NOT NULL PRIMARY KEY, menu_date DATE NOT NULL, description VARCHAR(128) ); CREATE TABLE "Menu_item_ingredient"( id SERIAL NOT NULL PRIMARY KEY, ingredient_id INTEGER NOT NULL, menu_item_id INTEGER NOT NULL, item_quantity DECIMAL(12) NOT NULL, standart_cost DECIMAL(12) NOT NULL ); CREATE TABLE "Ingredient"( id SERIAL NOT NULL PRIMARY KEY, type_code INTEGER NOT NULL, name VARCHAR(42) NOT NULL ); CREATE TABLE "Ingredient_type"( code INTEGER NOT NULL PRIMARY KEY, description VARCHAR(20) NOT NULL ); CREATE TABLE "Supplier"( id SERIAL NOT NULL PRIMARY KEY, ingredient_type_code INTEGER, company_name VARCHAR(64) NOT NULL, address VARCHAR(30) NOT NULL, phone_number VARCHAR(20) NOT NULL, email_address VARCHAR(128) NOT NULL ); CREATE TABLE "Platform"( name VARCHAR(12) NOT NULL PRIMARY KEY, query_count INTEGER ); CREATE TABLE "User" ( id UUID NOT NULL PRIMARY KEY, username VARCHAR(64) NOT NULL, email VARCHAR(128) NOT NULL, password VARCHAR(60) NOT NULL, is_admin BOOLEAN NOT NULL );
DROP TABLE USER; CREATE TABLE USER ( ID INTEGER PRIMARY KEY, NAME VARCHAR(40), PASSWORD VARCHAR(50) ); INSERT INTO USER (ID, NAME, PASSWORD) VALUES(1, 'N<PASSWORD>', '<PASSWORD>'); INSERT INTO USER (ID, NAME, PASSWORD) VALUES(2, '<PASSWORD>', '<PASSWORD>'); INSERT INTO USER (ID, NAME, PASSWORD) VALUES(3, '<PASSWORD>', '<PASSWORD>'); INSERT INTO USER (ID, NAME, PASSWORD) VALUES(4, '<PASSWORD>', '<PASSWORD>'); INSERT INTO USER (ID, NAME, PASSWORD) VALUES(5, '<PASSWORD>', '<PASSWORD>'); INSERT INTO USER (ID, NAME, PASSWORD) VALUES(6, '<PASSWORD>', '<PASSWORD>');
<gh_stars>0 with ranked AS ( SELECT client_id ,purchases_sk ,CAST(time_purchased AS DATE) ,category ,RANK() OVER ( PARTITION BY client_id ORDER BY CAST(time_purchased AS DATE) ASC ) purchase_rank FROM {ref('purchases_transformed')}} WHERE is_refunded = 0 ORDER BY client_id ), next AS ( SELECT client_id ,purchases_sk ,time_purchased ,category ,purchase_rank ,LEAD(category,1) OVER ( PARTITION BY client_id ORDER BY purchase_rank ) next_category ,LEAD(time_purchased,1) OVER ( PARTITION BY client_id ORDER BY purchase_rank ) next_time_purchased FROM ranked ), same_category AS ( SELECT client_id ,purchases_sk ,category ,DATE_PART('day', next_time_purchased::timestamp - time_purchased::timestamp) AS days_difference FROM next WHERE purchase_rank = 1 AND next_category IS NOT NULL AND category = next_category ), different_category AS ( SELECT client_id ,purchases_sk ,category ,next_category FROM next WHERE purchase_rank = 1 AND next_category IS NOT NULL AND category != next_category ) /*SELECT category ,MAX( days_difference) AS max_to_next_purchase ,ROUND(AVG( days_difference)) AS avg_to_next_purchase FROM same_category GROUP BY category */ SELECT category ,next_category ,COUNT(purchases_sk) AS count_of_snd_purchases FROM different_category GROUP BY category, next_category ORDER BY category, COUNT(purchases_sk) DESC
-- phpMyAdmin SQL Dump -- version 4.5.2 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: 04 Jul 2017 pada 14.48 -- Versi Server: 10.1.16-MariaDB -- PHP Version: 7.0.9 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; /*!40101 SET NAMES utf8mb4 */; -- -- Database: `lbr` -- -- -------------------------------------------------------- -- -- Struktur dari tabel `gallery` -- CREATE TABLE `gallery` ( `id` int(255) NOT NULL, `title` varchar(255) NOT NULL, `image` varchar(255) NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=latin1; -- -------------------------------------------------------- -- -- Struktur dari tabel `tb_blog` -- CREATE TABLE `tb_blog` ( `id` int(200) NOT NULL, `title` varchar(255) NOT NULL, `content` text NOT NULL, `date` date NOT NULL, `fk_category` int(20) NOT NULL, `posted_by` varchar(255) NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=latin1; -- -- Dumping data untuk tabel `tb_blog` -- INSERT INTO `tb_blog` (`id`, `title`, `content`, `date`, `fk_category`, `posted_by`) VALUES (1, '<NAME>', 'Blog Home is an unstyled Bootstrap template you can use to quickly create a home page for a Bootstrap based blog website.', '2017-04-06', 2, '<NAME>'), (2, '<NAME>', 'Need Help?\r\nFeeling stuck? Need something more? You can hire a designer to help you with your project or to create a custom build of any theme!', '2017-04-06', 2, '<NAME>'), (4, '<NAME> ', 'Pada tugas awal kalian pernah membuat aplikasi web statis menggunakan CI tentang pariwisata \r\nTambahkan crud pada web kalian tersebut\r\n', '2017-04-26', 2, '<NAME>'), (5, '<NAME>', '<NAME>', '2017-07-11', 2, '<NAME>'); -- -------------------------------------------------------- -- -- Struktur dari tabel `tb_category` -- CREATE TABLE `tb_category` ( `id` int(100) NOT NULL, `category_name` varchar(100) NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=latin1; -- -- Dumping data untuk tabel `tb_category` -- INSERT INTO `tb_category` (`id`, `category_name`) VALUES (1, 'A'), (2, 'Horror'); -- -------------------------------------------------------- -- -- Struktur dari tabel `tb_user` -- CREATE TABLE `tb_user` ( `id` int(255) NOT NULL, `username` varchar(255) NOT NULL, `password` varchar(255) NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=latin1; -- -- Dumping data untuk tabel `tb_user` -- INSERT INTO `tb_user` (`id`, `username`, `password`) VALUES (1, 'admin', '<PASSWORD>'), (2, 'a', '<PASSWORD>'), (3, 'cabela', '90c68b505adc92f4daa4f60031c8281b'); -- -- Indexes for dumped tables -- -- -- Indexes for table `gallery` -- ALTER TABLE `gallery` ADD PRIMARY KEY (`id`); -- -- Indexes for table `tb_blog` -- ALTER TABLE `tb_blog` ADD PRIMARY KEY (`id`); -- -- Indexes for table `tb_category` -- ALTER TABLE `tb_category` ADD PRIMARY KEY (`id`); -- -- Indexes for table `tb_user` -- ALTER TABLE `tb_user` ADD PRIMARY KEY (`id`); -- -- AUTO_INCREMENT for dumped tables -- -- -- AUTO_INCREMENT for table `gallery` -- ALTER TABLE `gallery` MODIFY `id` int(255) NOT NULL AUTO_INCREMENT; -- -- AUTO_INCREMENT for table `tb_blog` -- ALTER TABLE `tb_blog` MODIFY `id` int(200) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=6; -- -- AUTO_INCREMENT for table `tb_category` -- ALTER TABLE `tb_category` MODIFY `id` int(100) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3; -- -- AUTO_INCREMENT for table `tb_user` -- ALTER TABLE `tb_user` MODIFY `id` int(255) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4; /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */; /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
<reponame>CSCfi/ansible-role-shibboleth-idp-configurator<gh_stars>0 # DROP DATABASE IF EXISTS `idp`; CREATE DATABASE IF NOT EXISTS `idp`; USE idp; # DROP TABLE IF EXISTS `StorageRecords`; CREATE TABLE IF NOT EXISTS `StorageRecords` ( `context` varchar(255) NOT NULL, `id` varchar(255) NOT NULL, `expires` bigint(20) DEFAULT NULL, `value` longtext NOT NULL, `version` bigint(20) NOT NULL, PRIMARY KEY (`context`,`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; # DROP TABLE IF EXISTS `shibpid`; CREATE TABLE IF NOT EXISTS `shibpid` ( localEntity VARCHAR(255) NOT NULL, peerEntity VARCHAR(255) NOT NULL, persistentId VARCHAR(50) NOT NULL, principalName VARCHAR(50) NOT NULL, localId VARCHAR(50) NOT NULL, peerProvidedId VARCHAR(50) NULL, creationDate TIMESTAMP NOT NULL, deactivationDate TIMESTAMP NULL, PRIMARY KEY (localEntity, peerEntity, persistentId) ); # DROP TABLE IF EXISTS `tb_st`; CREATE TABLE IF NOT EXISTS tb_st ( uid VARCHAR(100) NOT NULL, sharedToken VARCHAR(50), PRIMARY KEY (uid) ); GRANT ALL ON idp.* TO '{{ shibbolethidp_dbuser }}'@'localhost' IDENTIFIED BY '{{ shibbolethidp_dbpassword }}'; FLUSH PRIVILEGES;
<reponame>arianvaldivieso/pos -- larger_invoice_item_description -- ALTER TABLE `phppos_sales_items` CHANGE `description` `description` TEXT CHARACTER SET utf8 COLLATE utf8_unicode_ci NULL DEFAULT NULL;
<reponame>ElrikSouza/blog-app-api<gh_stars>0 create table user_account ( id uuid primary key, password <PASSWORD>(60) not null, email varchar(255) not null unique ); create table user_profile ( id uuid primary key, account_id uuid not null references user_account(id) on delete cascade, display_name varchar(30) not null, profile_name varchar(30) not null unique, bio varchar(255) );
DROP DATABASE IF EXISTS company_db; CREATE DATABASE company_db; USE company_db; CREATE TABLE departments( id INT NOT NULL AUTO_INCREMENT PRIMARY KEY, department_name VARCHAR(30) NOT NULL ); CREATE TABLE roles( id INT NOT NULL AUTO_INCREMENT PRIMARY KEY, title VARCHAR(30) NOT NULL, salary DECIMAL(10,2) NOT NULL, department_id INT, FOREIGN KEY (department_id) REFERENCES departments(id) ); CREATE TABLE employees( id INT NOT NULL AUTO_INCREMENT PRIMARY KEY, first_name VARCHAR(30) NOT NULL, last_name VARCHAR(30) NOT NULL, roles_id INT, FOREIGN KEY (roles_id) REFERENCES roles(id), manager_id INT, FOREIGN KEY (manager_id) REFERENCES employees(id) on delete set null );
<filename>EmptyStgDB/cfg/Tables/PckgGenConfig.sql CREATE TABLE [cfg].[PckgGenConfig] ( [ID] INT IDENTITY (1, 1) NOT NULL, [Project] VARCHAR (100) NULL, [Package] VARCHAR (100) NULL, [SrcType] VARCHAR (10) NULL, [SrcCode] VARCHAR (MAX) NULL, [DesTabCreateFlag] INT NULL, [DesTab] VARCHAR (100) NULL, [MasterPackage] VARCHAR (100) NULL, [SeqOrder] INT NULL, PRIMARY KEY CLUSTERED ([ID] ASC), CONSTRAINT [UQ_PckgGenConfig] UNIQUE NONCLUSTERED ([Project] ASC, [Package] ASC) );
CREATE OR REPLACE FUNCTION fetchq_test.queue_status_01( OUT passed BOOLEAN ) AS $$ DECLARE VAR_testName VARCHAR = 'IT SHOULD RETRIEVE QUEUES STATUS'; VAR_numQueues INTEGER; VAR_r RECORD; BEGIN -- initialize test -- create & drop the queue PERFORM fetchq.queue_create('foo'); PERFORM fetchq.queue_create('faa'); SELECT COUNT(*) INTO VAR_numQueues FROM fetchq.queue_status(); IF VAR_numQueues != 2 THEN RAISE EXCEPTION 'failed - %(count, got %)', VAR_testName, VAR_numQueues; END IF; SELECT COUNT(*) INTO VAR_numQueues FROM fetchq.queue_status('foo'); IF VAR_numQueues != 1 THEN RAISE EXCEPTION 'failed - %(count, got %)', VAR_testName, VAR_numQueues; END IF; SELECT * INTO VAR_r FROM fetchq.queue_status('foo'); IF VAR_r.is_active IS NOT TRUE THEN RAISE EXCEPTION 'failed - %(is_active, got %)', VAR_testName, VAR_r.is_active; END IF; passed = TRUE; END; $$ LANGUAGE plpgsql;
SELECT DISTINCT PDT.PRIMARY_DS_TYPE_ID, PDT.PRIMARY_DS_TYPE AS DATA_TYPE FROM {{.Owner}}.PRIMARY_DS_TYPES PDT
CREATE TABLE PPCS.EST_PROMEDIO ( MODULO_MINUTOS NUMBER(3) NOT NULL, EVENTMISCELLANEOUS NUMBER(10) DEFAULT '0' NOT NULL, MSORIGINATING NUMBER(10) DEFAULT '0' NOT NULL, CALLFORWARDING NUMBER(10) DEFAULT '0' NOT NULL, MSTERMINATINGINROAMING NUMBER(10) DEFAULT '0' NOT NULL, MSORIGROAMP NUMBER(10) DEFAULT '0' NOT NULL, MSORIGROAML NUMBER(10) DEFAULT '0' NOT NULL, CALL_SMS_USSD_ENQUIRYCREDIT NUMBER(10) DEFAULT '0' NOT NULL, MSORIGINATINGSMS NUMBER(10) DEFAULT '0' NOT NULL, MSORIGINATINGINROAMING NUMBER(10) DEFAULT '0' NOT NULL, CALLFORWARDINGINROAMING NUMBER(10) DEFAULT '0' NOT NULL, MSTERMINATING NUMBER(10) DEFAULT '0' NOT NULL, MSORIGINATINGMSGUNITS NUMBER(10) DEFAULT '0' NOT NULL, MSTERMINATINGMSGUNITS NUMBER(10) DEFAULT '0' NOT NULL, CONTENTCHARGING NUMBER(10) DEFAULT '0' NOT NULL, SESSIONDIAMETER NUMBER(10) DEFAULT '0' NOT NULL, NOBALANCECALLME NUMBER(10) DEFAULT '0' NOT NULL, ENDBILLINGCYCLE NUMBER(10) DEFAULT '0' NOT NULL, PROMOTIONEVENTMODULE NUMBER(10) DEFAULT '0' NOT NULL ) PCTFREE 1 PCTUSED 90 INITRANS 10 TABLESPACE EST_4096K_DAT STORAGE (INITIAL 1M NEXT 1M FREELISTS 10 FREELIST GROUPS 1); / COMMENT ON COLUMN PPCS.EST_PROMEDIO.MODULO_MINUTOS IS 'Grupo de 5 minutos en los que se crea la estadistica'; COMMENT ON COLUMN PPCS.EST_PROMEDIO.EVENTMISCELLANEOUS IS 'CDR que registra los eventos del SG'; COMMENT ON COLUMN PPCS.EST_PROMEDIO.MSORIGINATING IS 'LLamada en el pais Origen del abonado'; COMMENT ON COLUMN PPCS.EST_PROMEDIO.CALLFORWARDING IS 'Llamada desviada aun numero que no es gratuito'; COMMENT ON COLUMN PPCS.EST_PROMEDIO.MSTERMINATINGINROAMING IS 'Llamadas recibidas en Roaming'; COMMENT ON COLUMN PPCS.EST_PROMEDIO.MSORIGROAMP IS 'Trafico Roaming CPSA tramo originado'; COMMENT ON COLUMN PPCS.EST_PROMEDIO.MSORIGROAML IS 'Trafico Roaming CPSA tramo originante'; COMMENT ON COLUMN PPCS.EST_PROMEDIO.CALL_SMS_USSD_ENQUIRYCREDIT IS 'Eventos de Consulta de Saldo'; COMMENT ON COLUMN PPCS.EST_PROMEDIO.MSORIGINATINGSMS IS 'SMS en el pais Origen del abonado'; COMMENT ON COLUMN PPCS.EST_PROMEDIO.MSORIGINATINGINROAMING IS 'Llamada originada en Roaming'; COMMENT ON COLUMN PPCS.EST_PROMEDIO.CALLFORWARDINGINROAMING IS 'Desvio de llamada en Roaming'; COMMENT ON COLUMN PPCS.EST_PROMEDIO.MSTERMINATING IS 'Llamada recibida de tu propia red HPLMS'; COMMENT ON COLUMN PPCS.EST_PROMEDIO.MSORIGINATINGMSGUNITS IS 'Duracion de la llamada en segundos'; COMMENT ON COLUMN PPCS.EST_PROMEDIO.MSTERMINATINGMSGUNITS IS 'Coste de la llamada en euros.'; COMMENT ON COLUMN PPCS.EST_PROMEDIO.CONTENTCHARGING IS 'Eventos de Tarificacion de Contenidos'; COMMENT ON COLUMN PPCS.EST_PROMEDIO.SESSIONDIAMETER IS 'Eventos de Tarificacion de Datos'; COMMENT ON COLUMN PPCS.EST_PROMEDIO.NOBALANCECALLME IS 'Llamadas Realizadas sin Saldo y generan mensaje de Llamame'; COMMENT ON COLUMN PPCS.EST_PROMEDIO.ENDBILLINGCYCLE IS 'Fin de ciclo de facturacion con resumen del mismo'; COMMENT ON COLUMN PPCS.EST_PROMEDIO.PROMOTIONEVENTMODULE IS 'Eventos de Tarificacion sin coste asociados a una Promocion'; CREATE UNIQUE INDEX PPCS.PK_EST_PROMEDIO ON PPCS.EST_PROMEDIO ( MODULO_MINUTOS ASC ) PCTFREE 1 INITRANS 11 TABLESPACE EST_4096K_IND STORAGE ( PCTINCREASE 0 FREELISTS 10 FREELIST GROUPS 1 ); / GRANT INSERT, UPDATE, DELETE ON PPCS.EST_PROMEDIO TO PPCS_IUD; / GRANT SELECT ON PPCS.EST_PROMEDIO TO PPCS_SEL; / CREATE SYNONYM CPPCS.EST_PROMEDIO FOR PPCS.EST_PROMEDIO; / CREATE SYNONYM EPPCS.EST_PROMEDIO FOR PPCS.EST_PROMEDIO; / CREATE OR REPLACE PROCEDURE PPCS.SP_ESTADISTICA_CALCULO_P is cursor c1 is select modulo_minutos, round(avg(col1),2) res1,round(avg(col2),2) res2,round(avg(col3),2) res3,round(avg(col4),2) res4,round(avg(col5),2) res5, round(avg(col6),2) res6,round(avg(col7),2) res7,round(avg(col8),2) res8,round(avg(col9),2) res9,round(avg(col10),2) res10, round(avg(col11),2) res11,round(avg(col12),2) res12,round(avg(col13),2) res13,round(avg(col14),2) res14,round(avg(col15),2) res15, round(avg(col16),2) res16,round(avg(col17),2) res17,round(avg(col18),2) res18 from (select modulo_minutos,trunc(fecha_escritura), sum(nvl(EVENTMISCELLANEOUS,0)) col1, sum(nvl(MSORIGINATING,0)) col2, sum(nvl(CALLFORWARDING,0)) col3, sum(nvl(MSTERMINATINGINROAMING,0)) col4, sum(nvl(MSORIGROAMP,0)) col5, sum(nvl(MSORIGROAML,0)) col6, sum(nvl(CALL_SMS_USSD_ENQUIRYCREDIT,0)) col7, sum(nvl(MSORIGINATINGSMS,0)) col8, sum(nvl(MSORIGINATINGINROAMING,0)) col9, sum(nvl(CALLFORWARDINGINROAMING,0)) col10, sum(nvl(MSTERMINATING,0)) col11, sum(nvl(MSORIGINATINGMSGUNITS,0)) col12, sum(nvl(MSTERMINATINGMSGUNITS,0)) col13, sum(nvl(CONTENTCHARGING,0)) col14, sum(nvl(SESSIONDIAMETER,0)) col15, sum(nvl(NOBALANCECALLME,0)) col16, sum(nvl(ENDBILLINGCYCLE,0)) col17, sum(nvl(PROMOTIONEVENTMODULE,0)) col18 from ppcs.estadisticas where trunc(FECHA_ESCRITURA) > add_months(sysdate,-3) and to_number(to_char(fecha_escritura,'D'))= to_number(to_char(sysdate,'D')) and trunc(fecha_escritura) <> trunc(sysdate) group by modulo_minutos,trunc(fecha_escritura)) group by modulo_minutos; BEGIN -- limpio la tabla delete PPCS.EST_PROMEDIO; commit; --- inserta el total de registros en la tabla diaria for carga in c1 loop insert into ppcs.est_promedio(modulo_minutos, EVENTMISCELLANEOUS,MSORIGINATING,CALLFORWARDING,MSTERMINATINGINROAMING,MSORIGROAMP, MSORIGROAML,CALL_SMS_USSD_ENQUIRYCREDIT,MSORIGINATINGSMS,MSORIGINATINGINROAMING,CALLFORWARDINGINROAMING, MSTERMINATING,MSORIGINATINGMSGUNITS,MSTERMINATINGMSGUNITS,CONTENTCHARGING,SESSIONDIAMETER, NOBALANCECALLME,ENDBILLINGCYCLE,PROMOTIONEVENTMODULE) values (carga.modulo_minutos, carga.res1,carga.res2,carga.res3,carga.res4,carga.res5, carga.res6,carga.res7,carga.res8,carga.res9,carga.res10, carga.res11,carga.res12,carga.res13,carga.res14,carga.res15, carga.res16,carga.res17,carga.res18); end loop; commit; END; / -----job ------------ declare x number; BEGIN SYS.DBMS_JOB.SUBMIT ( job => X ,what => 'BEGIN PPCS.SP_ESTADISTICA_CALCULO_P; END;' ,next_date => trunc(sysdate+1)+1/288 ,interval => 'trunc(SYSDATE)+1' ,no_parse => FALSE ); SYS.DBMS_OUTPUT.PUT_LINE('Job Number is: ' || to_char(x)); COMMIT; END; / --final select modulo_minutos,sum(nvl(EVENTMISCELLANEOUS,0)) from ppcs.estadisticas where trunc(FECHA_ESCRITURA) > add_months(sydate,-1) and to_number(to_char(fecha_escritura,'D'))= to_number(to_char(sysdate,'D')) and trunc(fecha_escritura) <> trunc(sysdate) group by modulo_minutos; --- pruebas select modulo_minutos,sum(nvl(SESSIONDIAMETER,0)),count(1) from ppcs.estadisticas where trunc(FECHA_ESCRITURA) > add_months(sysdate,-3) and to_number(to_char(fecha_escritura,'D'))= to_number(to_char(sysdate,'D')) and trunc(fecha_escritura) <> trunc(sysdate) group by modulo_minutos order by 1; select modulo_minutos,sum(nvl(SESSIONDIAMETER,0))/12,count(1) from ppcs.estadisticas where trunc(FECHA_ESCRITURA) > add_months(sysdate,-3) and to_number(to_char(fecha_escritura,'D'))= to_number(to_char(sysdate,'D')) and trunc(fecha_escritura) <> trunc(sysdate) group by modulo_minutos order by 1; select modulo_minutos,round(avg(total),2) from (select modulo_minutos,trunc(fecha_escritura),sum(nvl(SESSIONDIAMETER,0)) total from ppcs.estadisticas where trunc(FECHA_ESCRITURA) > add_months(sysdate,-3) and to_number(to_char(fecha_escritura,'D'))= to_number(to_char(sysdate,'D')) and trunc(fecha_escritura) <> trunc(sysdate) group by modulo_minutos,trunc(fecha_escritura)) group by modulo_minutos order by 1; select modulo_minutos,round(stddev(total),2) from (select modulo_minutos,trunc(fecha_escritura),sum(nvl(SESSIONDIAMETER,0)) total from ppcs.estadisticas where trunc(FECHA_ESCRITURA) > add_months(sysdate,-3) and to_number(to_char(fecha_escritura,'D'))= to_number(to_char(sysdate,'D')) and trunc(fecha_escritura) <> trunc(sysdate) group by modulo_minutos,trunc(fecha_escritura)) group by modulo_minutos order by 1; select modulo_minutos,round(stddev_pop(total),2) from (select modulo_minutos,trunc(fecha_escritura),sum(nvl(SESSIONDIAMETER,0)) total from ppcs.estadisticas where trunc(FECHA_ESCRITURA) > add_months(sysdate,-3) and to_number(to_char(fecha_escritura,'D'))= to_number(to_char(sysdate,'D')) and trunc(fecha_escritura) <> trunc(sysdate) group by modulo_minutos,trunc(fecha_escritura)) group by modulo_minutos order by 1; select modulo_minutos,round(stddev_samp(total),2) from (select modulo_minutos,trunc(fecha_escritura),sum(nvl(SESSIONDIAMETER,0)) total from ppcs.estadisticas where trunc(FECHA_ESCRITURA) > add_months(sysdate,-3) and to_number(to_char(fecha_escritura,'D'))= to_number(to_char(sysdate,'D')) and trunc(fecha_escritura) <> trunc(sysdate) group by modulo_minutos,trunc(fecha_escritura)) group by modulo_minutos order by 1; select modulo_minutos,sum(nvl(SESSIONDIAMETER,0)),count(1) from ppcs.estadisticas where trunc(fecha_escritura) = trunc(sysdate) group by modulo_minutos order by 1; select modulo_minutos,sum(nvl(SESSIONDIAMETER,0)),count(1) from ppcs.estadisticas where trunc(fecha_escritura) = to_date('19082013','DDMMYYYY') group by modulo_minutos order by 1; hobb!t78 ssh crppcs@10.225.216.9 Temporal ssh oracle@mcammtybesg10 oracle export ORACLE_SID=DPPCSCR export ORACLE_SID=F2PPCSCR insert into ppcs.ppcs_llamadas (MSISDN, FEH_LLAMADA, CID, FEH_INSERCION, TIP_LLAMADA, TIP_PREPAGO, TON_ORIGEN, NPI_ORIGEN, TLF_ORIGEN, TON_DESTINO, NPI_DESTINO, TLF_DESTINO, DURACION , COSTE , GSM_SERVICIO, SDP_ID, MISMA_TRIBU, LISTAS_BN, ZONAS_TARIF,LISTA_DESTINO, MAS_INFO, IMP_CREDITO, IMP_CONSUMO, SEC_ARCHIVO) select MSISDN, FEH_LLAMADA+3, CID, FEH_INSERCION+3, TIP_LLAMADA, TIP_PREPAGO, TON_ORIGEN, NPI_ORIGEN, TLF_ORIGEN, TON_DESTINO, NPI_DESTINO, TLF_DESTINO, DURACION , COSTE , GSM_SERVICIO, SDP_ID, MISMA_TRIBU, LISTAS_BN, ZONAS_TARIF,LISTA_DESTINO, MAS_INFO, IMP_CREDITO, IMP_CONSUMO, SEC_ARCHIVO from ppcs.ppcs_llamadas where rownum < 2; INSERT into ppcs.estadisticas (FECHA_ESCRITURA,MODULO_MINUTOS,PID,MSOriginating,MSOriginating_co) values (sysdate, trunc(mod(sysdate-trunc(sysdate),1)*288),SYS_CONTEXT('userenv','sessionid'),1,100); @gnitiooracle78 scp p10404530_112030_Linux-x86-64_1of7.zip oracle@fe1:backup scp p10404530_112030_Linux-x86-64_2of7.zip oracle@fe1:backup scp p10404530_112030_Linux-x86-64_3of7.zip oracle@fe1:backup scp p10404530_112030_Linux-x86-64_4of7.zip oracle@fe1:backup scp p10404530_112030_Linux-x86-64_5of7.zip oracle@fe1:backup scp p10404530_112030_Linux-x86-64_6of7.zip oracle@fe1:backup scp p10404530_112030_Linux-x86-64_7of7.zip oracle@fe1:backup rm -f p10404530_112030_Linux-x86-64_1of7.zip rm -f p10404530_112030_Linux-x86-64_2of7.zip rm -f p10404530_112030_Linux-x86-64_3of7.zip rm -f p10404530_112030_Linux-x86-64_4of7.zip rm -f p10404530_112030_Linux-x86-64_5of7.zip rm -f p10404530_112030_Linux-x86-64_6of7.zip rm -f p10404530_112030_Linux-x86-64_7of7.zip
<reponame>dshilja/CC-projekt CREATE USER 'root' IDENTIFIED BY '<PASSWORD>'; GRANT ALL PRIVILEGES ON onlinestore.* TO 'root'; CALL mysql.az_load_timezone(); SELECT name FROM mysql.time_zone_name;
ALTER TABLE IDN_OAUTH2_ACCESS_TOKEN MODIFY COLUMN TIME_CREATED TIMESTAMP;
drop sequence if exists measurement_id_seq; create sequence measurement_id_seq start with 1; insert into measurement ( measurement_id, person_id, measurement_concept_id, measurement_date, measurement_datetime, measurement_time, measurement_type_concept_id, operator_concept_id, value_as_number, value_as_concept_id, unit_concept_id, range_low, range_high, provider_id, visit_occurrence_id, visit_detail_id, measurement_source_value, measurement_source_concept_id, unit_source_value, value_source_value ) select nextval('measurement_id_seq'), p.person_id, srctostdvm.target_concept_id, pr.date, pr.date, pr.date, 5001, 0, cast(null as float), 0, 0, cast(null as float), cast(null as float), 0, (select fv.visit_occurrence_id_new from final_visit_ids fv where fv.encounter_id = pr.encounter) visit_occurrence_id, 0, pr.code, ( select srctosrcvm.source_concept_id from source_to_source_vocab_map srctosrcvm where srctosrcvm.source_code = pr.code and srctosrcvm.source_vocabulary_id = 'SNOMED' ), cast(null as varchar), cast(null as varchar) from native.procedures pr join source_to_standard_vocab_map srctostdvm on srctostdvm.source_code = pr.code and srctostdvm.target_domain_id = 'Measurement' and srctostdvm.target_vocabulary_id = 'SNOMED' and srctostdvm.target_standard_concept = 'S' and srctostdvm.target_invalid_reason IS NULL join person p on p.person_source_value = pr.patient union all select nextval('measurement_id_seq'), p.person_id, srctostdvm.target_concept_id, o.date, o.date, o.date, 5001, 0, cast(null as float), 0, 0, cast(null as float), cast(null as float), 0, (select fv.visit_occurrence_id_new from final_visit_ids fv where fv.encounter_id = o.encounter) visit_occurrence_id, 0, o.code, ( select srctosrcvm.source_concept_id from source_to_source_vocab_map srctosrcvm where srctosrcvm.source_code = o.code and srctosrcvm.source_vocabulary_id = 'LOINC' ), cast(null as varchar), cast(null as varchar) from native.observations o join source_to_standard_vocab_map srctostdvm on srctostdvm.source_code = o.code and srctostdvm.target_domain_id = 'Measurement' and srctostdvm.target_vocabulary_id = 'LOINC' and srctostdvm.target_standard_concept = 'S' and srctostdvm.target_invalid_reason IS NULL join person p on p.person_source_value = o.patient;
USE gdelt_db; SELECT Actor1CountryCode, avg(AvgTone) FROM gdelt_table group by Actor1CountryCode ;
<gh_stars>10-100 --name: select-user -- get user by id SELECT id, first_name, last_name, country, language, profile_visibility, profile_picture, role, about, email_notifications, activated FROM user WHERE id = :id AND deleted = 0 --name: select-user-profile-fields -- get all user's profile fields SELECT id, field, value, field_order FROM user_profile WHERE user_id = :user_id ORDER BY field_order --name: select-user-profile-fields-multi -- get all user's profile fields SELECT id, field, value, field_order FROM user_profile WHERE id IN (:field_ids) AND user_id = :user_id --name: delete-user-profile-fields! DELETE FROM user_profile WHERE user_id = :user_id --name: delete-user-profile-fields-multi! DELETE FROM user_profile WHERE user_id = :user_id AND id IN (:field_ids) --name: insert-user-profile-field! INSERT INTO user_profile (user_id, field, value, field_order) VALUES (:user_id, :field, :value, :field_order) --name: update-user-visibility-picture-about! UPDATE user SET profile_visibility = :profile_visibility, profile_picture = :profile_picture, about = :about, mtime = UNIX_TIMESTAMP() WHERE id = :id --name: insert-user-profile-properties! REPLACE INTO user_properties (user_id, name, value) VALUES (:user_id, 'profile', :value) --name: select-user-profile-properties SELECT value from user_properties where user_id = :user_id and name = 'profile' --name: delete-user-profile-properties! DELETE FROM user_properties WHERE user_id = :user_id AND name = 'profile' --name: delete-showcase-badges! DELETE FROM user_profile_badge_showcase_has_badge WHERE block_id = :block_id --name: delete-showcase-badges-multi!-REMOVE DELETE FROM user_profile_badge_showcase_has_badge AS t JOIN user_profile_badge_showcase AS t2 ON t.block_id = t2.id WHERE t.block_id IN (:block_ids) AND t2.user_id = :user_id --name: delete-showcase-block! DELETE FROM user_profile_badge_showcase WHERE id = :id --name: delete-showcase-block-multi! DELETE user_profile_badge_showcase, user_profile_badge_showcase_has_badge FROM user_profile_badge_showcase INNER JOIN user_profile_badge_showcase_has_badge ON user_profile_badge_showcase.id = user_profile_badge_showcase_has_badge.block_id WHERE user_profile_badge_showcase.id IN (:block_ids) AND user_profile_badge_showcase.user_id = :user_id; --name: delete-showcase-blocks! DELETE FROM user_profile_badge_showcase WHERE user_id = :user_id --name: insert-showcase-block<! INSERT INTO user_profile_badge_showcase (user_id, title, format, block_order) VALUES (:user_id, :title, :format, :block_order) --name: update-badge-showcase-block! UPDATE user_profile_badge_showcase SET title = :title, format = :format, block_order = :block_order WHERE id = :id AND user_id = :user_id --name: insert-showcase-badges! INSERT INTO user_profile_badge_showcase_has_badge (block_id, badge_id, badge_order) VALUES (:block_id, :badge_id, :badge_order) --name: select-badge-showcase-blocks SELECT id, 'showcase' AS type, title, format, block_order FROM user_profile_badge_showcase WHERE user_id = :user_id --name: select-showcase-block-content -- get badges in badge showcase SELECT DISTINCT ub.id, bc.name, bc.image_file FROM user_badge AS ub JOIN user_profile_badge_showcase_has_badge AS pb ON pb.badge_id = ub.id JOIN badge AS badge ON (badge.id = ub.badge_id) JOIN badge_badge_content AS bbc ON (bbc.badge_id = badge.id) JOIN badge_content AS bc ON (bc.id = bbc.badge_content_id) AND bc.language_code = badge.default_language_code WHERE pb.block_id = :block_id AND ub.revoked = 0 AND ub.deleted = 0 ORDER BY pb.badge_order --name: select-page --get profile page tab SELECT id, name, visibility FROM page WHERE id = :id AND deleted != 1; --name: select-page-multi SELECT id, name, visibility, user_id FROM page WHERE id IN (:tabs) AND deleted != 1 AND user_id = :user_id; --name: select-badge-multi SELECT id, visibility FROM user_badge WHERE id IN (:ids) AND deleted = 0 AND revoked = 0;
<gh_stars>100-1000 CREATE TABLE t8 (s varchar(10) character set latin1 collate "en_GB" not null)
<reponame>antontarasenko/gpq # Specifying "vendor name" to find out what other firms in your industry sell to the government # Data analytics vendors are used for example select agencyid, dollarsobligated, vendorname, descriptionofcontractrequirement from gpqueries:contracts.raw where vendorname contains 'tableau' or vendorname contains 'socrata' or vendorname contains 'palantir' or vendorname contains 'revolution analytics' or vendorname contains 'mathworks' or vendorname contains 'statacorp' or vendorname contains 'mathworks' order by dollarsobligated desc ignore case
<filename>embed/sql/generic/fqdn.sql DECLARE @Domain NVARCHAR(100) EXEC master.dbo.xp_regread 'HKEY_LOCAL_MACHINE', 'SYSTEM\CurrentControlSet\services\Tcpip\Parameters', N'Domain',@Domain OUTPUT SELECT Cast(SERVERPROPERTY('MachineName') as nvarchar) + '.' + @Domain AS FQDN
create table customers (first_name varchar(20), last_name varchar(20));
<reponame>h-t-tran/postgresEF -- -------------------------------------------------- -- Entity Designer DDL Script for SQL Server 2005, 2008, 2012 and Azure -- -------------------------------------------------- -- Date Created: 11/29/2014 01:15:57 -- Generated from EDMX file: C:\Users\hoanh\Google Drive\pluralsight\postgres-src\postgres.net\4-postgres-dotnet-developers-exercise-files\membership\testEFSqlServer2\Model1.edmx -- -------------------------------------------------- SET QUOTED_IDENTIFIER OFF; GO USE [vlab]; GO IF SCHEMA_ID(N'dbo') IS NULL EXECUTE(N'CREATE SCHEMA [dbo]'); GO -- -------------------------------------------------- -- Dropping existing FOREIGN KEY constraints -- -------------------------------------------------- -- -------------------------------------------------- -- Dropping existing tables -- -------------------------------------------------- IF OBJECT_ID(N'[dbo].[Employees]', 'U') IS NOT NULL DROP TABLE [dbo].[Employees]; GO IF OBJECT_ID(N'[dbo].[Metadatas]', 'U') IS NOT NULL DROP TABLE [dbo].[Metadatas]; GO -- -------------------------------------------------- -- Creating all tables -- -------------------------------------------------- -- Creating table 'Employees' CREATE TABLE [dbo].[Employees] ( [Id] int IDENTITY(1,1) NOT NULL, [Name] nvarchar(max) NOT NULL ); GO -- Creating table 'Metadatas' CREATE TABLE [dbo].[Metadatas] ( [Id] int IDENTITY(1,1) NOT NULL, [Age] int NOT NULL, [Hobby] nvarchar(max) NOT NULL, [When] datetime NULL ); GO -- -------------------------------------------------- -- Creating all PRIMARY KEY constraints -- -------------------------------------------------- -- Creating primary key on [Id] in table 'Employees' ALTER TABLE [dbo].[Employees] ADD CONSTRAINT [PK_Employees] PRIMARY KEY CLUSTERED ([Id] ASC); GO -- Creating primary key on [Id] in table 'Metadatas' ALTER TABLE [dbo].[Metadatas] ADD CONSTRAINT [PK_Metadatas] PRIMARY KEY CLUSTERED ([Id] ASC); GO -- -------------------------------------------------- -- Creating all FOREIGN KEY constraints -- -------------------------------------------------- -- -------------------------------------------------- -- Script has ended -- --------------------------------------------------
<filename>openGaussBase/testcase/SQL/DQL/Opengauss_Function_DQL_select_Case0011.sql -- @testpoint: DQL语法,结合order by后跟clob列 drop table if exists test_clob; create table test_clob(id int,c_clob clob); insert into test_clob values(1,'abcdeee'); insert into test_clob values(2,'abcd'); insert into test_clob values(3,'abc'); insert into test_clob values(4,'bcdefg'); insert into test_clob values(5,'中国abc'); insert into test_clob values(6,'abc中国'); select * from test_clob where c_clob like 'abc%' order by c_clob; drop table test_clob;
-- @testpoint:opengauss关键字parameter_ordinal_position(非保留),作为表空间名 --关键字不带引号,创建成功 drop tablespace if exists parameter_ordinal_position; CREATE TABLESPACE parameter_ordinal_position RELATIVE LOCATION 'hdfs_tablespace/hdfs_tablespace_1'; drop tablespace parameter_ordinal_position; --关键字带双引号,创建成功 drop tablespace if exists "parameter_ordinal_position"; CREATE TABLESPACE "parameter_ordinal_position" RELATIVE LOCATION 'hdfs_tablespace/hdfs_tablespace_1'; drop tablespace "parameter_ordinal_position"; --关键字带单引号,合理报错 drop tablespace if exists 'parameter_ordinal_position'; CREATE TABLESPACE 'parameter_ordinal_position' RELATIVE LOCATION 'hdfs_tablespace/hdfs_tablespace_1'; --关键字带反引号,合理报错 drop tablespace if exists `parameter_ordinal_position`; CREATE TABLESPACE `parameter_ordinal_position` RELATIVE LOCATION 'hdfs_tablespace/hdfs_tablespace_1';
update config set value='20.04.2' where param='version';
<gh_stars>0 declare @tmptable table (firstname varchar(50), lastname varchar(50), title varchar(200)) declare @cursor cursor declare @spid int, @pid int, @firstname varchar(50), @lastname varchar(50), @title varchar(200), @year int declare @contactid int = 0 set @cursor = cursor for select sp.id spid, sp.personid, firstname, lastname, s.[year] from seminarpeople sp inner join people p on sp.personid = p.id inner join seminars s on sp.seminarid = s.id open @cursor fetch next from @cursor into @spid, @pid, @firstname, @lastname, @year while(@@FETCH_STATUS = 0) begin print @spid print @pid print @firstname print @lastname print @year -- search for the title select @contactid = c_id from agribusinessarchive.dbo.seminars s inner join agribusinessarchive.dbo.contacts c on s.contactid = c.c_id where c.firstname = @firstname and c.lastname = @lastname and s.[year] = @year -- contact was found if (@contactid > 0) begin select @title = title from agribusinessarchive.dbo.contactfirms cf where cf.contactid = @contactid if (@title <> '') begin insert into @tmptable values (@firstname, @lastname, @title) end end fetch next from @cursor into @spid, @pid, @firstname, @lastname, @year set @contactid = 0 set @title = '' end close @cursor deallocate @cursor select * from @tmptable
INSERT INTO child(pid, name) SELECT id,name,name FROM parent
<reponame>clima-dev/builderhacks<filename>prisma/migrations/20220226113428_/migration.sql -- AlterTable ALTER TABLE "Modpack" ALTER COLUMN "downloadCount" SET DEFAULT 0;
INSERT INTO Genres(GenreName,Notes) VALUES ('Action','American the best action'), ('Drama','Story family'), ('Horror','Villains and monsters'), ('Science','The greatest disoveries'), ('Comedy','Funy films')
<filename>apex/f120/application/pages/page_00006.sql prompt --application/pages/page_00006 begin wwv_flow_api.create_page( p_id=>6 ,p_user_interface_id=>wwv_flow_api.id(40708662826080105) ,p_name=>'Test Details' ,p_page_mode=>'MODAL' ,p_step_title=>'Test Details' ,p_warn_on_unsaved_changes=>'N' ,p_autocomplete_on_off=>'OFF' ,p_page_template_options=>'#DEFAULT#' ,p_required_role=>wwv_flow_api.id(40711335611080246) ,p_dialog_height=>'600' ,p_dialog_width=>'800' ,p_dialog_chained=>'N' ,p_last_updated_by=>'MBECKER' ,p_last_upd_yyyymmddhh24miss=>'20191120180904' ); wwv_flow_api.create_page_plug( p_id=>wwv_flow_api.id(71760052639811733) ,p_plug_name=>'Test Suite Results' ,p_region_template_options=>'#DEFAULT#' ,p_component_template_options=>'#DEFAULT#' ,p_plug_template=>wwv_flow_api.id(40633550797079838) ,p_plug_display_sequence=>30 ,p_plug_display_point=>'BODY' ,p_query_type=>'SQL' ,p_plug_source=>wwv_flow_string.join(wwv_flow_t_varchar2( 'select testcase_name "Testcase Name",', ' nvl(test_status,''Success'') test_status,', ' case when test_status in ( ''Error'') then ''red''', ' when test_status in (''Failure'') then ''orange'' else ''green'' ', ' end "STATUS_COLOR", ', ' duration_sec "Test Duration", ', ' case when error_statement is null ', ' then nvl(Failure_statement,''Test was successful'')', ' else error_statement ', ' end "Error or Failure Info",', ' System_err "System Error", ', ' System_out "system Output",', ' testcase_path', 'from UTA_TEST_CASE ', 'where UTA_TEST_SUITE_ID ', ' in (select id from uta_test_suite where uta_test_run_id = :P6_TEST_RUN_ID and package_path like :P6_PKGPATH||''%'')', '', '')) ,p_plug_source_type=>'NATIVE_IR' ,p_plug_query_options=>'DERIVED_REPORT_COLUMNS' ,p_plug_display_condition_type=>'VAL_OF_ITEM_IN_COND_EQ_COND2' ,p_plug_display_when_condition=>'P6_HIDE' ,p_plug_display_when_cond2=>'1' ,p_prn_content_disposition=>'ATTACHMENT' ,p_prn_document_header=>'APEX' ,p_prn_units=>'INCHES' ,p_prn_paper_size=>'LETTER' ,p_prn_width=>11 ,p_prn_height=>8.5 ,p_prn_orientation=>'HORIZONTAL' ,p_prn_page_header_font_color=>'#000000' ,p_prn_page_header_font_family=>'Helvetica' ,p_prn_page_header_font_weight=>'normal' ,p_prn_page_header_font_size=>'12' ,p_prn_page_footer_font_color=>'#000000' ,p_prn_page_footer_font_family=>'Helvetica' ,p_prn_page_footer_font_weight=>'normal' ,p_prn_page_footer_font_size=>'12' ,p_prn_header_bg_color=>'#9bafde' ,p_prn_header_font_color=>'#000000' ,p_prn_header_font_family=>'Helvetica' ,p_prn_header_font_weight=>'normal' ,p_prn_header_font_size=>'10' ,p_prn_body_bg_color=>'#efefef' ,p_prn_body_font_color=>'#000000' ,p_prn_body_font_family=>'Helvetica' ,p_prn_body_font_weight=>'normal' ,p_prn_body_font_size=>'10' ,p_prn_border_width=>.5 ,p_prn_page_header_alignment=>'CENTER' ,p_prn_page_footer_alignment=>'CENTER' ); wwv_flow_api.create_worksheet( p_id=>wwv_flow_api.id(71950313511904787) ,p_max_row_count_message=>'The maximum row count for this report is #MAX_ROW_COUNT# rows. Please apply a filter to reduce the number of records in your query.' ,p_no_data_found_message=>'No data found.' ,p_allow_save_rpt_public=>'Y' ,p_show_nulls_as=>'-' ,p_pagination_type=>'ROWS_X_TO_Y' ,p_pagination_display_pos=>'BOTTOM_RIGHT' ,p_report_list_mode=>'TABS' ,p_show_detail_link=>'N' ,p_show_rows_per_page=>'N' ,p_show_highlight=>'N' ,p_show_computation=>'N' ,p_show_chart=>'N' ,p_show_group_by=>'N' ,p_show_notify=>'Y' ,p_show_flashback=>'N' ,p_download_formats=>'CSV:HTML:EMAIL:XLSX:PDF:RTF' ,p_owner=>'ADMIN' ,p_internal_uid=>71950313511904787 ); wwv_flow_api.create_worksheet_column( p_id=>wwv_flow_api.id(24750730379816582) ,p_db_column_name=>'Testcase Name' ,p_display_order=>10 ,p_column_identifier=>'R' ,p_column_label=>'Testcase Name' ,p_column_type=>'STRING' ); wwv_flow_api.create_worksheet_column( p_id=>wwv_flow_api.id(24749198675816581) ,p_db_column_name=>'Test Duration' ,p_display_order=>30 ,p_column_identifier=>'N' ,p_column_label=>'Test Duration' ,p_column_type=>'STRING' ); wwv_flow_api.create_worksheet_column( p_id=>wwv_flow_api.id(24749579420816581) ,p_db_column_name=>'Error or Failure Info' ,p_display_order=>40 ,p_column_identifier=>'O' ,p_column_label=>'Error Or Failure Info' ,p_column_type=>'STRING' ); wwv_flow_api.create_worksheet_column( p_id=>wwv_flow_api.id(24749968211816582) ,p_db_column_name=>'System Error' ,p_display_order=>50 ,p_column_identifier=>'P' ,p_column_label=>'System Error' ,p_column_type=>'STRING' ); wwv_flow_api.create_worksheet_column( p_id=>wwv_flow_api.id(24750360020816582) ,p_db_column_name=>'system Output' ,p_display_order=>60 ,p_column_identifier=>'Q' ,p_column_label=>'System Output' ,p_column_type=>'STRING' ); wwv_flow_api.create_worksheet_column( p_id=>wwv_flow_api.id(24751160844816582) ,p_db_column_name=>'TEST_STATUS' ,p_display_order=>90 ,p_column_identifier=>'V' ,p_column_label=>'Test Status' ,p_column_html_expression=>'<span style="color:#STATUS_COLOR#;font-weight:bold;">#TEST_STATUS#</span>' ,p_column_type=>'STRING' ); wwv_flow_api.create_worksheet_column( p_id=>wwv_flow_api.id(24751593328816583) ,p_db_column_name=>'STATUS_COLOR' ,p_display_order=>100 ,p_column_identifier=>'W' ,p_column_label=>'Status Color' ,p_column_type=>'STRING' ,p_display_text_as=>'HIDDEN' ); wwv_flow_api.create_worksheet_column( p_id=>wwv_flow_api.id(22299580037372038) ,p_db_column_name=>'TESTCASE_PATH' ,p_display_order=>110 ,p_column_identifier=>'X' ,p_column_label=>'Testcase Path' ,p_column_type=>'STRING' ); wwv_flow_api.create_worksheet_rpt( p_id=>wwv_flow_api.id(71962448917994648) ,p_application_user=>'APXWS_DEFAULT' ,p_report_seq=>10 ,p_report_alias=>'247519' ,p_status=>'PUBLIC' ,p_is_default=>'Y' ,p_report_columns=>'Testcase Name:TESTCASE_PATH:Error or Failure Info:TEST_STATUS:Test Duration:' ); wwv_flow_api.create_report_region( p_id=>wwv_flow_api.id(86176969781635495) ,p_name=>'Test Run Pkg Stats ' ,p_template=>wwv_flow_api.id(40634728512079847) ,p_display_sequence=>10 ,p_include_in_reg_disp_sel_yn=>'Y' ,p_region_template_options=>'#DEFAULT#:t-Region--noPadding:t-Region--removeHeader:t-Region--noBorder:t-Region--hiddenOverflow:t-Form--slimPadding:margin-top-none:margin-bottom-none:margin-left-none:margin-right-none' ,p_component_template_options=>'#DEFAULT#:u-colors:t-BadgeList--medium:t-BadgeList--circular:t-BadgeList--fixed' ,p_new_grid_row=>false ,p_display_point=>'BODY' ,p_source_type=>'NATIVE_SQL_REPORT' ,p_query_type=>'SQL' ,p_source=>wwv_flow_string.join(wwv_flow_t_varchar2( 'select testsuite_name ,uta_test_run_id, sum(TOTAL_TESTS) total, sum(FAILED_TESTS) FAILED, sum (to_number(TOTAL_TESTS)-( to_number(FAILED_TESTS)+to_number(ERRORED_TESTS)) )', ' SUCCESSED, sum(ERRORED_TESTS) ERRORED', ' from uta_test_suite where package_path =:P6_PKGPATH and uta_test_run_id = :P6_TEST_RUN_ID group by uta_test_run_id, testsuite_name', ' ')) ,p_ajax_enabled=>'Y' ,p_ajax_items_to_submit=>'P6_ID' ,p_query_row_template=>wwv_flow_api.id(40653553171079896) ,p_query_num_rows=>15 ,p_query_options=>'DERIVED_REPORT_COLUMNS' ,p_query_show_nulls_as=>'-' ,p_query_num_rows_type=>'NEXT_PREVIOUS_LINKS' ,p_pagination_display_position=>'BOTTOM_RIGHT' ,p_csv_output=>'N' ,p_prn_output=>'N' ,p_sort_null=>'L' ,p_plug_query_strip_html=>'N' ); wwv_flow_api.create_report_columns( p_id=>wwv_flow_api.id(24752698065816593) ,p_query_column_id=>1 ,p_column_alias=>'TESTSUITE_NAME' ,p_column_display_sequence=>5 ,p_hidden_column=>'Y' ,p_derived_column=>'N' ); wwv_flow_api.create_report_columns( p_id=>wwv_flow_api.id(24753025624816594) ,p_query_column_id=>2 ,p_column_alias=>'UTA_TEST_RUN_ID' ,p_column_display_sequence=>6 ,p_hidden_column=>'Y' ,p_derived_column=>'N' ); wwv_flow_api.create_report_columns( p_id=>wwv_flow_api.id(24753461287816594) ,p_query_column_id=>3 ,p_column_alias=>'TOTAL' ,p_column_display_sequence=>1 ,p_column_heading=>'Total Testcases' ,p_use_as_row_header=>'N' ,p_column_html_expression=>'<div style="background-color:darkblue; ">#TOTAL#' ,p_derived_column=>'N' ,p_include_in_export=>'Y' ); wwv_flow_api.create_report_columns( p_id=>wwv_flow_api.id(24753868090816594) ,p_query_column_id=>4 ,p_column_alias=>'FAILED' ,p_column_display_sequence=>3 ,p_column_heading=>'Fail' ,p_use_as_row_header=>'N' ,p_column_html_expression=>'<div style="background-color:#FF8000; ">#FAILED#' ,p_derived_column=>'N' ,p_include_in_export=>'Y' ); wwv_flow_api.create_report_columns( p_id=>wwv_flow_api.id(24754256160816595) ,p_query_column_id=>5 ,p_column_alias=>'SUCCESSED' ,p_column_display_sequence=>2 ,p_column_heading=>'Success' ,p_use_as_row_header=>'N' ,p_column_html_expression=>'<div style="background-color:#088A4B; ">#SUCCESSED#' ,p_derived_column=>'N' ,p_include_in_export=>'Y' ); wwv_flow_api.create_report_columns( p_id=>wwv_flow_api.id(24754681333816595) ,p_query_column_id=>6 ,p_column_alias=>'ERRORED' ,p_column_display_sequence=>4 ,p_column_heading=>'Error' ,p_use_as_row_header=>'N' ,p_column_html_expression=>'<div style="background-color:#DF0101; ">#ERRORED#' ,p_derived_column=>'N' ,p_include_in_export=>'Y' ); wwv_flow_api.create_page_plug( p_id=>wwv_flow_api.id(90670221189118328) ,p_plug_name=>'Test Details ' ,p_region_template_options=>'#DEFAULT#' ,p_plug_template=>wwv_flow_api.id(40633550797079838) ,p_plug_display_sequence=>20 ,p_plug_display_point=>'BODY' ,p_query_type=>'SQL' ,p_plug_source=>wwv_flow_string.join(wwv_flow_t_varchar2( 'select id,testcase_path "Testcase Path",testcase_name,nvl(test_status,''Success'') status, ', 'case when test_status in ''Error'' then ''red'' ', ' when test_status in ''Failure'' then ''orange'' else ''green'' end "STATUS_COLOR",''Detail'' "Detail",', '''History'' "History" from UTA_TEST_CASE where UTA_TEST_SUITE_ID in (select id from uta_test_suite where uta_test_run_id = :P6_TEST_RUN_ID and package_path like :P6_PKGPATH||''%'')', '', '')) ,p_plug_source_type=>'NATIVE_IR' ,p_plug_query_options=>'DERIVED_REPORT_COLUMNS' ,p_plug_display_condition_type=>'VAL_OF_ITEM_IN_COND_NOT_EQ_COND2' ,p_plug_display_when_condition=>'P6_HIDE' ,p_plug_display_when_cond2=>'1' ); wwv_flow_api.create_worksheet( p_id=>wwv_flow_api.id(90670339914118328) ,p_name=>'Test Details' ,p_max_row_count_message=>'The maximum row count for this report is #MAX_ROW_COUNT# rows. Please apply a filter to reduce the number of records in your query.' ,p_no_data_found_message=>'No data found.' ,p_allow_save_rpt_public=>'Y' ,p_show_nulls_as=>'-' ,p_report_list_mode=>'TABS' ,p_show_detail_link=>'N' ,p_show_highlight=>'N' ,p_show_computation=>'N' ,p_show_chart=>'N' ,p_show_group_by=>'N' ,p_show_notify=>'Y' ,p_show_flashback=>'N' ,p_download_formats=>'CSV:HTML:EMAIL:XLSX:PDF:RTF' ,p_owner=>'TESTER' ,p_internal_uid=>90670339914118328 ); wwv_flow_api.create_worksheet_column( p_id=>wwv_flow_api.id(24757773856816598) ,p_db_column_name=>'TESTCASE_NAME' ,p_display_order=>30 ,p_column_identifier=>'O' ,p_column_label=>'Testcase ' ,p_allow_highlighting=>'N' ,p_allow_computations=>'N' ,p_allow_charting=>'N' ,p_allow_group_by=>'N' ,p_allow_pivot=>'N' ,p_allow_hide=>'N' ,p_column_type=>'STRING' ); wwv_flow_api.create_worksheet_column( p_id=>wwv_flow_api.id(24758110019816598) ,p_db_column_name=>'STATUS' ,p_display_order=>40 ,p_column_identifier=>'P' ,p_column_label=>'Status' ,p_column_html_expression=>'<span style="color:#STATUS_COLOR#;font-weight:bold;">#STATUS#</span>' ,p_allow_sorting=>'N' ,p_allow_aggregations=>'N' ,p_allow_computations=>'N' ,p_allow_charting=>'N' ,p_allow_group_by=>'N' ,p_allow_pivot=>'N' ,p_allow_hide=>'N' ,p_column_type=>'STRING' ); wwv_flow_api.create_worksheet_column( p_id=>wwv_flow_api.id(24758581027816599) ,p_db_column_name=>'ID' ,p_display_order=>70 ,p_column_identifier=>'S' ,p_column_label=>'Id' ,p_column_type=>'NUMBER' ,p_display_text_as=>'HIDDEN' ); wwv_flow_api.create_worksheet_column( p_id=>wwv_flow_api.id(24756151641816597) ,p_db_column_name=>'STATUS_COLOR' ,p_display_order=>80 ,p_column_identifier=>'U' ,p_column_label=>'Status Color' ,p_column_type=>'STRING' ,p_display_text_as=>'HIDDEN' ); wwv_flow_api.create_worksheet_column( p_id=>wwv_flow_api.id(24756536705816597) ,p_db_column_name=>'Testcase Path' ,p_display_order=>90 ,p_column_identifier=>'V' ,p_column_label=>'Testcase Path' ,p_column_type=>'STRING' ); wwv_flow_api.create_worksheet_column( p_id=>wwv_flow_api.id(24756974712816598) ,p_db_column_name=>'Detail' ,p_display_order=>100 ,p_column_identifier=>'W' ,p_column_label=>'<p style="color:#337ac0;" >Detail </p>' ,p_column_link=>'f?p=&APP_ID.:7:&SESSION.::&DEBUG.:RP,7:P7_ID:#ID#' ,p_column_linktext=>'<span aria-hidden="true" style="color:Blue" class="fa fa-binoculars"></span>' ,p_allow_sorting=>'N' ,p_allow_filtering=>'N' ,p_allow_highlighting=>'N' ,p_allow_ctrl_breaks=>'N' ,p_allow_aggregations=>'N' ,p_allow_computations=>'N' ,p_allow_charting=>'N' ,p_allow_group_by=>'N' ,p_allow_pivot=>'N' ,p_allow_hide=>'N' ,p_column_type=>'STRING' ); wwv_flow_api.create_worksheet_column( p_id=>wwv_flow_api.id(24757385500816598) ,p_db_column_name=>'History' ,p_display_order=>110 ,p_column_identifier=>'X' ,p_column_label=>'<p style="color:#337ac0;" > History </p>' ,p_column_link=>'f?p=&APP_ID.:16:&SESSION.::&DEBUG.:RP,16:P16_PKGNAME,P16_TESTCASE:#Testcase Path#,#TESTCASE_NAME#' ,p_column_linktext=>' <span class="fa fa-history" style="color:Blue"></span>' ,p_allow_sorting=>'N' ,p_allow_filtering=>'N' ,p_allow_highlighting=>'N' ,p_allow_ctrl_breaks=>'N' ,p_allow_aggregations=>'N' ,p_allow_computations=>'N' ,p_allow_charting=>'N' ,p_allow_group_by=>'N' ,p_allow_pivot=>'N' ,p_allow_hide=>'N' ,p_column_type=>'STRING' ); wwv_flow_api.create_worksheet_rpt( p_id=>wwv_flow_api.id(90683515695154184) ,p_application_user=>'APXWS_DEFAULT' ,p_report_seq=>10 ,p_report_alias=>'247589' ,p_status=>'PUBLIC' ,p_is_default=>'Y' ,p_report_columns=>'TESTCASE_NAME:Testcase Path:STATUS:Detail:History:' ,p_sort_column_1=>'Testcase Path' ,p_sort_direction_1=>'ASC' ,p_sort_column_2=>'TESTCASE_NAME' ,p_sort_direction_2=>'ASC' ,p_sort_column_3=>'0' ,p_sort_direction_3=>'ASC' ,p_sort_column_4=>'0' ,p_sort_direction_4=>'ASC' ,p_sort_column_5=>'0' ,p_sort_direction_5=>'ASC' ,p_sort_column_6=>'0' ,p_sort_direction_6=>'ASC' ); wwv_flow_api.create_page_button( p_id=>wwv_flow_api.id(22299161092372034) ,p_button_sequence=>10 ,p_button_plug_id=>wwv_flow_api.id(71760052639811733) ,p_button_name=>'SHOW_LESS' ,p_button_action=>'SUBMIT' ,p_button_template_options=>'#DEFAULT#:t-Button--iconRight' ,p_button_template_id=>wwv_flow_api.id(40686937944079977) ,p_button_is_hot=>'Y' ,p_button_image_alt=>'without Info' ,p_button_position=>'RIGHT_OF_IR_SEARCH_BAR' ,p_icon_css_classes=>'fa-binoculars' ); wwv_flow_api.create_page_button( p_id=>wwv_flow_api.id(24759382001816599) ,p_button_sequence=>10 ,p_button_plug_id=>wwv_flow_api.id(90670221189118328) ,p_button_name=>'SHOW_MORE' ,p_button_action=>'SUBMIT' ,p_button_template_options=>'#DEFAULT#:t-Button--iconRight' ,p_button_template_id=>wwv_flow_api.id(40686937944079977) ,p_button_is_hot=>'Y' ,p_button_image_alt=>'with Info' ,p_button_position=>'RIGHT_OF_IR_SEARCH_BAR' ,p_icon_css_classes=>'fa-binoculars' ); wwv_flow_api.create_page_item( p_id=>wwv_flow_api.id(24755029106816595) ,p_name=>'P6_PKGPATH' ,p_item_sequence=>10 ,p_item_plug_id=>wwv_flow_api.id(86176969781635495) ,p_use_cache_before_default=>'NO' ,p_prompt=>'New' ,p_source=>'P6_PKGPATH' ,p_source_type=>'ITEM' ,p_display_as=>'NATIVE_DISPLAY_ONLY' ,p_colspan=>9 ,p_grid_column=>3 ,p_field_template=>wwv_flow_api.id(40686215320079967) ,p_item_template_options=>'#DEFAULT#:margin-top-none:margin-bottom-none:margin-left-none:margin-right-none' ,p_attribute_01=>'Y' ,p_attribute_02=>'VALUE' ,p_attribute_04=>'Y' ); wwv_flow_api.create_page_item( p_id=>wwv_flow_api.id(24755448571816596) ,p_name=>'P6_TEST_RUN_ID' ,p_item_sequence=>20 ,p_item_plug_id=>wwv_flow_api.id(86176969781635495) ,p_display_as=>'NATIVE_HIDDEN' ,p_attribute_01=>'Y' ); wwv_flow_api.create_page_item( p_id=>wwv_flow_api.id(24759756392816600) ,p_name=>'P6_ID' ,p_item_sequence=>20 ,p_item_plug_id=>wwv_flow_api.id(90670221189118328) ,p_display_as=>'NATIVE_HIDDEN' ,p_attribute_01=>'N' ); wwv_flow_api.create_page_item( p_id=>wwv_flow_api.id(24760138425816600) ,p_name=>'P6_TESTCASE' ,p_item_sequence=>30 ,p_item_plug_id=>wwv_flow_api.id(90670221189118328) ,p_use_cache_before_default=>'NO' ,p_source=>'select testcase_name from UTA_TEST_CASE where UTA_TEST_SUITE_ID= :P6_ID' ,p_source_type=>'QUERY' ,p_display_as=>'NATIVE_HIDDEN' ,p_attribute_01=>'N' ); wwv_flow_api.create_page_item( p_id=>wwv_flow_api.id(24760534296816600) ,p_name=>'P6_PRCNAME' ,p_item_sequence=>40 ,p_item_plug_id=>wwv_flow_api.id(90670221189118328) ,p_use_cache_before_default=>'NO' ,p_display_as=>'NATIVE_HIDDEN' ,p_attribute_01=>'N' ); wwv_flow_api.create_page_item( p_id=>wwv_flow_api.id(24760983636816601) ,p_name=>'P6_HIDE' ,p_item_sequence=>50 ,p_item_plug_id=>wwv_flow_api.id(90670221189118328) ,p_display_as=>'NATIVE_HIDDEN' ,p_attribute_01=>'Y' ); wwv_flow_api.create_page_process( p_id=>wwv_flow_api.id(24761301534816605) ,p_process_sequence=>10 ,p_process_point=>'ON_SUBMIT_BEFORE_COMPUTATION' ,p_process_type=>'NATIVE_PLSQL' ,p_process_name=>'Show More' ,p_process_sql_clob=>':P6_HIDE :=1;' ,p_process_clob_language=>'PLSQL' ,p_error_display_location=>'INLINE_IN_NOTIFICATION' ,p_process_when_button_id=>wwv_flow_api.id(24759382001816599) ,p_process_when=>'SHOW_MORE' ,p_process_when_type=>'REQUEST_EQUALS_CONDITION' ); wwv_flow_api.create_page_process( p_id=>wwv_flow_api.id(22299237139372035) ,p_process_sequence=>20 ,p_process_point=>'ON_SUBMIT_BEFORE_COMPUTATION' ,p_process_type=>'NATIVE_PLSQL' ,p_process_name=>'Show Less' ,p_process_sql_clob=>':P6_HIDE :=0;' ,p_process_clob_language=>'PLSQL' ,p_error_display_location=>'INLINE_IN_NOTIFICATION' ,p_process_when_button_id=>wwv_flow_api.id(22299161092372034) ,p_process_when=>'SHOW_LESS' ,p_process_when_type=>'REQUEST_EQUALS_CONDITION' ); end; /
CREATE PROCEDURE filmLibrary() BEGIN /* Write your SQL here. Terminate each statement with a semicolon. */ SET @fav_genre = (SELECT genre FROM movies GROUP BY genre ORDER BY COUNT(*) DESC LIMIT 1); SELECT s.actor, a.age FROM starring_actors AS s INNER JOIN actor_ages AS a ON s.actor = a.actor WHERE movie_name IN (SELECT movie FROM movies WHERE genre = @fav_genre) ORDER BY a.age DESC, s.actor; END
-- MySQL dump 10.13 Distrib 5.7.24, for Linux (x86_64) -- -- Host: 172.18.0.2 Database: fileshare -- ------------------------------------------------------ -- Server version 5.7.22-0ubuntu18.04.1 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; /*!40101 SET NAMES utf8 */; /*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */; /*!40103 SET TIME_ZONE='+00:00' */; /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */; /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */; /*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */; -- -- Table structure for table `avatars` -- DROP TABLE IF EXISTS `avatars`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `avatars` ( `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `uri` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `size` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `mime` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `likes` int(11) NOT NULL DEFAULT '0', `views` int(11) NOT NULL DEFAULT '0', `created_at` timestamp NULL DEFAULT NULL, `updated_at` timestamp NULL DEFAULT NULL, `ownerId` int(10) unsigned NOT NULL, `id` int(10) unsigned NOT NULL AUTO_INCREMENT, PRIMARY KEY (`id`), UNIQUE KEY `avatars_id_unique` (`id`), KEY `avatars_ownerid_foreign` (`ownerId`), CONSTRAINT `avatars_ownerid_foreign` FOREIGN KEY (`ownerId`) REFERENCES `users` (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `avatars` -- LOCK TABLES `avatars` WRITE; /*!40000 ALTER TABLE `avatars` DISABLE KEYS */; INSERT INTO `avatars` VALUES ('user.png','/img/user.png',NULL,NULL,0,0,NULL,NULL,1,1); /*!40000 ALTER TABLE `avatars` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `files` -- DROP TABLE IF EXISTS `files`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `files` ( `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `uri` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `size` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `mime` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `likes` int(11) NOT NULL DEFAULT '0', `views` int(11) NOT NULL DEFAULT '0', `created_at` timestamp NULL DEFAULT NULL, `updated_at` timestamp NULL DEFAULT NULL, `ownerId` int(10) unsigned NOT NULL, `id` int(10) unsigned NOT NULL AUTO_INCREMENT, PRIMARY KEY (`id`), UNIQUE KEY `files_id_unique` (`id`), KEY `files_ownerid_foreign` (`ownerId`), CONSTRAINT `files_ownerid_foreign` FOREIGN KEY (`ownerId`) REFERENCES `users` (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `files` -- LOCK TABLES `files` WRITE; /*!40000 ALTER TABLE `files` DISABLE KEYS */; /*!40000 ALTER TABLE `files` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `phinxlog` -- DROP TABLE IF EXISTS `phinxlog`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `phinxlog` ( `version` bigint(20) NOT NULL, `migration_name` varchar(100) DEFAULT NULL, `start_time` timestamp NULL DEFAULT NULL, `end_time` timestamp NULL DEFAULT NULL, `breakpoint` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`version`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `phinxlog` -- LOCK TABLES `phinxlog` WRITE; /*!40000 ALTER TABLE `phinxlog` DISABLE KEYS */; INSERT INTO `phinxlog` VALUES (20180319102013,'Users','2018-11-05 07:46:30','2018-11-05 07:46:30',0),(20180319110020,'UsersInfo','2018-11-05 07:46:30','2018-11-05 07:46:31',0),(20180319125543,'UsersSettings','2018-11-05 07:46:31','2018-11-05 07:46:32',0),(20180320125818,'Images','2018-10-10 10:43:01','2018-10-10 10:43:01',0),(20180628140959,'Files','2018-11-05 07:46:32','2018-11-05 07:46:33',0),(20180628141822,'Avatars','2018-11-05 07:46:33','2018-11-05 07:46:35',0),(20180708044221,'FileTokens','2018-10-07 22:28:25','2018-10-07 22:28:26',0); /*!40000 ALTER TABLE `phinxlog` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `users` -- DROP TABLE IF EXISTS `users`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `users` ( `email` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `password` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `token` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `id` int(10) unsigned NOT NULL AUTO_INCREMENT, `created_at` timestamp NULL DEFAULT NULL, `updated_at` timestamp NULL DEFAULT NULL, PRIMARY KEY (`id`), UNIQUE KEY `users_email_unique` (`email`), UNIQUE KEY `users_id_unique` (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `users` -- LOCK TABLES `users` WRITE; /*!40000 ALTER TABLE `users` DISABLE KEYS */; INSERT INTO `users` VALUES ('anonymous@fileshare','5bdff56bc2ba4',NULL,1,'2018-11-05 07:46:51','2018-11-05 07:46:51'); /*!40000 ALTER TABLE `users` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `users_info` -- DROP TABLE IF EXISTS `users_info`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `users_info` ( `name` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `userId` int(10) unsigned NOT NULL, `created_at` timestamp NULL DEFAULT NULL, `updated_at` timestamp NULL DEFAULT NULL, UNIQUE KEY `users_info_userid_unique` (`userId`), CONSTRAINT `users_info_userid_foreign` FOREIGN KEY (`userId`) REFERENCES `users` (`id`) ON DELETE CASCADE ON UPDATE CASCADE ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `users_info` -- LOCK TABLES `users_info` WRITE; /*!40000 ALTER TABLE `users_info` DISABLE KEYS */; INSERT INTO `users_info` VALUES ('anonym',1,'2018-11-05 07:46:51','2018-11-05 07:46:51'); /*!40000 ALTER TABLE `users_info` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `users_settings` -- DROP TABLE IF EXISTS `users_settings`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `users_settings` ( `accountStatus` tinyint(1) NOT NULL DEFAULT '1', `accessLvl` int(11) NOT NULL DEFAULT '1', `userId` int(10) unsigned NOT NULL, `created_at` timestamp NULL DEFAULT NULL, `updated_at` timestamp NULL DEFAULT NULL, UNIQUE KEY `users_settings_userid_unique` (`userId`), CONSTRAINT `users_settings_userid_foreign` FOREIGN KEY (`userId`) REFERENCES `users` (`id`) ON DELETE CASCADE ON UPDATE CASCADE ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `users_settings` -- LOCK TABLES `users_settings` WRITE; /*!40000 ALTER TABLE `users_settings` DISABLE KEYS */; INSERT INTO `users_settings` VALUES (1,1,1,'2018-11-05 07:46:51','2018-11-05 07:46:51'); /*!40000 ALTER TABLE `users_settings` ENABLE KEYS */; UNLOCK TABLES; /*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */; /*!40101 SET SQL_MODE=@OLD_SQL_MODE */; /*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */; /*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */; /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */; /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */; /*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */; -- Dump completed on 2018-11-05 17:47:28
<reponame>ShiyangQiu/sql-server-samples-shiyang ------------------------------------------------------------------ -- -- -- File: usp_ProductSelectionCriteria.sql -- -- Version: 0.0.0-1006 -- -- -- ------------------------------------------------------------------ SET QUOTED_IDENTIFIER OFF GO SET ANSI_NULLS ON GO USE InMemDB GO IF EXISTS ( SELECT name FROM sysobjects WHERE name = 'usp_ProductSelectionCriteria' ) DROP PROCEDURE usp_ProductSelectionCriteria GO CREATE PROCEDURE [dbo].usp_ProductSelectionCriteria ( @LOWER_PR_ID bigint, @UPPER_PR_ID bigint, @PC_ID bigint) WITH NATIVE_COMPILATION, EXECUTE AS OWNER, SCHEMABINDING AS BEGIN ATOMIC WITH ( TRANSACTION ISOLATION LEVEL = SNAPSHOT, LANGUAGE = N'us_english' ) DECLARE @pc_dec001 float, @pc_dec002 float, @pc_dec003 float, @pc_dec004 float, @pc_dec005 float, @pc_dec006 float, @pc_dec007 float, @pc_dec008 float, @pc_dec009 float, @pc_dec010 float, @pc_dec011 float, @pc_dec012 float, @pc_dec013 float, @pc_dec014 float, @pc_dec015 float, @pc_dec016 float, @pc_dec017 float, @pc_dec018 float, @pc_dec019 float, @pc_dec020 float, @pc_dec021 float, @pc_dec022 float, @pc_dec023 float, @pc_dec024 float, @pc_dec025 float, @pc_dec026 float, @pc_dec027 float, @pc_dec028 float, @pc_dec029 float, @pc_dec030 float, @pc_dec031 float, @pc_dec032 float, @pc_dec033 float, @pc_dec034 float, @pc_dec035 float, @pc_dec036 float, @pc_dec037 float, @pc_dec038 float, @pc_dec039 float, @pc_dec040 float, @pc_dec041 float, @pc_dec042 float, @pc_dec043 float, @pc_dec044 float, @pc_dec045 float, @pc_dec046 float, @pc_dec047 float, @pc_dec048 float, @pc_dec049 float, @pc_dec050 float, @pc_dec051 float, @pc_dec052 float, @pc_dec053 float, @pc_dec054 float, @pc_dec055 float, @pc_dec056 float, @pc_dec057 float, @pc_dec058 float, @pc_dec059 float, @pc_dec060 float, @pc_dec061 float, @pc_dec062 float, @pc_dec063 float, @pc_dec064 float, @pc_dec065 float, @pc_dec066 float, @pc_dec067 float, @pc_dec068 float, @pc_dec069 float, @pc_dec070 float, @pc_dec071 float, @pc_dec072 float, @pc_dec073 float, @pc_dec074 float, @pc_dec075 float, @pc_dec076 float, @pc_dec077 float, @pc_dec078 float, @pc_dec079 float, @pc_dec080 float, @pc_dec081 float, @pc_dec082 float, @pc_dec083 float, @pc_dec084 float, @pc_dec085 float, @pc_dec086 float, @pc_dec087 float, @pc_dec088 float, @pc_dec089 float, @pc_dec090 float, @pc_dec091 float, @pc_dec092 float, @pc_dec093 float, @pc_dec094 float, @pc_dec095 float, @pc_dec096 float, @pc_dec097 float, @pc_dec098 float, @pc_dec099 float, @pc_dec100 float SELECT @pc_dec001 = PC_DEC1, @pc_dec002 = PC_DEC2, @pc_dec003 = PC_DEC3, @pc_dec004 = PC_DEC4, @pc_dec005 = PC_DEC5, @pc_dec006 = PC_DEC6, @pc_dec007 = PC_DEC7, @pc_dec008 = PC_DEC8, @pc_dec009 = PC_DEC9, @pc_dec010 = PC_DEC10, @pc_dec011 = PC_DEC11, @pc_dec012 = PC_DEC12, @pc_dec013 = PC_DEC13, @pc_dec014 = PC_DEC14, @pc_dec015 = PC_DEC15, @pc_dec016 = PC_DEC16, @pc_dec017 = PC_DEC17, @pc_dec018 = PC_DEC18, @pc_dec019 = PC_DEC19, @pc_dec020 = PC_DEC20, @pc_dec021 = PC_DEC21, @pc_dec022 = PC_DEC22, @pc_dec023 = PC_DEC23, @pc_dec024 = PC_DEC24, @pc_dec025 = PC_DEC25, @pc_dec026 = PC_DEC26, @pc_dec027 = PC_DEC27, @pc_dec028 = PC_DEC28, @pc_dec029 = PC_DEC29, @pc_dec030 = PC_DEC30, @pc_dec031 = PC_DEC31, @pc_dec032 = PC_DEC32, @pc_dec033 = PC_DEC33, @pc_dec034 = PC_DEC34, @pc_dec035 = PC_DEC35, @pc_dec036 = PC_DEC36, @pc_dec037 = PC_DEC37, @pc_dec038 = PC_DEC38, @pc_dec039 = PC_DEC39, @pc_dec040 = PC_DEC40, @pc_dec041 = PC_DEC41, @pc_dec042 = PC_DEC42, @pc_dec043 = PC_DEC43, @pc_dec044 = PC_DEC44, @pc_dec045 = PC_DEC45, @pc_dec046 = PC_DEC46, @pc_dec047 = PC_DEC47, @pc_dec048 = PC_DEC48, @pc_dec049 = PC_DEC49, @pc_dec050 = PC_DEC50, @pc_dec051 = PC_DEC51, @pc_dec052 = PC_DEC52, @pc_dec053 = PC_DEC53, @pc_dec054 = PC_DEC54, @pc_dec055 = PC_DEC55, @pc_dec056 = PC_DEC56, @pc_dec057 = PC_DEC57, @pc_dec058 = PC_DEC58, @pc_dec059 = PC_DEC59, @pc_dec060 = PC_DEC60, @pc_dec061 = PC_DEC61, @pc_dec062 = PC_DEC62, @pc_dec063 = PC_DEC63, @pc_dec064 = PC_DEC64, @pc_dec065 = PC_DEC65, @pc_dec066 = PC_DEC66, @pc_dec067 = PC_DEC67, @pc_dec068 = PC_DEC68, @pc_dec069 = PC_DEC69, @pc_dec070 = PC_DEC70, @pc_dec071 = PC_DEC71, @pc_dec072 = PC_DEC72, @pc_dec073 = PC_DEC73, @pc_dec074 = PC_DEC74, @pc_dec075 = PC_DEC75, @pc_dec076 = PC_DEC76, @pc_dec077 = PC_DEC77, @pc_dec078 = PC_DEC78, @pc_dec079 = PC_DEC79, @pc_dec080 = PC_DEC80, @pc_dec081 = PC_DEC81, @pc_dec082 = PC_DEC82, @pc_dec083 = PC_DEC83, @pc_dec084 = PC_DEC84, @pc_dec085 = PC_DEC85, @pc_dec086 = PC_DEC86, @pc_dec087 = PC_DEC87, @pc_dec088 = PC_DEC88, @pc_dec089 = PC_DEC89, @pc_dec090 = PC_DEC90, @pc_dec091 = PC_DEC91, @pc_dec092 = PC_DEC92, @pc_dec093 = PC_DEC93, @pc_dec094 = PC_DEC94, @pc_dec095 = PC_DEC95, @pc_dec096 = PC_DEC96, @pc_dec097 = PC_DEC97, @pc_dec098 = PC_DEC98, @pc_dec099 = PC_DEC99, @pc_dec100 = PC_DEC100 FROM dbo.Purchase_Criteria WHERE PC_ID = @PC_ID SELECT TOP 20 PR_NAME, ((@pc_dec001/PR_DEC1-1)+(@pc_dec002/PR_DEC2-1)+(@pc_dec003/PR_DEC3-1)+(@pc_dec004/PR_DEC4-1)+(@pc_dec005/PR_DEC5-1)+(@pc_dec006/PR_DEC6-1)+(@pc_dec007/PR_DEC7-1)+(@pc_dec008/PR_DEC8-1)+(@pc_dec009/PR_DEC9-1)+(@pc_dec010/PR_DEC10-1)+(@pc_dec011/PR_DEC11-1)+(@pc_dec012/PR_DEC12-1)+(@pc_dec013/PR_DEC13-1)+(@pc_dec014/PR_DEC14-1)+(@pc_dec015/PR_DEC15-1)+(@pc_dec016/PR_DEC16-1)+(@pc_dec017/PR_DEC17-1)+(@pc_dec018/PR_DEC18-1)+(@pc_dec019/PR_DEC19-1)+(@pc_dec020/PR_DEC20-1)+(@pc_dec021/PR_DEC21-1)+(@pc_dec022/PR_DEC22-1)+(@pc_dec023/PR_DEC23-1)+(@pc_dec024/PR_DEC24-1)+(@pc_dec025/PR_DEC25-1)+(@pc_dec026/PR_DEC26-1)+(@pc_dec027/PR_DEC27-1)+(@pc_dec028/PR_DEC28-1)+(@pc_dec029/PR_DEC29-1)+(@pc_dec030/PR_DEC30-1)+(@pc_dec031/PR_DEC31-1)+(@pc_dec032/PR_DEC32-1)+(@pc_dec033/PR_DEC33-1)+(@pc_dec034/PR_DEC34-1)+(@pc_dec035/PR_DEC35-1)+(@pc_dec036/PR_DEC36-1)+(@pc_dec037/PR_DEC37-1)+(@pc_dec038/PR_DEC38-1)+(@pc_dec039/PR_DEC39-1)+(@pc_dec040/PR_DEC40-1)+(@pc_dec041/PR_DEC41-1)+(@pc_dec042/PR_DEC42-1)+(@pc_dec043/PR_DEC43-1)+(@pc_dec044/PR_DEC44-1)+(@pc_dec045/PR_DEC45-1)+(@pc_dec046/PR_DEC46-1)+(@pc_dec047/PR_DEC47-1)+(@pc_dec048/PR_DEC48-1)+(@pc_dec049/PR_DEC49-1)+(@pc_dec050/PR_DEC50-1)+(@pc_dec051/PR_DEC51-1)+(@pc_dec052/PR_DEC52-1)+(@pc_dec053/PR_DEC53-1)+(@pc_dec054/PR_DEC54-1)+(@pc_dec055/PR_DEC55-1)+(@pc_dec056/PR_DEC56-1)+(@pc_dec057/PR_DEC57-1)+(@pc_dec058/PR_DEC58-1)+(@pc_dec059/PR_DEC59-1)+(@pc_dec060/PR_DEC60-1)+(@pc_dec061/PR_DEC61-1)+(@pc_dec062/PR_DEC62-1)+(@pc_dec063/PR_DEC63-1)+(@pc_dec064/PR_DEC64-1)+(@pc_dec065/PR_DEC65-1)+(@pc_dec066/PR_DEC66-1)+(@pc_dec067/PR_DEC67-1)+(@pc_dec068/PR_DEC68-1)+(@pc_dec069/PR_DEC69-1)+(@pc_dec070/PR_DEC70-1)+(@pc_dec071/PR_DEC71-1)+(@pc_dec072/PR_DEC72-1)+(@pc_dec073/PR_DEC73-1)+(@pc_dec074/PR_DEC74-1)+(@pc_dec075/PR_DEC75-1)+(@pc_dec076/PR_DEC76-1)+(@pc_dec077/PR_DEC77-1)+(@pc_dec078/PR_DEC78-1)+(@pc_dec079/PR_DEC79-1)+(@pc_dec080/PR_DEC80-1)+(@pc_dec081/PR_DEC81-1)+(@pc_dec082/PR_DEC82-1)+(@pc_dec083/PR_DEC83-1)+(@pc_dec084/PR_DEC84-1)+(@pc_dec085/PR_DEC85-1)+(@pc_dec086/PR_DEC86-1)+(@pc_dec087/PR_DEC87-1)+(@pc_dec088/PR_DEC88-1)+(@pc_dec089/PR_DEC89-1)+(@pc_dec090/PR_DEC90-1)+(@pc_dec091/PR_DEC91-1)+(@pc_dec092/PR_DEC92-1)+(@pc_dec093/PR_DEC93-1)+(@pc_dec094/PR_DEC94-1)+(@pc_dec095/PR_DEC95-1)+(@pc_dec096/PR_DEC96-1)+(@pc_dec097/PR_DEC97-1)+(@pc_dec098/PR_DEC98-1)+(@pc_dec099/PR_DEC99-1)+(@pc_dec100/PR_DEC100-1)) AS Closeness FROM dbo.Products WHERE PR_ID BETWEEN @LOWER_PR_ID AND @UPPER_PR_ID ORDER BY Closeness ASC END GO
<gh_stars>10-100 -- file:plpgsql.sql ln:1517 expect:false BEGIN FOR i IN $1 .. $2 LOOP RETURN NEXT i + 1
<reponame>18F/openFEC<filename>data/migrations/V0064__schedule_f_add_cycle_idx.sql CREATE INDEX ofec_sched_f_mv_tmp_cycle_sub_id_idx1 ON ofec_sched_f_mv USING btree (election_cycle, sub_id);
select c_integer, cume_dist() over(order by c_integer desc nulls first) from j1 order by 2;
<gh_stars>1-10 INSERT INTO salumistore.reputation VALUES (1, 'Traditional'); INSERT INTO salumistore.reputation VALUES (2, 'Normal' ); INSERT INTO salumistore.products (name, price, fat, reputation) VALUES ('Chorizo Spagnolo' , 15.55, 49.99, 2); INSERT INTO salumistore.products (name, price, fat, reputation) VALUES ('Swedish Falukorv' , 29.55, 31.00, 2); INSERT INTO salumistore.products (name, price, fat, reputation) VALUES ('Light Fuet' , 57.37, 31.00, 2); INSERT INTO salumistore.products (name, price, fat, reputation) VALUES ('Premium Polish Kabanos' , 41.60, 37.00, 1); INSERT INTO salumistore.products (name, price, fat, reputation) VALUES ('Premium ''Nduja Calabrese' , 73.23, 38.00, 1); INSERT INTO salumistore.products (name, price, fat, reputation) VALUES ('Gourmet Salam Casalin' , 41.60, 37.00, 1); INSERT INTO salumistore.products (name, price, fat, reputation) VALUES ('Salame all''aglio' , 73.23, 38.00, 1); INSERT INTO salumistore.products (name, price, fat, reputation) VALUES ('Salame Brianza D.O.P.' , 29.55, 31.00, 1); INSERT INTO salumistore.products (name, price, fat, reputation) VALUES ('Salame Bastardei' , 57.37, 31.00, 2);
/****** Object: View [dbo].[V_Search_CollectionID_By_ProteinName] ******/ SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO CREATE VIEW dbo.V_Search_CollectionID_By_ProteinName AS SELECT dbo.T_Protein_Collection_Members.Protein_Collection_ID AS Collection_ID, dbo.T_Protein_Names.Name, 'collectionIDByProteinName' AS Value_type FROM dbo.T_Protein_Collection_Members INNER JOIN dbo.T_Protein_Names ON dbo.T_Protein_Collection_Members.Original_Reference_ID = dbo.T_Protein_Names.Reference_ID GO
<filename>persistence/sql/migrations/sql/20200705105359_rename_identities_schema.cockroach.up.sql ALTER TABLE "identities" RENAME COLUMN "traits_schema_id" TO "schema_id";COMMIT TRANSACTION;BEGIN TRANSACTION;
-- phpMyAdmin SQL Dump -- version 4.7.4 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1:3306 -- Generation Time: Jun 20, 2018 at 11:16 PM -- Server version: 5.7.19 -- PHP Version: 7.1.9 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; /*!40101 SET NAMES utf8mb4 */; -- -- Database: `infrabidtrack` -- -- -------------------------------------------------------- -- -- Table structure for table `account_classification` -- DROP TABLE IF EXISTS `account_classification`; CREATE TABLE IF NOT EXISTS `account_classification` ( `account_id` int(11) NOT NULL AUTO_INCREMENT, `classification` varchar(255) NOT NULL, PRIMARY KEY (`account_id`) ) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=latin1; -- -- Dumping data for table `account_classification` -- INSERT INTO `account_classification` (`account_id`, `classification`) VALUES (1, 'Capitol Outlay'), (2, 'MOOE'); -- -------------------------------------------------------- -- -- Table structure for table `barangays` -- DROP TABLE IF EXISTS `barangays`; CREATE TABLE IF NOT EXISTS `barangays` ( `barangay_id` int(11) NOT NULL AUTO_INCREMENT, `barangay_code` varchar(11) NOT NULL, `barangay` varchar(225) NOT NULL, `municipality_id` int(11) NOT NULL, PRIMARY KEY (`barangay_id`), KEY `selected_municipality` (`municipality_id`) ) ENGINE=InnoDB AUTO_INCREMENT=25 DEFAULT CHARSET=latin1; -- -- Dumping data for table `barangays` -- INSERT INTO `barangays` (`barangay_id`, `barangay_code`, `barangay`, `municipality_id`) VALUES (1, '1101001', 'Abiang', 1), (2, '1101002', 'Caliking', 1), (3, '1101003', 'Cattubo', 1), (4, '1101004', 'Naguey', 1), (5, '1101005', 'Paoay', 1), (6, '1101006', 'Pasdong', 1), (7, '1101007', 'Poblacion(Bakun)', 1), (8, '1101008', 'Topdac', 1), (9, '1103001', 'Ampusongan', 2), (10, '1103002', 'Bagu', 2), (11, '1103003', 'Dalipey', 2), (12, '1103004', 'Gambang', 2), (13, '1103005', 'Kayapa', 2), (14, '1103006', 'Poblacion(Bakun)', 2), (15, '1103007', 'Sinacbat', 2), (16, '1104001', 'Ambuclao', 3), (17, '1104002', 'Bila', 3), (18, '1104003', 'Bokod-Bisal', 3), (19, '1104004', 'Daclan(Bokod)', 3), (20, '1104005', 'Ekip', 3), (21, '1104006', 'Karao', 3), (22, '1104007', 'Nawal', 3), (23, '1104008', 'Pito', 3), (24, '1104009', 'Poblacion(Bokod)', 3); -- -------------------------------------------------------- -- -- Table structure for table `contractors` -- DROP TABLE IF EXISTS `contractors`; CREATE TABLE IF NOT EXISTS `contractors` ( `contractor_id` int(11) NOT NULL AUTO_INCREMENT, `businessname` varchar(255) NOT NULL, `owner` varchar(255) NOT NULL, `address` varchar(255) NOT NULL, `contactnumber` varchar(13) NOT NULL, PRIMARY KEY (`contractor_id`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1; -- -------------------------------------------------------- -- -- Table structure for table `funds` -- DROP TABLE IF EXISTS `funds`; CREATE TABLE IF NOT EXISTS `funds` ( `fund_id` int(11) NOT NULL AUTO_INCREMENT, `source` varchar(255) NOT NULL, PRIMARY KEY (`fund_id`) ) ENGINE=InnoDB AUTO_INCREMENT=14 DEFAULT CHARSET=latin1; -- -- Dumping data for table `funds` -- INSERT INTO `funds` (`fund_id`, `source`) VALUES (1, 'PSB'), (2, 'Calamity Fund'), (3, 'GF'), (4, 'Trust'), (5, 'PRDP'), (6, 'SLRF'), (7, 'PAMANA'), (8, 'PRNDP'), (9, 'DOE'), (10, 'SEF'), (11, 'CHARMP'), (12, 'Supplemental Budget'), (13, 'Other Funds'); -- -------------------------------------------------------- -- -- Table structure for table `municipalities` -- DROP TABLE IF EXISTS `municipalities`; CREATE TABLE IF NOT EXISTS `municipalities` ( `municipality_id` int(11) NOT NULL AUTO_INCREMENT, `municipality_code` varchar(11) NOT NULL, `municipality` varchar(225) NOT NULL, PRIMARY KEY (`municipality_id`) ) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=latin1; -- -- Dumping data for table `municipalities` -- INSERT INTO `municipalities` (`municipality_id`, `municipality_code`, `municipality`) VALUES (1, '1101000', 'Atok'), (2, '1103000', 'Bakun'), (3, '1104000', 'Bokod'); -- -------------------------------------------------------- -- -- Table structure for table `procact` -- DROP TABLE IF EXISTS `procact`; CREATE TABLE IF NOT EXISTS `procact` ( `plan_id` int(11) NOT NULL, `pre_proc` date DEFAULT NULL, `advertisement` date DEFAULT NULL, `pre_bid` date DEFAULT NULL, `eligibility_check` date DEFAULT NULL, `open_bid` date DEFAULT NULL, `bid_evaluation` date DEFAULT NULL, `post_qual` date DEFAULT NULL, `award_notice` date DEFAULT NULL, `contract_signing` date DEFAULT NULL, `proceed_notice` date DEFAULT NULL, `delivery_completion` date DEFAULT NULL, `acceptance_turnover` date DEFAULT NULL, `remark` varchar(225) DEFAULT NULL, KEY `plan_activity` (`plan_id`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1; -- -------------------------------------------------------- -- -- Table structure for table `procurement_mode` -- DROP TABLE IF EXISTS `procurement_mode`; CREATE TABLE IF NOT EXISTS `procurement_mode` ( `mode_id` int(11) NOT NULL AUTO_INCREMENT, `mode` varchar(255) NOT NULL, PRIMARY KEY (`mode_id`) ) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=latin1; -- -- Dumping data for table `procurement_mode` -- INSERT INTO `procurement_mode` (`mode_id`, `mode`) VALUES (1, 'Bidding'), (2, 'SVP'), (3, 'Negotiated'); -- -------------------------------------------------------- -- -- Table structure for table `project_plan` -- DROP TABLE IF EXISTS `project_plan`; CREATE TABLE IF NOT EXISTS `project_plan` ( `plan_id` int(11) NOT NULL AUTO_INCREMENT, `project_no` int(11) NOT NULL, `project_title` varchar(255) NOT NULL, `municipality_id` int(11) NOT NULL, `barangay_id` int(11) NOT NULL, `projtype_id` int(11) NOT NULL, `mode_id` int(11) NOT NULL, `fund_id` int(11) NOT NULL, `account_id` int(11) NOT NULL, `abc` decimal(25,2) NOT NULL, `status` varchar(255) NOT NULL, `re-bid_count` int(11) DEFAULT NULL, PRIMARY KEY (`plan_id`), KEY `plan_municipality` (`municipality_id`), KEY `plan_barangay` (`barangay_id`), KEY `plan_type` (`projtype_id`), KEY `plan_mode` (`mode_id`), KEY `plan_fund` (`fund_id`), KEY `plan_account` (`account_id`) ) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=latin1; -- -- Dumping data for table `project_plan` -- INSERT INTO `project_plan` (`plan_id`, `project_no`, `project_title`, `municipality_id`, `barangay_id`, `projtype_id`, `mode_id`, `fund_id`, `account_id`, `abc`, `status`, `re-bid_count`) VALUES (1, 3, 'new tittle', 3, 21, 15, 2, 4, 2, '90909023913.00', 'pending', NULL), (2, 2, 'Tire Path for atok ', 1, 6, 9, 1, 7, 1, '50000000.00', 'pending', NULL); -- -------------------------------------------------------- -- -- Table structure for table `projtype` -- DROP TABLE IF EXISTS `projtype`; CREATE TABLE IF NOT EXISTS `projtype` ( `projtype_id` int(11) NOT NULL AUTO_INCREMENT, `type` varchar(255) NOT NULL, PRIMARY KEY (`projtype_id`) ) ENGINE=InnoDB AUTO_INCREMENT=18 DEFAULT CHARSET=latin1; -- -- Dumping data for table `projtype` -- INSERT INTO `projtype` (`projtype_id`, `type`) VALUES (1, 'FMP'), (2, 'Bridge'), (3, 'Munti-Purpose Building/Hall/Outpost'), (4, 'Slope Protection'), (5, 'School Building'), (6, 'Senior Citizen\'s Building'), (7, 'Domestic Water Supply/Irrigation/Waterworks'), (8, 'Footbridges'), (9, 'Footpath/Foot Trail'), (10, 'Multi-Purpose Shed/Waiting Shed'), (11, 'Multi-Purpose Gym/Basketball Count'), (12, 'Drainage Canal'), (13, 'Flood Control/Riprapping/Slope Protection'), (14, 'Provincial Road'), (15, 'Health &amp; PHO Facilities'), (16, 'Agriculture Services'), (17, 'Veterinary Services'); -- -------------------------------------------------------- -- -- Table structure for table `users` -- DROP TABLE IF EXISTS `users`; CREATE TABLE IF NOT EXISTS `users` ( `user_id` int(11) NOT NULL AUTO_INCREMENT, `first_name` varchar(25) NOT NULL, `middle_name` varchar(25) NOT NULL, `last_name` varchar(25) NOT NULL, `username` varchar(255) NOT NULL, `password` varchar(255) NOT NULL, `user_type` varchar(20) NOT NULL, PRIMARY KEY (`user_id`) ) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=latin1; -- -- Dumping data for table `users` -- INSERT INTO `users` (`user_id`, `first_name`, `middle_name`, `last_name`, `username`, `password`, `user_type`) VALUES (1, 'admin', 'admin', 'admin', '<PASSWORD>', '<PASSWORD>', '<PASSWORD>'); -- -- Constraints for dumped tables -- -- -- Constraints for table `barangays` -- ALTER TABLE `barangays` ADD CONSTRAINT `selected_municipality` FOREIGN KEY (`municipality_id`) REFERENCES `municipalities` (`municipality_id`) ON DELETE CASCADE ON UPDATE CASCADE; -- -- Constraints for table `procact` -- ALTER TABLE `procact` ADD CONSTRAINT `plan_activity` FOREIGN KEY (`plan_id`) REFERENCES `project_plan` (`plan_id`) ON UPDATE CASCADE; -- -- Constraints for table `project_plan` -- ALTER TABLE `project_plan` ADD CONSTRAINT `plan_account` FOREIGN KEY (`account_id`) REFERENCES `account_classification` (`account_id`) ON DELETE CASCADE, ADD CONSTRAINT `plan_barangay` FOREIGN KEY (`barangay_id`) REFERENCES `barangays` (`barangay_id`) ON UPDATE CASCADE, ADD CONSTRAINT `plan_fund` FOREIGN KEY (`fund_id`) REFERENCES `funds` (`fund_id`) ON DELETE CASCADE, ADD CONSTRAINT `plan_mode` FOREIGN KEY (`mode_id`) REFERENCES `procurement_mode` (`mode_id`) ON DELETE CASCADE, ADD CONSTRAINT `plan_municipality` FOREIGN KEY (`municipality_id`) REFERENCES `municipalities` (`municipality_id`) ON UPDATE CASCADE, ADD CONSTRAINT `plan_type` FOREIGN KEY (`projtype_id`) REFERENCES `projtype` (`projtype_id`) ON DELETE CASCADE; COMMIT; /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */; /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
-- Table: public."SpendSummaries" -- DROP TABLE public."SpendSummaries"; CREATE TABLE public."SpendSummaries" ( "ID" bigserial NOT NULL, "TrackerID" bigint NOT NULL, "UserID" bigint NOT NULL, "Currency" text NOT NULL DEFAULT '£'::text, "Value" numeric NOT NULL, CONSTRAINT "PK_SpendSummaries" PRIMARY KEY ("ID"), CONSTRAINT "FK_SpendSummaries_Trackers_TrackerID" FOREIGN KEY ("TrackerID") REFERENCES public."Trackers" ("ID") MATCH SIMPLE ON UPDATE NO ACTION ON DELETE NO ACTION, CONSTRAINT "FK_SpendSummaries_Users_UserID" FOREIGN KEY ("UserID") REFERENCES public."Users" ("ID") MATCH SIMPLE ON UPDATE NO ACTION ON DELETE NO ACTION ) WITH ( OIDS=FALSE ); ALTER TABLE public."SpendSummaries" OWNER TO godutch; -- Index: public."NonClusteredIndex-20151207-211821" -- DROP INDEX public."NonClusteredIndex-20151207-211821"; CREATE INDEX "NonClusteredIndex-20151207-211821" ON public."SpendSummaries" USING btree ("TrackerID");
<filename>HackerRank/sql/Basic Select/Weather Observation Station 10.sql SELECT DISTINCT city FROM station WHERE city NOT RLIKE '.*[aeiouAEIOU]$'
<gh_stars>0 -- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Hôte : 127.0.0.1:3306 -- Généré le : mar. 02 mars 2021 à 22:18 -- Version du serveur : 8.0.21 -- Version de PHP : 7.4.9 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; /*!40101 SET NAMES utf8mb4 */; -- -- Base de données : `football_base` -- CREATE DATABASE IF NOT EXISTS `football_base` DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci; USE `football_base`; -- -------------------------------------------------------- -- -- Structure de la table `absence` -- DROP TABLE IF EXISTS `absence`; CREATE TABLE IF NOT EXISTS `absence` ( `id_absence` int NOT NULL AUTO_INCREMENT, `codeAbsence` enum('Blessé','Suspendu','Absent') CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL, `date` date NOT NULL, `id_Effectif` int NOT NULL, PRIMARY KEY (`id_absence`), KEY `FKid_Effectif` (`id_Effectif`) USING BTREE ) ENGINE=MyISAM AUTO_INCREMENT=11 DEFAULT CHARSET=utf8; -- -- Déchargement des données de la table `absence` -- INSERT INTO `absence` (`id_absence`, `codeAbsence`, `date`, `id_Effectif`) VALUES (1, 'Blessé', '2020-08-16', 1), (2, 'Suspendu', '2021-03-14', 2), (10, 'Suspendu', '2021-02-21', 3), (6, 'Blessé', '2021-03-29', 1); -- -------------------------------------------------------- -- -- Structure de la table `calendrierrencontre` -- DROP TABLE IF EXISTS `calendrierrencontre`; CREATE TABLE IF NOT EXISTS `calendrierrencontre` ( `id_rencontre` int NOT NULL AUTO_INCREMENT, `categorie` varchar(255) NOT NULL DEFAULT 'seniors', `competition` enum('Amical','Coupe de France','Coupe de l''Anjou','Coupe des Pays de la loire','Coupe des Réserves','D1 Groupe A','D4 Groupe E','D5 Groupe A') NOT NULL, `equipe` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL, `equipeAdverse` varchar(255) NOT NULL, `date` date NOT NULL, `heure` time NOT NULL, `terrain` varchar(255) NOT NULL, `site` varchar(255) NOT NULL, PRIMARY KEY (`id_rencontre`) ) ENGINE=MyISAM AUTO_INCREMENT=6 DEFAULT CHARSET=utf8; -- -- Déchargement des données de la table `calendrierrencontre` -- INSERT INTO `calendrierrencontre` (`id_rencontre`, `categorie`, `competition`, `equipe`, `equipeAdverse`, `date`, `heure`, `terrain`, `site`) VALUES (1, 'seniors', 'Amical', 'SeniorsA', 'Ambillou ASVR 1', '2020-08-16', '14:45:00', 'Stade Alphonse leroi 1', 'Ambillou'), (2, 'seniors', 'Coupe de l\'Anjou', 'SeniorsB', 'Valanjou AS 2', '2020-08-23', '15:00:00', 'Stade de contades', 'Allonnes'), (3, 'seniors', 'Coupe des Pays de la loire', 'SeniorsA', 'Angers NDC 2', '2020-08-23', '15:00:00', 'St<NAME> 1', 'Bellevigne en Layon'), (4, 'seniors', 'D4 Groupe E', 'SeniorsC', 'St Hilaire Vihiers 4', '2020-08-23', '15:00:00', 'Terrain A', 'Martigne'), (5, 'seniors', 'D1 Groupe A', 'SeniorsB', 'Angers NDC 2', '2021-03-28', '14:00:00', 'St<NAME> bertin 1', 'Cersay'); -- -------------------------------------------------------- -- -- Structure de la table `convocation` -- DROP TABLE IF EXISTS `convocation`; CREATE TABLE IF NOT EXISTS `convocation` ( `id_convocation` int NOT NULL AUTO_INCREMENT, `messageRdv` varchar(255) NOT NULL, `id_rencontre` int NOT NULL, PRIMARY KEY (`id_convocation`), KEY `FKid_rencontre` (`id_rencontre`) ) ENGINE=MyISAM AUTO_INCREMENT=4 DEFAULT CHARSET=utf8; -- -- Déchargement des données de la table `convocation` -- INSERT INTO `convocation` (`id_convocation`, `messageRdv`, `id_rencontre`) VALUES (1, 'Venez habillé il fait froid', 2), (2, 'derrière le gymnase', 3), (3, 'En face d\'une superette ', 4); -- -------------------------------------------------------- -- -- Structure de la table `convoquee` -- DROP TABLE IF EXISTS `convoquee`; CREATE TABLE IF NOT EXISTS `convoquee` ( `id_convoquee` int NOT NULL AUTO_INCREMENT, `id_effectif` int NOT NULL, `id_convocation` int NOT NULL, PRIMARY KEY (`id_convoquee`), KEY `FKid_Effectif` (`id_effectif`), KEY `FKid_convocation` (`id_convocation`) ) ENGINE=MyISAM AUTO_INCREMENT=41 DEFAULT CHARSET=utf8; -- -- Déchargement des données de la table `convoquee` -- INSERT INTO `convoquee` (`id_convoquee`, `id_effectif`, `id_convocation`) VALUES (1, 1, 1), (2, 2, 1), (3, 3, 1), (4, 4, 1), (5, 5, 1), (6, 6, 1), (7, 7, 1), (8, 8, 1), (9, 9, 1), (10, 10, 1), (11, 11, 1), (12, 12, 1), (13, 14, 2), (14, 15, 2), (15, 16, 2), (16, 17, 2), (17, 18, 2), (18, 19, 2), (19, 20, 2), (20, 21, 2), (21, 22, 2), (22, 23, 2), (23, 24, 2), (24, 25, 2), (25, 26, 2), (26, 27, 3), (27, 28, 3), (28, 29, 3), (29, 30, 3), (30, 31, 3), (31, 32, 3), (32, 33, 3), (33, 34, 3), (34, 35, 3), (35, 36, 3), (36, 37, 3), (37, 38, 3), (38, 39, 3), (39, 40, 3), (40, 41, 3); -- -------------------------------------------------------- -- -- Structure de la table `effectif` -- DROP TABLE IF EXISTS `effectif`; CREATE TABLE IF NOT EXISTS `effectif` ( `id_effectif` int NOT NULL AUTO_INCREMENT, `typeLicence` varchar(255) NOT NULL DEFAULT 'Libre', `prenom` varchar(255) NOT NULL, `nom` varchar(255) NOT NULL, `Licence` varchar(3) DEFAULT 'oui', PRIMARY KEY (`id_effectif`) ) ENGINE=MyISAM AUTO_INCREMENT=65 DEFAULT CHARSET=utf8; -- -- Déchargement des données de la table `effectif` -- INSERT INTO `effectif` (`id_effectif`, `typeLicence`, `prenom`, `nom`, `Licence`) VALUES (1, 'Libre', 'Al', 'Ambiqué', 'oui'), (2, 'Libre', 'Bonnie', 'Dée', 'oui'), (3, 'Libre', 'Ève', 'Anescense', 'oui'), (4, 'Libre', 'Hal', 'Aniche', 'oui'), (5, 'Libre', 'Hubert', 'Gamote', 'oui'), (6, 'Libre', 'Jean', 'Tanlelou', 'oui'), (7, 'Libre', 'José', 'Patelefaire', 'oui'), (8, 'Libre', 'Marie', 'Covert', 'oui'), (9, 'Libre', 'Marie', 'Nière', 'oui'), (10, 'Libre', 'Marie', 'Rouanna', 'oui'), (11, 'Libre', 'Marion', 'Lait', 'oui'), (12, 'Libre', 'Marty', 'Ni', 'oui'), (13, 'Libre', 'Maude', 'Cologne', 'oui'), (14, 'Libre', 'Mehdi', 'Zan', 'oui'), (15, 'Libre', 'Mélusine', 'Engraiv', 'oui'), (16, 'Libre', 'Mouss', 'Tache', 'oui'), (17, 'Libre', 'Otto', 'Psie', 'oui'), (18, 'Libre', 'Paul', 'Iglotte', 'oui'), (19, 'Libre', 'Pierre', 'Oglyphe', 'oui'), (20, 'Libre', 'Sam', 'Soule', 'oui'), (21, 'Libre', 'Sophie', 'Stiqué', 'oui'), (22, 'Libre', 'Terry', 'Dicule', 'oui'), (23, 'Libre', 'Théo', 'Jasmin', 'oui'), (24, 'Libre', 'Jean-Pascal', 'Micheaux', 'oui'), (25, 'Libre', 'José', 'Milhaud', 'oui'), (26, 'Libre', 'Emmanuel', 'Barbeau', 'oui'), (27, 'Libre', 'Norbert', 'Bruguière', 'oui'), (28, 'Libre', 'François', 'Gagnon', 'oui'), (29, 'Libre', 'Marcel', 'Ardouin', 'oui'), (30, 'Libre', 'Léopold', 'D\'Aboville', 'oui'), (31, 'Libre', 'Abelin', 'Delaplace', 'oui'), (32, 'Libre', 'Anatole', 'Bonnot', 'oui'), (33, 'Libre', 'Alex', 'Compere', 'oui'), (34, 'Libre', 'Amandine', 'Dupuy', 'oui'), (35, 'Libre', 'Lydie', 'De Verley', 'oui'), (36, 'Libre', 'Lise', 'Trémaux', 'oui'), (37, 'Libre', 'Haydée', 'Batteux', 'oui'), (38, 'Libre', 'Anita', 'Jégou', 'oui'), (39, 'Libre', 'Guillemette', 'Jacquemoud', 'non'), (40, 'Libre', 'Annie', 'Chappelle', 'oui'), (41, 'Libre', 'Aliénor', 'Courvoisier', 'oui'), (42, 'Libre', 'Clotilde', 'Rouzet', 'oui'), (43, 'Libre', 'Vanessa', 'Toutain', 'oui'), (44, 'Libre', 'Blaise', 'Cochet', 'oui'), (45, 'Libre', 'Marius', 'Jacquier', 'oui'), (46, 'Libre', 'Martial', 'Couturier', 'oui'), (47, 'Libre', 'Jérémie', 'Arsenault', 'oui'), (48, 'Libre', 'Marcel', 'Descombes', 'oui'), (49, 'Libre', 'Valentin', 'Morel', 'oui'), (50, 'Libre', 'Ignace', 'Brunelle', 'oui'), (51, 'Libre', 'Robin', 'Delon', 'non'), (52, 'Libre', 'Timothé', 'Lefrançois', 'oui'), (53, 'Libre', 'Mathis', 'Pierlot', 'oui'), (55, 'Libre', 'yoann', 'jouvin', 'oui'), (56, 'Libre', 'celia', 'robin', 'oui'), (57, 'Libre', 'johan', 'larc', 'non'), (62, 'Libre', 'loupo', 'nathanaël', 'non'), (59, 'Libre', 'laure', 'leon', 'non'), (63, 'Libre', 'charles', 'leon', 'oui'); -- -------------------------------------------------------- -- -- Structure de la table `utilisateur` -- DROP TABLE IF EXISTS `utilisateur`; CREATE TABLE IF NOT EXISTS `utilisateur` ( `id_utilisateur` int NOT NULL AUTO_INCREMENT, `nom` varchar(255) NOT NULL, `prenom` varchar(255) NOT NULL, `type` enum('entraineur','secretaire') CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL, `adresseEmail` varchar(50) NOT NULL, `motDePasse` varchar(50) NOT NULL, PRIMARY KEY (`id_utilisateur`) ) ENGINE=MyISAM AUTO_INCREMENT=3 DEFAULT CHARSET=utf8; -- -- Déchargement des données de la table `utilisateur` -- INSERT INTO `utilisateur` (`id_utilisateur`, `nom`, `prenom`, `type`, `adresseEmail`, `motDePasse`) VALUES (1, 'Brosseau', 'Aurélien', 'entraineur', '<EMAIL>', 'mdpaurelien'), (2, 'Gaudreau', 'Frank', 'secretaire', '<EMAIL>', 'mdpfrank'); COMMIT; /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */; /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
<gh_stars>0 -------------------------------------------------------------------------------- -- Up -------------------------------------------------------------------------------- CREATE TABLE css_selector ( name VARCHAR PRIMARY KEY NOT NULL, created_at DATE NOT NULL, seen_at DATE -- first_seen_at DATE, -- last_seen_at DATE ); CREATE TABLE css_file ( name VARCHAR PRIMARY KEY NOT NULL, created_at DATE NOT NULL, seen_at DATE ); CREATE TABLE file_selector ( selector VARCHAR NOT NULL, file VARCHAR NOT NULL, PRIMARY KEY (selector, file) ); CREATE TABLE css_file_history ( pattern VARCHAR NOT NULL, url VARCHAR PRIMARY KEY NOT NULL, created_at DATE NOT NULL ); -------------------------------------------------------------------------------- -- Down -------------------------------------------------------------------------------- DROP TABLE selector; DROP TABLE css_file; DROP TABLE file_selector; DROP TABLE css_file_history;
\i 05-clustering-a-regions.sql \i 05-clustering-b-clusters.sql \i 05-clustering-c-size-1.sql \i 05-clustering-d-size-2.sql \i 05-clustering-e-pairs.sql \i 05-clustering-f-size-N.sql
<filename>setup/SQL/CreateTables.sql DROP DATABASE IF EXISTS HeadacheBot; CREATE DATABASE HeadacheBot; USE HeadacheBot; CREATE TABLE question ( QID INT NOT NULL AUTO_INCREMENT, qText VARCHAR (256), PRIMARY KEY (QID)); CREATE TABLE leads_to ( parentQID INT, childQID INT, response VARCHAR (256), PRIMARY KEY (parentQID, childQID), FOREIGN KEY (parentQID) REFERENCES question (QID), FOREIGN KEY (childQID) REFERENCES question (QID)); -- how would we generate training phrases? CREATE TABLE DFintent ( IID INT NOT NULL AUTO_INCREMENT, response VARCHAR (256), inputCtx JSON, outputCtx JSON, params JSON, fullfillment JSON,-- added isConversationEnd BOOL, -- added isDuplicate BOOL, dfEvent JSON, dfAction JSON, trainingPhrase JSON, PRIMARY KEY (IID)); CREATE TABLE DFleads_to ( parentIID INT, childIID INT, PRIMARY KEY (parentIID, childIID), FOREIGN KEY (parentIID) REFERENCES DFintent (IID), FOREIGN KEY (childIID) REFERENCES DFintent (IID)); CREATE TABLE corresponds_to ( QID INT, IID INT, PRIMARY KEY (QID, IID), FOREIGN KEY (QID) REFERENCES question (QID), FOREIGN KEY (IID) REFERENCES DFintent (IID));
CREATE TABLE ig_media ( id String, caption Nullable(String), comments_count Nullable(Int64), ig_id Nullable(String), is_comment_enabled Nullable(UInt8), like_count Nullable(Int64), media_type Nullable(String), media_url Nullable(String), permalink Nullable(String), shortcode Nullable(String), thumbnail_url Nullable(String), timestamp Nullable(String), username Nullable(String) ) ENGINE = Log
/* Use WideWorldImporters Database */ drop table if exists dbo.sample_cities; select CityId, CityName, StateProvinceID, [Location], LatestRecordedPopulation, LastEditedBy into dbo.sample_cities from [Application].[Cities] go select CityName, count(*) as [Rows] from dbo.sample_cities where CityName in ('Redmond', 'Bellevue', 'Kirkland') group by CityName go begin tran select @@trancount -- Make some changes insert into dbo.sample_cities (CityID, CityName, StateProvinceID, LastEditedBy) values (99999, 'Redmond', 50, 1) delete from dbo.sample_cities where CityName = 'Bellevue' update dbo.sample_cities set LatestRecordedPopulation = 123456 where CityName = 'Kirkland' and StateProvinceID = 50 -- This connection can see all the changes done to the data by itself select * from dbo.sample_cities where CityName IN ('Kirkland', 'Redmond', 'Bellevue') order by CityID select CityName, count(*) as [Rows] from dbo.sample_cities where CityName in ('Redmond', 'Bellevue', 'Kirkland') group by CityName select @@trancount /* STOP HERE AND EXECUTE IN ANOTHER SESSION THE "connection-b.sql" SCRIPT BEFORE PROCEEDING! */ commit tran --or rollback tran
SELECT COUNT(DISTINCT "MulheresMil_1"."Calculation_838513981462429699") AS "ctd:Calculation_838513981462429699:ok" FROM "MulheresMil_1" WHERE ((NOT (("MulheresMil_1"."nome da sit matricula (situacao detalhada)" NOT IN ('', 'INTEGRALIZADA', 'TRANCADA', 'EM_CURSO', 'EM_DEPENDÊNCIA')) OR ("MulheresMil_1"."nome da sit matricula (situacao detalhada)" IS NULL))) AND (NOT ("MulheresMil_1"."situacao_da_turma" IN ('CANCELADA', 'CRIADA', 'PUBLICADA')))) HAVING (COUNT(1) > 0);
-- file:with.sql ln:770 expect:true WITH t1 AS ( DELETE FROM bug6051 RETURNING * ) INSERT INTO bug6051 SELECT * FROM t1
<gh_stars>1-10 insert into positions(person, organization, title, start_date, start_date_precision, end_date, end_date_precision, urls, notes, employment_type, cause_area) values ('<NAME>','Wild-Animal Suffering Research','Executive Director','2017-06-01','month',NULL,NULL,'https://web.archive.org/web/20170720184841/https://was-research.org/about-us/team/ https://web.archive.org/web/20180914001622/https://was-research.org/team/ https://was-research.org/blog/biannual-project-evaluation-t1-2018/#Staff_time_investment https://was-research.org/blog/2017-retrospective/','Originally the position was called “Research Associate”.','full-time','Animal welfare') ,('<NAME>','Wild-Animal Suffering Research','Researcher','2017-06-01','month',NULL,NULL,'https://web.archive.org/web/20170720184841/https://was-research.org/about-us/team/ https://web.archive.org/web/20180914001622/https://was-research.org/team/ https://was-research.org/blog/biannual-project-evaluation-t1-2018/#Staff_time_investment https://was-research.org/blog/2017-retrospective/','Originally the position was called “Research Associate”.','part-time','Animal welfare') ,('<NAME>','Wild-Animal Suffering Research','Researcher','2017-09-28','month',NULL,NULL,'https://web.archive.org/web/20170928221832/https://was-research.org/about-us/team/ https://web.archive.org/web/20180914001622/https://was-research.org/team/ https://was-research.org/blog/biannual-project-evaluation-t1-2018/#Staff_time_investment https://was-research.org/blog/2017-retrospective/','Originally the position was called “Research Associate”.','part-time','Animal welfare') ,('<NAME>','Wild-Animal Suffering Research','Advisor','2017-06-01','month',NULL,NULL,'https://web.archive.org/web/20170720184841/https://was-research.org/about-us/team/ https://web.archive.org/web/20180914001622/https://was-research.org/team/',NULL,'advisor','Animal welfare') ,('<NAME>','Wild-Animal Suffering Research','Advisor','2017-06-01','month',NULL,NULL,'https://web.archive.org/web/20170720184841/https://was-research.org/about-us/team/ https://web.archive.org/web/20180914001622/https://was-research.org/team/',NULL,'advisor','Animal welfare') ,('<NAME>','Wild-Animal Suffering Research','Advisor','2017-06-01','month',NULL,NULL,'https://web.archive.org/web/20170720184841/https://was-research.org/about-us/team/ https://web.archive.org/web/20180914001622/https://was-research.org/team/',NULL,'advisor','Animal welfare') ,('<NAME>','Wild-Animal Suffering Research','Advisor','2017-06-01','month',NULL,NULL,'https://web.archive.org/web/20170720184841/https://was-research.org/about-us/team/ https://web.archive.org/web/20180914001622/https://was-research.org/team/',NULL,'advisor','Animal welfare') ,('<NAME>','Wild-Animal Suffering Research','External Review','2017-06-01','month','2017-09-28','month','https://web.archive.org/web/20170720184841/https://was-research.org/about-us/team/ https://web.archive.org/web/20170928221832/https://was-research.org/about-us/team/',NULL,'advisor','Animal welfare') ;
UPDATE creature_template SET ScriptName='spell_dummy_npc' WHERE entry=24918;
<reponame>pcmasuzzo/COVID-19_Sicilia<filename>risorse/query/andamentoPosititiviProvincia.sql WITH andamentoprovincia AS ( SELECT data, covid_19_sicilia_dati.sigla_provincia, covid_19_sicilia_dati.totale_positivi FROM covid_19_sicilia_dati ORDER BY DATA ) SELECT * FROM andamentoprovincia PIVOT (MAX(totale_positivi) FOR sigla_provincia IN ("AG","CL","CT","EN","ME","PA","RG","SR","TP")) ORDER BY data
<reponame>ed-quiroga-2103/Proyecto1Bases<gh_stars>0 INSERT INTO Items VALUES (251, 251, 1, 'Nice Wheels', 'Wheels', 45, 1, '2019-10-03'), (252, 252, 1, 'The best Skateboard', 'Skateboard', 120, 1, '2019-10-03'), (253, 253, 1, 'Amazing Shoes', 'Shoes', 80, 1, '2019-10-03'), (254, 254, 1, 'Nice Wheels', 'Wheels', 45, 1, '2019-10-03'), (255, 255, 1, 'The best Hat', 'Hat', 25, 1, '2019-10-03'), (256, 256, 1, 'The best Hat', 'Hat', 25, 1, '2019-10-03'), (257, 257, 1, 'Cool Pants', 'Pants', 40, 1, '2019-10-03'), (258, 258, 1, 'Amazing Board', 'Board', 60, 1, '2019-10-03'), (259, 259, 1, 'Amazing Board', 'Board', 60, 1, '2019-10-03'), (260, 260, 1, 'Amazing Board', 'Board', 60, 1, '2019-10-03'), (262, 262, 3, 'Amazing Board', 'Board', 60, 1, '2019-10-03'), (263, 263, 3, 'Cool Pants', 'Pants', 40, 1, '2019-10-03'), (264, 264, 3, 'Cool Bearings', 'Bearings', 25, 1, '2019-10-03'), (265, 265, 3, 'The best Skateboard', 'Skateboard', 120, 1, '2019-10-03'), (266, 266, 3, 'Cool Pants', 'Pants', 40, 1, '2019-10-03'), (267, 267, 3, 'Nice Shirt', 'Shirt', 25, 1, '2019-10-03'), (268, 268, 3, 'Fire Trucks', 'Trucks', 40, 1, '2019-10-03'), (269, 269, 3, 'Fire Trucks', 'Trucks', 40, 1, '2019-10-03'), (270, 270, 3, 'Nice Wheels', 'Wheels', 45, 1, '2019-10-03'), (271, 271, 3, 'Fire Trucks', 'Trucks', 40, 1, '2019-10-03'), (273, 273, 5, 'Cool Bearings', 'Bearings', 25, 1, '2019-10-03'), (274, 274, 5, 'Cool Bearings', 'Bearings', 25, 1, '2019-10-03'), (275, 275, 5, 'Cool Pants', 'Pants', 40, 1, '2019-10-03'), (276, 276, 5, 'Nice Shirt', 'Shirt', 25, 1, '2019-10-03'), (277, 277, 5, 'Cool Pants', 'Pants', 40, 1, '2019-10-03'), (278, 278, 5, 'Nice Shirt', 'Shirt', 25, 1, '2019-10-03'), (279, 279, 5, 'Amazing Board', 'Board', 60, 1, '2019-10-03'), (280, 280, 5, 'Nice Shirt', 'Shirt', 25, 1, '2019-10-03'), (281, 281, 5, 'Nice Wheels', 'Wheels', 45, 1, '2019-10-03'), (282, 282, 5, 'Nice Shirt', 'Shirt', 25, 1, '2019-10-03'), (284, 284, 7, 'Cool Bearings', 'Bearings', 25, 1, '2019-10-03'), (285, 285, 7, 'The best Hat', 'Hat', 25, 1, '2019-10-03'), (286, 286, 7, 'Nice Shirt', 'Shirt', 25, 1, '2019-10-03'), (287, 287, 7, 'The best Hat', 'Hat', 25, 1, '2019-10-03'), (288, 288, 7, 'The best Skateboard', 'Skateboard', 120, 1, '2019-10-03'), (289, 289, 7, 'Cool Pants', 'Pants', 40, 1, '2019-10-03'), (290, 290, 7, 'Amazing Shoes', 'Shoes', 80, 1, '2019-10-03'), (291, 291, 7, 'Amazing Shoes', 'Shoes', 80, 1, '2019-10-03'), (292, 292, 7, 'The best Hat', 'Hat', 25, 1, '2019-10-03'), (293, 293, 7, 'Amazing Board', 'Board', 60, 1, '2019-10-03'), (295, 295, 9, 'Nice Shirt', 'Shirt', 25, 1, '2019-10-03'), (296, 296, 9, 'Cool Bearings', 'Bearings', 25, 1, '2019-10-03'), (297, 297, 9, 'The best Hat', 'Hat', 25, 1, '2019-10-03'), (298, 298, 9, 'Nice Wheels', 'Wheels', 45, 1, '2019-10-03'), (299, 299, 9, 'Amazing Board', 'Board', 60, 1, '2019-10-03'), (300, 300, 9, 'Cool Pants', 'Pants', 40, 1, '2019-10-03'), (301, 301, 9, 'Amazing Shoes', 'Shoes', 80, 1, '2019-10-03'), (302, 302, 9, 'Nice Shirt', 'Shirt', 25, 1, '2019-10-03'), (303, 303, 9, 'Cool Bearings', 'Bearings', 25, 1, '2019-10-03'), (304, 304, 9, 'Fire Trucks', 'Trucks', 40, 1, '2019-10-03'), (306, 306, 11, 'The best Skateboard', 'Skateboard', 120, 1, '2019-10-03'), (307, 307, 11, 'Cool Bearings', 'Bearings', 25, 1, '2019-10-03'), (308, 308, 11, 'Cool Pants', 'Pants', 40, 1, '2019-10-03'), (309, 309, 11, 'Nice Shirt', 'Shirt', 25, 1, '2019-10-03'), (310, 310, 11, 'Fire Trucks', 'Trucks', 40, 1, '2019-10-03'), (311, 311, 11, 'Fire Trucks', 'Trucks', 40, 1, '2019-10-03'), (312, 312, 11, 'Nice Shirt', 'Shirt', 25, 1, '2019-10-03'), (313, 313, 11, 'Nice Shirt', 'Shirt', 25, 1, '2019-10-03'), (314, 314, 11, 'Cool Bearings', 'Bearings', 25, 1, '2019-10-03'), (315, 315, 11, 'Nice Wheels', 'Wheels', 45, 1, '2019-10-03'), (317, 317, 13, 'The best Hat', 'Hat', 25, 1, '2019-10-03'), (318, 318, 13, 'The best Hat', 'Hat', 25, 1, '2019-10-03'), (319, 319, 13, 'Nice Shirt', 'Shirt', 25, 1, '2019-10-03'), (320, 320, 13, 'Cool Pants', 'Pants', 40, 1, '2019-10-03'), (321, 321, 13, 'Amazing Board', 'Board', 60, 1, '2019-10-03'), (322, 322, 13, 'Cool Pants', 'Pants', 40, 1, '2019-10-03'), (323, 323, 13, 'Amazing Shoes', 'Shoes', 80, 1, '2019-10-03'), (324, 324, 13, 'Fire Trucks', 'Trucks', 40, 1, '2019-10-03'), (325, 325, 13, 'The best Hat', 'Hat', 25, 1, '2019-10-03'), (326, 326, 13, 'Cool Bearings', 'Bearings', 25, 1, '2019-10-03'), (328, 328, 15, 'The best Skateboard', 'Skateboard', 120, 1, '2019-10-03'), (329, 329, 15, 'Cool Pants', 'Pants', 40, 1, '2019-10-03'), (330, 330, 15, 'The best Skateboard', 'Skateboard', 120, 1, '2019-10-03'), (331, 331, 15, 'Fire Trucks', 'Trucks', 40, 1, '2019-10-03'), (332, 332, 15, 'Nice Wheels', 'Wheels', 45, 1, '2019-10-03'), (333, 333, 15, 'Nice Shirt', 'Shirt', 25, 1, '2019-10-03'), (334, 334, 15, 'Nice Shirt', 'Shirt', 25, 1, '2019-10-03'), (335, 335, 15, 'Nice Wheels', 'Wheels', 45, 1, '2019-10-03'), (336, 336, 15, 'Nice Wheels', 'Wheels', 45, 1, '2019-10-03'), (337, 337, 15, 'The best Hat', 'Hat', 25, 1, '2019-10-03'), (339, 339, 17, 'Amazing Board', 'Board', 60, 1, '2019-10-03'), (340, 340, 17, 'The best Skateboard', 'Skateboard', 120, 1, '2019-10-03'), (341, 341, 17, 'Cool Pants', 'Pants', 40, 1, '2019-10-03'), (342, 342, 17, 'Cool Bearings', 'Bearings', 25, 1, '2019-10-03'), (343, 343, 17, 'Fire Trucks', 'Trucks', 40, 1, '2019-10-03'), (344, 344, 17, 'Fire Trucks', 'Trucks', 40, 1, '2019-10-03'), (345, 345, 17, 'Nice Shirt', 'Shirt', 25, 1, '2019-10-03'), (346, 346, 17, 'Amazing Shoes', 'Shoes', 80, 1, '2019-10-03'), (347, 347, 17, 'Cool Bearings', 'Bearings', 25, 1, '2019-10-03'), (348, 348, 17, 'Nice Wheels', 'Wheels', 45, 1, '2019-10-03'), (350, 350, 19, 'Amazing Shoes', 'Shoes', 80, 1, '2019-10-03'), (351, 351, 19, 'Nice Wheels', 'Wheels', 45, 1, '2019-10-03'), (352, 352, 19, 'Cool Pants', 'Pants', 40, 1, '2019-10-03'), (353, 353, 19, 'Amazing Board', 'Board', 60, 1, '2019-10-03'), (354, 354, 19, 'Cool Pants', 'Pants', 40, 1, '2019-10-03'), (355, 355, 19, 'Nice Wheels', 'Wheels', 45, 1, '2019-10-03'), (356, 356, 19, 'Nice Wheels', 'Wheels', 45, 1, '2019-10-03'), (357, 357, 19, 'Amazing Shoes', 'Shoes', 80, 1, '2019-10-03'), (358, 358, 19, 'Fire Trucks', 'Trucks', 40, 1, '2019-10-03'), (359, 359, 19, 'Amazing Shoes', 'Shoes', 80, 1, '2019-10-03'), (361, 361, 21, 'Amazing Board', 'Board', 60, 1, '2019-10-03'), (362, 362, 21, 'Cool Pants', 'Pants', 40, 1, '2019-10-03'), (363, 363, 21, 'Amazing Shoes', 'Shoes', 80, 1, '2019-10-03'), (364, 364, 21, 'Nice Wheels', 'Wheels', 45, 1, '2019-10-03'), (365, 365, 21, 'Amazing Board', 'Board', 60, 1, '2019-10-03'), (366, 366, 21, 'Amazing Board', 'Board', 60, 1, '2019-10-03'), (367, 367, 21, 'Cool Bearings', 'Bearings', 25, 1, '2019-10-03'), (368, 368, 21, 'Nice Wheels', 'Wheels', 45, 1, '2019-10-03'), (369, 369, 21, 'Cool Bearings', 'Bearings', 25, 1, '2019-10-03'), (370, 370, 21, 'Amazing Board', 'Board', 60, 1, '2019-10-03'), (372, 372, 23, 'Amazing Shoes', 'Shoes', 80, 1, '2019-10-03'), (373, 373, 23, 'The best Skateboard', 'Skateboard', 120, 1, '2019-10-03'), (374, 374, 23, 'Fire Trucks', 'Trucks', 40, 1, '2019-10-03'), (375, 375, 23, 'Amazing Board', 'Board', 60, 1, '2019-10-03'), (376, 376, 23, 'Amazing Shoes', 'Shoes', 80, 1, '2019-10-03'), (377, 377, 23, 'Fire Trucks', 'Trucks', 40, 1, '2019-10-03'), (378, 378, 23, 'The best Skateboard', 'Skateboard', 120, 1, '2019-10-03'), (379, 379, 23, 'The best Hat', 'Hat', 25, 1, '2019-10-03'), (380, 380, 23, 'Fire Trucks', 'Trucks', 40, 1, '2019-10-03'), (381, 381, 23, 'The best Skateboard', 'Skateboard', 120, 1, '2019-10-03'), (383, 383, 25, 'Amazing Board', 'Board', 60, 1, '2019-10-03'), (384, 384, 25, 'Amazing Board', 'Board', 60, 1, '2019-10-03'), (385, 385, 25, 'Nice Shirt', 'Shirt', 25, 1, '2019-10-03'), (386, 386, 25, 'Nice Shirt', 'Shirt', 25, 1, '2019-10-03'), (387, 387, 25, 'Cool Bearings', 'Bearings', 25, 1, '2019-10-03'), (388, 388, 25, 'Amazing Board', 'Board', 60, 1, '2019-10-03'), (389, 389, 25, 'Cool Bearings', 'Bearings', 25, 1, '2019-10-03'), (390, 390, 25, 'Nice Wheels', 'Wheels', 45, 1, '2019-10-03'), (391, 391, 25, 'Amazing Board', 'Board', 60, 1, '2019-10-03'), (392, 392, 25, 'The best Hat', 'Hat', 25, 1, '2019-10-03');
<gh_stars>1-10 -- system_patches INSERT INTO `system_patches` (`issue`, `created`) VALUES('POCOR-3797', NOW()); -- competency_criterias RENAME TABLE `competency_criterias` TO `z_3797_competency_criterias`; DROP TABLE IF EXISTS `competency_criterias`; CREATE TABLE `competency_criterias` ( `id` int(11) NOT NULL AUTO_INCREMENT, `code` varchar(20) COLLATE utf8mb4_unicode_ci DEFAULT NULL, `name` varchar(250) COLLATE utf8mb4_unicode_ci NOT NULL, `academic_period_id` int(11) NOT NULL COMMENT 'links to academic_periods.id', `competency_item_id` int(11) NOT NULL COMMENT 'links to competency_items.id', `competency_template_id` int(11) NOT NULL COMMENT 'links to competency_templates.id', `competency_grading_type_id` int(11) NOT NULL COMMENT 'links to competency_grading_types.id', `modified_user_id` int(11) DEFAULT NULL, `modified` datetime DEFAULT NULL, `created_user_id` int(11) NOT NULL, `created` datetime NOT NULL, PRIMARY KEY (`id`,`academic_period_id`,`competency_item_id`,`competency_template_id`), KEY `id` (`id`), KEY `academic_period_id` (`academic_period_id`), KEY `competency_item_id` (`competency_item_id`), KEY `competency_template_id` (`competency_template_id`), KEY `competency_grading_type_id` (`competency_grading_type_id`), KEY `modified_user_id` (`modified_user_id`), KEY `created_user_id` (`created_user_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='This table contains the list of competency criterias for a given competency item'; INSERT INTO `competency_criterias` (`id`, `code`, `name`, `academic_period_id`, `competency_item_id`, `competency_template_id`, `competency_grading_type_id`, `modified_user_id`, `modified`, `created_user_id`, `created`) SELECT `id`, NULL, `name`, `academic_period_id`, `competency_item_id`, `competency_template_id`, `competency_grading_type_id`, `modified_user_id`, `modified`, `created_user_id`, `created` FROM `z_3797_competency_criterias`;
<reponame>andreylipattsev/almanac.httparchive.org<filename>sql/2021/security/cookie_max_age_expires_top_values.sql #standardSQL # Top 10 values of Max-Age and Expires cookie attributes. CREATE TEMPORARY FUNCTION getCookieAgeValues(headers STRING, epochOfRequest NUMERIC) RETURNS STRING DETERMINISTIC LANGUAGE js AS ''' const regexMaxAge = new RegExp(/max-age\\s*=\\s*(?<value>-*[0-9]+)/i); const regexExpires = new RegExp(/expires\\s*=\\s*(?<value>.*?)(;|$)/i); const parsed_headers = JSON.parse(headers); const cookies = parsed_headers.filter(h => h.name.match(/set-cookie/i)); const cookieValues = cookies.map(h => h.value); const result = { "maxAge": [], "expires": [] }; cookieValues.forEach(cookie => { let maxAge = null; let expires = null; if (regexMaxAge.exec(cookie)) { maxAge = Number(regexMaxAge.exec(cookie)[1]); result["maxAge"].push(maxAge); } if (regexExpires.exec(cookie)) { expires = regexExpires.exec(cookie)[1]; result["expires"].push(expires); } }); return JSON.stringify(result); '''; WITH max_age_values AS ( SELECT client, max_age_value FROM `httparchive.almanac.requests`, UNNEST(JSON_QUERY_ARRAY(getCookieAgeValues(response_headers, startedDateTime), "$.maxAge")) AS max_age_value WHERE date = "2021-07-01" ), expires_values AS ( SELECT client, expires_value FROM `httparchive.almanac.requests`, UNNEST(JSON_QUERY_ARRAY(getCookieAgeValues(response_headers, startedDateTime), "$.expires")) AS expires_value WHERE date = "2021-07-01" ), max_age AS ( SELECT client, "max-age" AS type, total_cookies_with_max_age AS total, COUNT(0) AS freq, COUNT(0) / total_cookies_with_max_age AS pct, max_age_value AS attribute_value FROM max_age_values JOIN ( SELECT client, COUNT(0) AS total_cookies_with_max_age FROM max_age_values GROUP BY client ) USING (client) GROUP BY client, total, attribute_value ORDER BY freq DESC LIMIT 50 ), expires AS ( SELECT client, "expires" AS type, total_cookies_with_expires AS total, COUNT(0) AS freq, COUNT(0) / total_cookies_with_expires AS pct, expires_value AS attribute_value FROM expires_values JOIN ( SELECT client, COUNT(0) AS total_cookies_with_expires FROM expires_values GROUP BY client ) USING (client) GROUP BY client, total, attribute_value ORDER BY freq DESC LIMIT 50 ) SELECT * FROM max_age UNION ALL SELECT * FROM expires ORDER BY client, type, freq DESC
<reponame>mmci2468/automate -- Revert user_cache BEGIN; DROP TABLE IF EXISTS user_cache; COMMIT;
-- created 2013-01-08 -- This file contains the mw_location_pcr table, which was originally created as tbl_location_pcr and then renamed to mw_location_pcr -- but due to a bug it may not be created by previous SQL scripts correctly CREATE TABLE `mw_location_pcr` ( `ID` int(11) NOT NULL AUTO_INCREMENT, `location` varchar(200) NOT NULL, `pcr_value` varchar(100) NOT NULL, PRIMARY KEY (`ID`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1 COMMENT='Mapping between the pcr values and location'; INSERT INTO `mw_changelog` (`ID`, `APPLIED_AT`, `DESCRIPTION`) VALUES (20130108232900,NOW(),'premium - patch for 1.1 adding mw_location_pcr table');