sql
stringlengths
6
1.05M
<reponame>calebschoepp/playlist-rotator CREATE EXTENSION IF NOT EXISTS "uuid-ossp"; CREATE TABLE users ( id UUID PRIMARY KEY DEFAULT uuid_generate_v4(), spotify_id TEXT NOT NULL, playlists_built INTEGER NOT NULL, session_token VARCHAR(128), session_expiry TIMESTAMPTZ, access_token TEX...
-- phpMyAdmin SQL Dump -- version 4.5.1 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: Sep 22, 2019 at 06:07 AM -- Server version: 10.1.10-MariaDB -- PHP Version: 7.0.3 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLI...
# --- Created by Ebean DDL # To stop Ebean DDL generation, remove this comment and start using Evolutions # --- !Ups create table score ( id bigint not null, name varchar(255), score bigint, constraint pk_score primary key (id)) ; create se...
<filename>SQL/SQL_exercise_02/2_questions_and_solution.sql -- LINK : https://en.wikibooks.org/wiki/SQL_Exercises/Employee_management -- 2.1 Select the last name of all employees. select LastName from Employees; -- 2.2 Select the last name of all employees, without duplicates. select distinct LastName from employees;...
DELIMITER $$ CREATE DEFINER=`root`@`%` PROCEDURE `GetTransactionTypeName`( IN typeID INT, OUT typeName VARCHAR(35)) BEGIN SELECT name INTO typeName FROM transaction_types WHERE id = typeID; END$$ DELIMITER ; DELIMITER $$ CREATE DEFINER=`root`@`%` PROCEDURE `ProcessUserTransaction`( IN t...
<reponame>irooit/sspanel /* Navicat Premium Data Transfer Source Server : 亚马逊美西 Source Server Type : MySQL Source Server Version : 50641 Source Host : rooit.c6xbwtcnposp.us-west-1.rds.amazonaws.com:3306 Source Schema : shadow Target Server Type : MySQL Target Server Version : 5...
drop table if exists gh_ost_test; create table gh_ost_test ( id int auto_increment, create_time timestamp NULL DEFAULT '0000-00-00 00:00:00', update_time timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, counter int(10) unsigned DEFAULT NULL, primary key(id) ) auto_increment=1; insert int...
<reponame>canavdan/Gagful INSERT INTO `roles` (`id`, `created_date`,`last_modified_date`,`name`) VALUES ('1role', '2020-04-02 15:19:41.607000', '2020-04-02 15:19:41.607000', 'Admin') INSERT INTO `roles` (`id`, `created_date`,`last_modified_date`,`name`) VALUES ('2role', '2020-04-02 15:19:41.607000', '2020-04-02 15:19:4...
CREATE TABLE [dbo].[LocalAuthorityGroupMembership] ( [LocalAuthorityID] INT NOT NULL, [LocalAuthorityGroupID] INT NOT NULL, CONSTRAINT [PK_LocalAuthorityGroupMembership] PRIMARY KEY CLUSTERED ([LocalAuthorityID] ASC, [LocalAuthorityGroupID] ASC), CONSTRAINT [FK_LAGroupMembership_LAGroup] FOREIGN K...
-- phpMyAdmin SQL Dump -- version 5.1.1 -- https://www.phpmyadmin.net/ -- -- Host: 1172.16.17.32 -- Generation Time: Oct 06, 2021 at 04:33 AM -- Server version: 10.4.21-MariaDB -- PHP Version: 7.3.31 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_...
<reponame>keithbabinec/Archivial<filename>ArchivialDB/FullText/ArchivialFtsCatalog.sql CREATE FULLTEXT CATALOG [ArchivialFtsCatalog]
<reponame>PepperJo/jdbc_fdw -- -- postgreSql -- INSERT -- \set ECHO none \ir sql/configs/postgresql_parameters.conf \set ECHO all \i sql/14.0/insert.sql
SET SERVEROUTPUT ON / CLEAR SCREEN / DECLARE CONN UTL_TCP.CONNECTION; RETVAL BINARY_INTEGER; L_RESPONSE VARCHAR2(1000) := ''; L_TEXT VARCHAR2(1000); BEGIN --Deschidem conexiunea... CONN := UTL_TCP.OPEN_CONNECTION( REMOTE_HOST => '127.0.0.1', ...
ALTER TABLE `m_loan` ADD COLUMN `irr`decimal(19,6) DEFAULT NULL;
CREATE TABLE scm_contact_point( seq BIGINT AUTO_INCREMENT PRIMARY KEY, /** * type: org.kyojo.schemaorg.m3n3.core.Container$AdditionalType * param: org.kyojo.schemaorg.m3n3.core.Clazz$URL */ additional_type VARCHAR(100) NULL, /** * type: org.kyojo.schemaorg.m3n3.core.Container$AlternateName * param: or...
CREATE TABLE project ( name VARCHAR(32), description text, orgURL VARCHAR(256), logo text, PRIMARY KEY(name) );
-- +migrate Up ALTER TABLE hydra_oauth2_access ADD requested_audience TEXT NULL; UPDATE hydra_oauth2_access SET requested_audience=''; ALTER TABLE hydra_oauth2_access MODIFY requested_audience TEXT NOT NULL; ALTER TABLE hydra_oauth2_access ADD granted_audience TEXT NULL; UPDATE hydra_oauth2_access SET granted_audience=...
-- Table SENTRY_PERM_CHANGE for classes [org.apache.sentry.provider.db.service.model.MSentryPermChange] CREATE TABLE SENTRY_PERM_CHANGE ( CHANGE_ID BIGINT NOT NULL, CREATE_TIME_MS BIGINT NOT NULL, PERM_CHANGE VARCHAR(4000) NOT NULL ); ALTER TABLE SENTRY_PERM_CHANGE ADD CONSTRAINT SENTRY_PERM_CHANGE_PK PRIM...
create table helm_tag_formats( id uuid primary key default uuid_generate_v4(), created_at timestamptz not null default now(), pattern varchar unique not null ); create trigger notify_changes after insert or update or delete on helm_tag_formats for each row execute procedure notify_trigger('id'); alter table hel...
SELECT CONVERT(nvarchar(14), sls.SourceServer) AS SourceServer , CONVERT(nvarchar(16), sls.DestinationServer) AS DestinationServer , sls.LastUpdate FROM t_server s JOIN SQLLinkedServers sls ON s.server_name = sls.DestinationServer WHERE s.active = '0' ORDER BY 1, 2 SELECT ServerName...
select distinct `X509v3 extensions:Netscape CA Revocation Url` from valid_certs into outfile '/tmp/ns_ca_crls.txt' select distinct `X509v3 extensions:Netscape Revocation Url` from valid_certs into outfile '/tmp/ns_crls.txt';
<filename>flyway-lihongjie/db_flyway_sample/src/main/resources/flyway/migrations/release_2/V2_1__create_test_index.sql CREATE INDEX flyway_test_idx ON flyway_test USING btree(value);
<filename>fdb-sql-layer-core/src/test/resources/com/foundationdb/sql/optimizer/rule/operator/insert-1.sql INSERT INTO child(pid, id, name) VALUES(1, 1, 'Judy'),(1, 2, 'Elroy')
CREATE TABLE CPIC ( ID INT NOT NULL IDENTITY (1,1), Code NVARCHAR(255) NOT NULL, CostAreaCode NVARCHAR(255) NULL, CostAreaName NVARCHAR(255) NULL, ProjectCode NVARCHAR(255) NULL, ProjectName NVARCHAR(255) NULL );
--DB Table schema CREATE TABLE account( login VARCHAR(30) PRIMARY KEY, createdAt TIMESTAMP NOT NULL, email VARCHAR(100) NOT NULL, userPass BYTEA NOT NULL ); CREATE TABLE posts( id SERIAL8 PRIMARY KEY, title VARCHAR(150) NOT NULL, createdAt TIMESTAMP NOT NULL, userLogin VARCHAR(30) NOT NULL, bo...
<filename>io-lbapp/server/scripts/install/mariadb.sql<gh_stars>0 /* * * INSTALLATION SCRIPT FOR MARIADB * */ /* PLEASE UPDATE USERNAME AND PASSWORD */ CREATE USER 'db_username'@'localhost' IDENTIFIED BY 'db_password'; /* PLEASE REPLACE DATABASE NAME */ CREATE DATABASE IF NOT EXISTS `db_database` CHARACTER SET = '...
SELECT sender_public_key, asset, version FROM transactions WHERE TYPE = ${type} ORDER BY timestamp DESC, sequence ASC
<gh_stars>1-10 BEGIN; ALTER TABLE sessions DROP CONSTRAINT join_id_unique; COMMIT;
<reponame>pofider/jsreport-oracle-store ALTER SESSION SET CONTAINER = XEPDB1; create user JSREPORT identified by jsreport default tablespace users temporary tablespace temp; alter user JSREPORT quota unlimited on users; grant create session to JSREPORT; grant create table to JSREPORT; grant create any index to JSREPOR...
CREATE DATABASE bd_estados; use bd_estados; -- tabela de users CREATE TABLE IF NOT EXISTS `bd_estados`.`users` ( `id` INT(11) NOT NULL AUTO_INCREMENT, `nome` VARCHAR(50) NOT NULL, `email` VARCHAR(30) NOT NULL, `senha` VARCHAR(100) NOT NULL, `permissao` INT(11) NULL DEFAULT NULL, `remember_token` VARCHAR(25...
CREATE TABLE casbin_rule ( id int UNSIGNED AUTO_INCREMENT PRIMARY KEY, ptype varchar(100) NULL, v0 varchar(100) NULL, v1 varchar(100) NULL, v2 varchar(100) NULL, v3 varchar(100) NULL, v4 varchar(100) NULL, v5 varchar(100) NULL, CONSTRAINT idx_casbin_rule UNIQUE (...
CREATE OR REPLACE PROCEDURE add_session(p_login Konta.login%TYPE, p_haslo Konta.haslo%TYPE, p_token sesje.token%TYPE) IS osoba_id osoby.nr_osoby%TYPE; count_ac NUMERIC; count_ses NUMERIC; BEGIN SELECT COUNT(id_konta) INTO count_ac FROM Konta WHERE login=p_login and haslo=p_haslo; SELECT COU...
ALTER TABLE BUDGET_SUB_AWARDS MODIFY SUB_AWARD_XML_FILE LONGTEXT NULL;
ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY '<PASSWORD>!'; flush privileges; DROP DATABASE IF EXISTS employeesDB; CREATE DATABASE employeesDB; USE employeesDB; CREATE TABLE department ( id INT AUTO_INCREMENT, department_name VARCHAR(30), PRIMARY KEY (id) ); INSERT INTO departme...
--clear data TRUNCATE TABLE core.structure CASCADE; ALTER SEQUENCE core.structure_id_seq RESTART WITH 6; ALTER SEQUENCE core.structure_metadata_id_seq RESTART WITH 6; INSERT INTO core.structure (id, json) VALUES (1, '{"id": "90397", "type": "Feature", "geometry": {"type": "Polygon", "coordinates": [[[32.5978597, -14...
<gh_stars>0 create table if not exists IPCountryMap( id bigint GENERATED BY DEFAULT AS IDENTITY (START WITH 1, INCREMENT BY 1) NOT NULL, createdDate datetime not null, modifiedDate datetime not null, ipAddress varchar(45) NOT NULL UNIQUE, countryCode varchar(2) NOT NULL, version bigint not null, PRIMARY ...
SET NAMES utf8mb4; SET FOREIGN_KEY_CHECKS = 0; CREATE TABLE `undo_log` ( `id` bigint(20) NOT NULL AUTO_INCREMENT, `branch_id` bigint(20) NOT NULL, `xid` varchar(100) NOT NULL, `context` varchar(128) NOT NULL, `rollback_info` longblob NOT NULL, `log_status` int(11) NOT NULL, `log_created` datetime NOT NULL...
-- Dato un id = 4 di una risorsa mostrare i suoi figli, esclusa se stessa WITH RECURSIVE tree AS ( SELECT resource.id FROM resource WHERE id = 4 UNION ALL SELECT r.id FROM resource r JOIN tree p ON p.id = r.parent ) SELECT * FROM tree WHERE id != 4; -- Selezionare tutte le risorse che hanno almeno 1 allegato ...
<reponame>greenvilleassociates/fusionshellplus CREATE TABLE /*_*/log_search ( -- The type of ID (rev ID, log ID, rev timestamp, username) ls_field varbinary(32) NOT NULL, -- The value of the ID ls_value varchar(255) NOT NULL, -- Key to log_id ls_log_id int unsigned NOT NULL default 0 ) /*$wgDBTableOptions*/...
-- TODO: can't just remove default prefix, it breaks the test! drop database if exists db_01080; create database db_01080; drop table if exists db_01080.test_table_01080; CREATE TABLE db_01080.test_table_01080 (dim_key Int64, dim_id String) ENGINE = MergeTree Order by (dim_key); insert into db_01080.test_table_01080 ...
/** used in tests that use MYSQL **/ CREATE TABLE oauth_client_details ( client_id VARCHAR(128) PRIMARY KEY, resource_ids VARCHAR(128), client_secret VARCHAR(128), scope VARCHAR(128), authorized_grant_types VARCHAR(128), web_server_redirect_uri VARCHAR(128), authorities VARCHAR(128), access_token_valid...
<reponame>elementary-data/dbt-data-reliability {% macro data_type_list(data_type) %} {% set result = adapter.dispatch('data_type_list','elementary')(data_type) %} {{ return(result) }} {% endmacro %} {% macro default__data_type_list(data_type) %} {% set string_list = ['character varying','varchar','charact...
CREATE INDEX ON public.t1 (c1); CREATE UNIQUE INDEX ON public.t1 (c1); CREATE INDEX ON public.t1 (c1); CREATE INDEX CONCURRENTLY ON public.t1 (c1); CREATE INDEX i1 ON public.t1 (c1); CREATE INDEX IF NOT EXISTS i1 ON public.t1 (c1); CREATE INDEX ON ONLY public.t1 (c1); CREATE INDEX ON public.t1 USING btree (c1); CREATE ...
<filename>sql/_06_manipulation/_01_select/_002_outer_join/cases/1013.sql --test outer join using correlated index --it tests out join using correlated index and /*+ USE_IDX */ * create class tbl (a int, b int); insert into tbl values (1, 1); insert into tbl values (2, NULL); create index i_tbl_a_b on tbl (a, b); sel...
--addition in late binding using enum type --+ holdcas on; set names iso88591; drop table if exists t1; create table t1 (e1 enum('A','B') collate utf8_bin); show full columns from t1; create table t2 (s varchar(255) collate iso88591_bin); show full columns from t2; insert into t2 values ('A'), ('B'); select * from ...
CREATE TABLE [dbo].[R2PBParametro]( [IdParametro] [int] IDENTITY(1,1) NOT NULL, [IdMetodo] [int] NOT NULL, [Nombre] [varchar](50) NOT NULL, [Tipo] [varchar](50) NOT NULL, [Estatico] [bit]NOT NULL, CONSTRAINT [PK_R2PBParametro] PRIMARY KEY CLUSTERED ( [IdParametro] ASC )WITH (PAD_INDEX = OFF, STATISTICS_NORECO...
/* SQL in this file will only be executed by the release pipeline in the QA environment. */
<gh_stars>0 ALTER TABLE `paymill_fastcheckout` CHANGE `userID` `oxid` VARCHAR( 100 ) CHARACTER SET latin1 COLLATE latin1_general_ci NOT NULL;
<gh_stars>0 -- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Máy chủ: 127.0.0.1 -- Thời gian đã tạo: Th7 24, 2020 lúc 12:09 PM -- Phiên bản máy phục vụ: 10.4.11-MariaDB -- Phiên bản PHP: 7.4.6 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SE...
---------------------------Queries and Views---------------------------------- --Show all marriages in Ireland with the date and place of marriage SELECT L.Country, V.PlaceOfMarriage, M.DateOfWedding From Location L INNER JOIN Venue V ON V.VenueAddress = L.LocationID INNER JOIN Marriage M ON V.VenueID = M.MarriageV...
<filename>Scripts/RunningQueries.sql SET QUOTED_IDENTIFIER ON GO SET ANSI_NULLS ON GO --============================================= -- Copyright (C) 2018 <NAME>, @SQLDoubleG -- All rights reserved. -- -- You may alter this code for your own *non-commercial* purposes. You may -- republish altered code as long as yo...
<reponame>naveenkod22/MySQL -- 12.26 crating and dropping tables use sql_store2; create table if not exists customers ( customer_id int primary key auto_increment, fitst_name varchar(50) not null, point int not null default 0, email varchar(255) not null unique ); -- droping drop table if exists customers;
-- ============================================= -- Author: <NAME>, <NAME>, <NAME> -- Create date: 10/20/2017 -- Description: 1.0 with Soft Deletion -- ============================================= DELIMITER $$ DROP PROCEDURE IF EXISTS `risk_calculation_V1`$$ CREATE DEFINER = `synapsemaster`@`%` PROCEDURE `risk_c...
<filename>database/lelang.sql -- phpMyAdmin SQL Dump -- version 5.0.4 -- https://www.phpmyadmin.net/ -- -- Host: 1172.16.31.10 -- Generation Time: Jul 02, 2021 at 03:47 PM -- Server version: 10.4.17-MariaDB -- PHP Version: 8.0.1 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!...
<filename>Banco/ViewEProcedure.sql use mydb; create view VW_CONSULTA_GERAL as select f.nome,f.matricula,f.email,f.ramal,s.descricao as Setor,fun.descricao as Função, t.descricao as Turno from funcionario f inner join setor s on s.codigo_setor =f.FK_SETOR inner join funcao fun on fun.codigo_funcao = f.FK_FU...
<gh_stars>1-10 CREATE SCHEMA [aspnet_Membership_ReportingAccess] AUTHORIZATION [WowMacroEditorUser];
IF NOT EXISTS (SELECT * FROM sys.columns WHERE name = 'IsContributor' AND object_id = OBJECT_ID('dbo.UserAccount')) ALTER TABLE dbo.UserAccount ADD IsContributor bit NOT NULL CONSTRAINT DF_UserAccount_IsContributor DEFAULT (0); IF EXISTS (SELECT * FROM sys.default_constraints WHERE name = 'DF_UserAccount_IsContribu...
<filename>src/Novosga/Install/sql/migration/1.4.0.sql ALTER TABLE uni_serv DROP COLUMN nome; CREATE TABLE uni_meta ( unidade_id integer NOT NULL, name varchar(50) NOT NULL, value TEXT , PRIMARY KEY (unidade_id, name), FOREIGN KEY (unidade_id) REFERENCES unidades (id) ); CREATE TABLE se...
-- Table: public.Venta -- DROP TABLE public."Venta"; CREATE TABLE IF NOT EXISTS public."Venta" ( "IdVenta" character varying(40) COLLATE pg_catalog."default" NOT NULL, "IdTrabajador" character varying(10) COLLATE pg_catalog."default" NOT NULL, "PrecioTotal" integer NOT NULL, "FechaVenta" date NOT NULL...
/* You'll now explore using two consecutive full joins on the three tables you worked with in the previous two exercises. */ /* Instructions Complete a full join with countries on the left and languages on the right. Next, full join this result with currencies on the right. Select the fields corresponding to the count...
CREATE or alter PROCEDURE CreateRandomString @randomString VARCHAR(16) OUTPUT AS BEGIN SET NOCOUNT ON; DECLARE @stringLength INT =16; DECLARE @chars VARCHAR(200) = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'; SET @randomString = ''; WHILE LEN(@randomString) < @stringLength BEGIN SET @randomString = @ra...
<filename>td/krux-output/scripts/combine.sql<gh_stars>10-100 SELECT kuid AS user_id, ARRAY_JOIN(ARRAY_DISTINCT(ARRAY_AGG(segment_name)), ',') AS td_segment FROM tmp_unioned_segments GROUP BY kuid
/* Warnings: - The primary key for the `commentonhashtag` table will be changed. If it partially fails, the table could be left without primary key constraint. - You are about to drop the column `hashtagId` on the `commentonhashtag` table. All the data in the column will be lost. - The primary key for the `con...
SET @sName = 'bx_developer';
USE [perpetuumsa] GO ---------------------------------------------------------------------------- --PitBoss Live Tweaks: v1 --Changes: more dps, faster lock, blinder, misc tweaks on other modifiers -- --Last modified: 2019/07/13 ---------------------------------------------------------------------------- PRINT N'Bli...
-- 2017-10-09T14:56:56.450 -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator UPDATE AD_Field_Trl SET UpdatedBy=100,Updated=TO_TIMESTAMP('2017-10-09 14:56:56','YYYY-MM-DD HH24:MI:SS'),Name='Date' WHERE AD_Field_ID=10425 AND AD_Language='en_US' ; -- 2017-10-09T14:58:13.697 -- I forgot to set the DICTIONA...
<reponame>dram/metasfresh<gh_stars>1000+ -- 2020-02-20T15:16:56.442Z -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator UPDATE AD_Process SET SQLStatement='select * from customerItemStatistics(@AD_Client_ID@, @AD_Org_ID@, ''@DateFrom/1900-01-01@''::date , ''@DateTo/9999-12-31@''::date , @C_BPartner_ID/-1...
-- 2.车辆基本信息表 use car_rental_sys_db; create table car_info ( id char(32) PRIMARY KEY, model_info_id char(32) NOT NULL, car_no char(8) NOT NULL UNIQUE, car_color char(4) NOT NULL, car_buy_date date, car_engine_no char(8) NOT NULL, car_frame_no char(8) NOT NULL, car_status boolean, car_store_id char(32) NOT NULL...
DELETE FROM `sys_account_custom_stat_elements` WHERE `Label` = '_bx_groups'; INSERT INTO `sys_account_custom_stat_elements` VALUES(NULL, '_bx_groups', '__bx_groups__ (<a href="modules/?r=groups/browse/my&bx_groups_filter=add_group">__l_add__</a>)'); -- update module version UPDATE `sys_modules` SET `version...
<reponame>simhnna/sourcegraph -- +++ -- parent: 1528395893 -- +++ -- This speeds up IterateRepoGitserverStatus CREATE INDEX CONCURRENTLY IF NOT EXISTS gitserver_repos_shard_id ON gitserver_repos(shard_id, repo_id);
with active_volume as ( select *, DATE_TRUNC(date(measured_at), month) as measured_month from {{ ref('stg_fivetran_log_active_volume') }} where schema_name != 'fivetran_log' -- it's free! ), connector as ( select * from {{ ref('stg_fivetran_log_connector') }} ), destinatio...
<filename>courier/src/main/resources/schema.sql<gh_stars>0 -- create table users CREATE TABLE users ( id SERIAL PRIMARY KEY, login VARCHAR(25) NOT NULL, password VARCHAR(100) NOT NULL, name VARCHAR(25) DEFAULT 'name', surname VARCHAR(25) DEFAULT 'surname', money FLOAT(2) DEFAULT 0 CONSTRAINT positive_money ...
<filename>postgres.sql -- -- PostgreSQL database dump -- -- Dumped from database version 9.6.10 -- Dumped by pg_dump version 9.6.10 SET statement_timeout = 0; SET lock_timeout = 0; SET idle_in_transaction_session_timeout = 0; SET client_encoding = 'UTF8'; SET standard_conforming_strings = on; SELECT pg_catalog.set_co...
<reponame>b-0-x/steampipe-mod-azure-compliance with logging_details as ( select distinct a.id as vm_scale_set_id from azure_compute_virtual_machine_scale_set as a, jsonb_array_elements(extensions) as b where (b ->> 'Publisher' = 'Microsoft.Azure.Diagnostics' and b ->> 'ExtensionType' = 'IaaSDi...
-- Copyright 2018 <NAME>. All rights reserved. More info at http://tanelpoder.com -- Licensed under the Apache License, Version 2.0. See LICENSE.txt for terms & conditions. -- DROP TABLE tbb; -- DROP SEQUENCE tbb_seq; -- -- CREATE SEQUENCE tbb_seq NOCACHE; -- -- CREATE TABLE tbb ( -- id NUMBER PRIMARY K...
DROP MATERIALIZED VIEW IF EXISTS mv_update_by_job; DROP TABLE IF EXISTS update_info;
DO $$ BEGIN IF register_patch('SetAuthFeature.sql', '<NAME>', 'Set STFC auth to enabled', '2021-02-23') THEN BEGIN INSERT INTO features(feature_id, description) VALUES ('EXTERNAL_AUTH', 'STFC Authentication'); END; END IF; END; $$ LANGUAGE plpgsql;
-- phpMyAdmin SQL Dump -- version 4.0.10deb1 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: Mar 15, 2018 at 08:46 AM -- Server version: 5.5.50-0ubuntu0.14.04.1 -- PHP Version: 5.6.31-6+ubuntu14.04.1+deb.sury.org+1 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET ...
DROP DATABASE IF EXISTS employeeTracker_db; CREATE DATABASE employeeTracker_db; USE employeeTracker_db; CREATE TABLE department ( id INT AUTO_INCREMENT PRIMARY KEY NOT NULL, department_name VARCHAR(30) NULL ); CREATE TABLE role ( id INT AUTO_INCREMENT PRIMARY KEY NOT NULL, title VARCHAR(30) NULL, ...
<gh_stars>0 -- phpMyAdmin SQL Dump -- version 4.1.12 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: Apr 08, 2015 at 02:14 AM -- Server version: 5.6.16 -- PHP Version: 5.5.11 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SE...
drop table if exists settings;
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1:3306 -- Generation Time: Mar 02, 2022 at 02:45 PM -- Server version: 10.4.13-MariaDB -- PHP Version: 7.2.31 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET...
START TRANSACTION; CREATE TABLE audit ( id uuid NOT NULL, account uuid NOT NULL, action text NOT NULL, created_on timestamp with time zone NOT NULL, action_account uuid, action_cluster uuid, action_deployment uuid, action_namespace uuid, action_release uuid, action_service uuid,...
DELIMITER $$ CREATE DEFINER=`root`@`%` PROCEDURE `user_stats`( IN userId INT(11), sessionId INT(11), todayOnline INT(11), totalOnline INT(11), specOnline INT(11), playOnline INT(11), userName VARCHAR(32) ) SQL SECURITY INVOKER BEGIN /* UPDATE dxg_users */ UPDATE `np_users` SET l...
<filename>security_metrics/sm_homepage.sql /* This is the project website security metric. If no website has been identified then the project recieves 1 point. We weight this very low because our data sources often fail to identify websites even when they exist. */ DROP TABLE IF EXISTS sm_homepage; \...
<reponame>irsyadhani/FP-PBKK_B -- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Jul 05, 2021 at 07:40 AM -- Server version: 10.4.11-MariaDB -- PHP Version: 7.4.6 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!401...
<filename>db.sql CREATE DATABASE cups DEFAULT CHARACTER SET utf8 ; USE cups; CREATE TABLE categorias ( id INT NOT NULL AUTO_INCREMENT, nome VARCHAR(45) NOT NULL, created_at TIMESTAMP NULL, updated_at TIMESTAMP NULL, PRIMARY KEY (id)); INSERT INTO categorias (nome,created_at,updated_at) VALUES ('Programação'...
<reponame>tied/innovation-funding-service INSERT INTO activity_state VALUES (59, 'PROJECT_SETUP_PAYMENT_MILESTONES', 'NOT_VERIFIED'); INSERT INTO activity_state VALUES (60, 'PROJECT_SETUP_PAYMENT_MILESTONES', 'ACCEPTED');
<gh_stars>1-10 create or replace table `dataline-integration-testing`.test_normalization.`conflict_stream_name` OPTIONS() as ( with __dbt__CTE__conflict_stream_name_ab1 as ( -- SQL model to parse JSON blob stored in a single column and extract into separated field columns as described by the JSON Sc...
<reponame>albugrimenko/PerfMon USE PerfmonE GO print '--- Loading static data ---' GO exec [tools_SetUpDimentions] GO exec [tools_SetUpLookups] GO print '--- Loading static data: data loaded. ---' GO USE [master] GO ALTER DATABASE [PerfmonE] SET READ_WRITE GO
-- randexpr1.test -- -- db eval {SELECT f+coalesce((select case when ~case when coalesce((select max(b) from t1 where not exists(select 1 from t1 where 11*t1.b>case t1.b when 13 then 11 else b end)),t1.b) not in (a,b,+t1.e | case when t1.a<>17 then 17 else t1.e end) then c when (t1.e)<>d then 11 else f end*(e) not bet...
--1.List the following details of each employee: employee number, last name, first name, sex, and salary Select e.emp_no as "employee number", e.last_name as "last name", e.first_name as "first name", e.sex, s.salary from "Employees" as e inner join "Salaries" as s on e.emp_no = s.emp_no; --2.List first n...
<reponame>tatianegercina/FinTech<filename>01-Lesson-Plans/07-SQL/2/Activities/05-Stu_Order_By/Solved/query.sql -- Find the count of payments per customer in descending order SELECT customer_id, COUNT(*) AS payment_count FROM payment GROUP BY customer_id ORDER BY COUNT(*) DESC; -- Find the top 5 customers who have spe...
<reponame>dram/metasfresh -- 2017-08-24T09:08:57.203 -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator INSERT INTO AD_Table_Process (AD_Client_ID,AD_Org_ID,AD_Process_ID,AD_Table_ID,Created,CreatedBy,EntityType,IsActive,Updated,UpdatedBy,WEBUI_QuickAction,WEBUI_QuickAction_Default) VALUES (0,0,194,533,T...
-- -- acs-workflow/sql/workflow-package-head.sql -- -- Creates the PL/SQL package that provides the API for defining and dropping -- workflow cases. -- -- @author <NAME> (<EMAIL>) -- -- @creation-date 2000-05-18 -- -- @cvs-id $Id: workflow-package.sql,v 1.1.1.1 2005/04/27 22:50:59 cvs Exp $ -- @@workflow-package-head....
CREATE INDEX ID_Customer ON tbl_RefundGoods ( [AgentID] ASC , [CustomerID] ASC , [CreatedDate] DESC ) ;
CREATE SCHEMA `MCPUBS` ; CREATE TABLE `Pub` ( `id` int(11) NOT NULL AUTO_INCREMENT, `fullCode` varchar(70) NOT NULL COMMENT '4200.43 or 3-12', `rootCode` varchar(10) NOT NULL COMMENT '4200 or 3-12', `code` int(11) DEFAULT NULL COMMENT '43 or null', `version` varchar(5) DEFAULT NULL COMMENT 'B or ...
<reponame>Bus-Data-NYC/inferno INSERT INTO gtfs.agency ("feed_index","agency_timezone") VALUES (7, 'America/New_York'), (23, 'America/New_York'), (65, 'America/New_York'); INSERT INTO gtfs.calendar ("feed_index","service_id","monday","tuesday","wednesday","thursday","friday","saturday","sunday","start_date","e...
select c.studentassessmentid , c.studentnumber , s.fullname , e.advisory , ci.teacher_name , ci.sectionnumber , ci.sectionname , e.gradelevel , p.sped_status , p._504_status , p.lep_status , p.frl_status , l.schoolname , l.schoolabbreviation , l.level , l...
<reponame>lbouma/Cyclopath /* Copyright (c) 2006-2012 Regents of the University of Minnesota. For licensing terms, see the file LICENSE. */ /* Fix the revision history to clean up orphan tag_bs's and tag_point's 1. Find each orphan tag_bs.id, version. 2. Set valid_before_rid on existing rows (version 1) to the va...