sql
stringlengths
6
1.05M
<reponame>yangbajing/akka-fusion create table qrtz_job_details ( sched_name varchar(120) not null, job_name varchar(200) not null, job_group varchar(200) not null, description varchar(250), job_class_name varchar(250) not null, is_durable boolean not null, is_nonconcurrent boolean not null, is_update_data boole...
<reponame>cmgerber/CensusMapper -- generate the cartodb query SELECT 'SELECT a.cartodb_id, a.geotype, sum(case when b.fieldid in (' UNION ALL SELECT '''' || fieldid || ''',' FROM datalayers d JOIN numerator n ON d.measureid = n.measureid WHERE d.datalayersid = 5 UNION ALL SELECT '''ZZZ'') then b.value else 0 end) ' UNI...
-- Verify words:0006-update-user on pg BEGIN; -- XXX Add verifications here. ROLLBACK;
<filename>V1/Database/Tables/FF.League.sql SET ANSI_NULLS ON SET QUOTED_IDENTIFIER ON CREATE TABLE [FF].[League]( [LeagueId] [int] IDENTITY(1,1) NOT NULL, [Name] [varchar](50) NULL, CONSTRAINT [PK_League] PRIMARY KEY CLUSTERED ( [LeagueId] ASC )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY ...
<filename>bamazonInfo.sql<gh_stars>0 DROP DATABASE IF EXISTS bamazon; CREATE database bamazon; USE bamazon; CREATE TABLE products ( item_id INT NOT NULL AUTO_INCREMENT, product_name VARCHAR(100) NULL, department_name VARCHAR(100) NULL, price DECIMAL (10,4) NULL, stock_quantity INT NULL, PRIMARY KEY (id...
<filename>C#/C# DB/DataBases Basics/04. Data aggregation/07. Deposits Filter.sql<gh_stars>0 SELECT e.DepositGroup, SUM(e.DepositAmount) AS [TotalSum] FROM WizzardDeposits AS e WHERE e.MagicWandCreator LIKE '<NAME>' GROUP BY e.DepositGroup HAVING SUM(e.DepositAmount) < 150000 ORDER BY SUM(e.DepositAmount) DESC
SET @now := now(); SET @siteID = 1; SET @userID = 1;
<reponame>Gallouche/SLO_projet -- -- Database: centre_commercial -- CREATION_TABLES_ELISEI_TCHENTE_TRUAN.sql -- DROP DATABASE IF EXISTS slo_schema; SET NAMES 'cp1250'; SET CHARSET 'utf8'; CREATE SCHEMA slo_schema; USE slo_schema; -- ------------------- -- -- Création des tables -- -- ------------------- -- -- Tab...
UPDATE patient SET isoniazid_end_date = DATE_ADD(isoniazid_start_date, INTERVAL 168 DAY) WHERE isoniazid_start_date != ''//
SET FOREIGN_KEY_CHECKS = 0; DROP TABLE IF EXISTS `Empresa`; DROP TABLE IF EXISTS `Actividad`; DROP TABLE IF EXISTS `actividadEmpresa`; DROP TABLE IF EXISTS `GrupoActividad`; DROP TABLE IF EXISTS `Domicilio`; DROP TABLE IF EXISTS `Representante`; DROP TABLE IF EXISTS `Producto`; DROP TABLE IF EXISTS `Subproducto`; DROP ...
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Aug 29, 2021 at 09:37 PM -- Server version: 10.4.14-MariaDB -- PHP Version: 7.4.9 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIEN...
<filename>migrations/00000000000000_initial_setup/down.sql DROP INDEX IF EXISTS internal_calls_callee_class_idx; DROP INDEX IF EXISTS internal_calls_caller_class_idx; DROP INDEX IF EXISTS internal_calls_callee_idx; DROP INDEX IF EXISTS internal_calls_caller_idx; DROP INDEX IF EXISTS internal_calls_protocol_idx; DROP TA...
SELECT COUNT(E.codice) FROM esame_specialistico AS E JOIN specialita AS S ON E.area=S.id WHERE (E.for_sesso = ? OR E.for_sesso = ?) AND lower(E.nome) LIKE ? OR lower(S.nome) LIKE ? OR lower(descrizione) LIKE ?
INSERT INTO specifications VALUEs (1, 'Project initial requirements'); INSERT INTO specifications VALUEs (2, 'Another one specification'); INSERT INTO requirements VALUES (1, 'App should be useful', 1, NULL); INSERT INTO requirements VALUES (2, 'App should work', 1, NULL); INSERT INTO requirements VALUES (3, 'App shou...
create table reminders ( who varchar(255) not null, what varchar(255) not null, when timestamp not null, where varchar(255) );
CREATE TABLE casesvc.temp_cases ( bicaseid uuid NOT NULL, actionplanid uuid NOT NULL, bcaseid uuid, CONSTRAINT temp_cases_pkey PRIMARY KEY (bicaseid) );
create database if not exists ims; drop table if exists ims.customers; CREATE TABLE ims.customer_table(customer_id int AUTO_INCREMENT, first_name varchar(100) NOT NULL, surname varchar(100) NOT NULL, email varchar(150) NOT NULL, phone_number varchar(100) NOT NULL, UNIQUE(customer_id), PRIMARY KEY(customer_id)); CREATE ...
<filename>core/store/migrate/migrations/0105_create_forwarder_addresses.sql -- +goose Up CREATE TABLE evm_forwarders ( id BIGSERIAL PRIMARY KEY, address bytea NOT NULL UNIQUE, created_at timestamptz NOT NULL, updated_at timestamptz NOT NULL, evm_chain_id numeric(78,0) NOT NULL REFERENCES evm_chains(...
-- You have to create all of these tables in order because of they Primary Key and Foreign Key relationship. -- You can't create table with a Foreign Key without table with Primary Key first because I am using in line constraint. CREATE TABLE titles( title_id VARCHAR(10) PRIMARY KEY, title VARCHAR(30) NOT NULL ); C...
-- 2021-05-18T10:06:42.865Z -- URL zum Konzept /* DDL */ SELECT public.db_alter_table('C_BPartner','ALTER TABLE public.C_BPartner ADD COLUMN PO_Incoterm VARCHAR(3)') ;
-- -- PostgreSQL database dump -- -- Dumped from database version 13.3 (Debian 13.3-1.pgdg100+1) -- Dumped by pg_dump version 13.3 (Debian 13.3-1.pgdg100+1) SET statement_timeout = 0; SET lock_timeout = 0; SET idle_in_transaction_session_timeout = 0; SET client_encoding = 'UTF8'; SET standard_conforming_strings = on;...
<gh_stars>0 CREATE TABLE [membership].[Users] ( [Id] BIGINT IDENTITY (1, 1) NOT NULL, [UserName] VARCHAR (30) NOT NULL, [Password] CHAR (20) NOT NULL, [FullName] VARCHAR (100) NOT NULL, [email] VARCHAR (50) NULL );
<gh_stars>0  CREATE OR REPLACE VIEW list_location_attribute_values AS SELECT lav.id, l.id AS location_id, la.id AS location_attribute_id, CASE la.data_type WHEN 'T'::bpchar THEN 'Text'::bpchar WHEN 'L'::bpchar THEN 'Lookup List'::bpchar WHEN 'I'::bpchar THEN 'Integer'::bp...
<reponame>mtulio/kb<filename>Faculdade/2009-2_-_VI/Banco_de_Dados/projetos/copa_do_mundo/source/script_insert.sql /* */ /*INSERCAO DOS REGISTROS NAS TABELAS*/ /*INSERCAO DOS REGISTROS DAS TABELAS: CHAVE, PAIS, JOGADOR, POSICAO, JUIZ, BANDEIRINHA E ESTADIO*/ DELETE FROM Gols; DELETE FROM Cartoes; DELETE FROM Escalacao;...
<filename>Sql/public/Functions/NetworkApi_CreateSensorKey.sql CREATE FUNCTION networkapi_createsensorkey(key TEXT, userId TEXT) RETURNS TABLE( "Id" UUID, "UserId" UUID, "ApiKey" TEXT, "Revoked" BOOLEAN, "Type" INT, "ReadOnly" BOOLEAN ) LA...
<filename>sql/sqlite/V20190429181934__mark-active-column-as-boolean.sql<gh_stars>10-100 create table Guilds_dg_tmp ( id INTEGER primary key, name TEXT not null, region TEXT, created_on TEXT, last_active_on TEXT, active BOOLEAN default 1 ); insert into Guilds_dg...
<reponame>muratartim/Equinox CREATE TABLE AURORA.DB_VERSION(NAME VARCHAR(50) NOT NULL, VALUE DOUBLE NOT NULL); CREATE TABLE AURORA.EXCALIBUR_ANALYSES(ID BIGINT NOT NULL GENERATED ALWAYS AS IDENTITY (START WITH 1, INCREMENT BY 1), START_TIME TIMESTAMP NOT NULL, PRIMARY KEY(ID)); CREATE TABLE AURORA.RFORT_ANALYSES(ID INT...
-- -- AGGREGATES -- SELECT avg(four) AS avg_1 FROM onek; SELECT avg(a) AS avg_32 FROM aggtest WHERE a < 100; -- In 7.1, avg(float4) is computed using float8 arithmetic. -- Round the result to 3 digits to avoid platform-specific results. SELECT avg(b)::numeric(10,3) AS avg_107_943 FROM aggtest; SELECT avg(gpa) AS a...
IF NOT EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND object_id = object_id('dbo.Cleanup_CommandLog')) EXEC ('CREATE PROCEDURE dbo.Cleanup_CommandLog AS SELECT ''This is a stub''') GO ALTER PROCEDURE dbo.Cleanup_CommandLog @RetainDays_Backup int = 30, @RetainDays_DBCC int = 180, @R...
-- @testpoint:opengauss关键字sqlexception(非保留),作为数据库名 --关键字不带引号-成功 drop database if exists sqlexception; create database sqlexception; drop database sqlexception; --关键字带双引号-成功 drop database if exists "sqlexception"; create database "sqlexception"; drop database "sqlexception"; --关键字带单引号-合理报错 drop database if exists 's...
<filename>src/main/resources/database/changes/release-23/remove_all_templates_and_mappings.sql<gh_stars>0 DELETE FROM actionexporter.templatemapping; DELETE FROM actionexporter.template;
<filename>int-test/src/main/resources/db/migration/V2__Create_tokens_table.sql<gh_stars>0 create table TOKENS ( TOKENID varchar(64) PRIMARY KEY, EXPIRES bigint not null, USERID varchar(64) not null );
<reponame>joekucera2002/EnvironmentManager-API CREATE TABLE [dbo].[Test] ( [Id] INT NOT NULL PRIMARY KEY )
-- phpMyAdmin SQL Dump -- version 4.8.5 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1:3306 -- Generation Time: Dec 10, 2021 at 05:45 AM -- Server version: 5.7.26 -- PHP Version: 7.3.5 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHA...
<reponame>EmmanuelSHS/CSSA_Crawler -- CREATE DATABASE forum; -- unvid 1 = Columbia -- did 1 = secondhand USE forum; DROP TABLE categories; DROP TABLE users; DROP TABLE secondhand; CREATE TABLE categories( `did` INT(5) unvidSIGNED NOT NULL, `unvid` INT(3) UNSINGED NOT NULL, `name` VARCHAR(20), PRIM...
<gh_stars>0 @@grantRightsToRoles-contacts.sql @@grantRightsToRoles-expenseList.sql @@grantRightsToRoles-expenses.sql @@grantRightsToRoles-locationList.sql @@grantRightsToRoles-logs.sql @@grantRightsToRoles-payments.sql @@grantRightsToRoles-rs_contact_location.sql @@grantRightsToRoles-rs_contact_subject.sql @@gr...
<gh_stars>0 INSERT INTO pos_itemtemp VALUES("ILBT200000020","193405","191001","192019","34545","1","34545","0","34545","1","1","1","ILB3112200900","NHO2018000014","PAID","","193405"); INSERT INTO pos_salestemp VALUES("ILBT200000020","","1","34545","0","3455","0","38000","38000","31/12/2020","16:41","2020-12-31","16:...
SELECT *, BA.nama_konsumen as nama_konsumen_renovasi, BB.nama_konsumen as nama_konsumen_sewa, BC.nama_konsumen as nama_konsumen_wedding, BD.nama_konsumen as nama_konsumen_franchise, BE.nama_konsumen as nama_konsumen_lainnya, C.nama_konsumen as nama_konsumen_mytalim, D.nama_konsumen as nama_konsumen_mysafar, E.nama_ko...
<filename>PurchasingLookups.Db/dbo/Stored Procedures/usp_LoadAllPrePurchasingTables_partitioned.sql<gh_stars>1-10 -- ============================================= -- Author: <NAME> -- Create date: February 14, 2012 -- Description: Load all of the new PrePurchasingLookups tables as per Alan Lai -- Note: -- Comment o...
<gh_stars>1-10 USE [DataQualityDB] GO IF NOT EXISTS (SELECT 1 FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_NAME = 'DataQualityPrimaryKeyValues' AND TABLE_SCHEMA = 'DQ' ) BEGIN CREATE TABLE [DQ].[DataQualityPrimaryKeyValues]( [PKLogId] [int] IDENTITY(1,1) NOT NULL, [EntityId] [int] NULL, [RowId] [varchar](2...
<reponame>danieldiamond/gitlab-analytics {{config({ "schema": "staging" }) }} WITH RECURSIVE flattening AS ( SELECT {{ dbt_utils.star(from=ref('zuora_subscription_intermediate'), except=["ZUORA_RENEWAL_SUBSCRIPTION_NAME_SLUGIFY"]) }}, IFF(array_to_string(ZUORA_RENEWAL_SUBSCRIPTION_NAME_SLUGIFY,',') IS ...
<gh_stars>1-10 DROP TABLE IF exists final_events; SET @NUM := 0; SET @Device := 0; SET @Trip := 0; Set @Time := 0; SET @OID := 0; CREATE TABLE final_events as select @NUM := if(@Device = cf.Device and @Trip = cf.Trip and @Time = cf.Time - 10 and @OID = cf.obstacleID, @NUM, @NUM + 1) as eventNum, @Device :=...
<gh_stars>10-100 -- file:oidjoins.sql ln:200 expect:true SELECT ctid, conproc FROM pg_catalog.pg_conversion fk WHERE conproc != 0 AND NOT EXISTS(SELECT 1 FROM pg_catalog.pg_proc pk WHERE pk.oid = fk.conproc)
/* Calculate mutational signatures By Variant Classification */ WITH variant_classifications AS ( SELECT DISTINCT variant_classification FROM variants.variant_classifications ORDER BY 1 ), variant_contexts AS ( SELECT DISTINCT ref_context AS trinucleotide_context, alt FROM ref.signature_proba sp ), variant_context...
CREATE VIEW reservation_view AS SELECT b.id, b.purpose AS description, b.event_id AS eventId, b.group_id AS groupId, IFNULL (b.project_id, 0) AS projectId, b.guests, b.created as created, IF ( b.canceled, JSON_OBJECT( 'canceled', JSON_OBJECT( 'on', DATE_FORMAT(b.canceled_time, "%Y...
DROP TABLE IF EXISTS `mq_publisher`; CREATE TABLE `mq_publisher` ( `id` bigint(20) NOT NULL AUTO_INCREMENT, `body` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL, `correlation_id` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL, `create_time` datetime(0) NUL...
<gh_stars>1-10 ALTER TABLE {$NAMESPACE}_project.project ADD subprojectPHIDs longblob NOT NULL; UPDATE {$NAMESPACE}_project.project SET subprojectPHIDs = '[]'; CREATE TABLE {$NAMESPACE}_project.project_subproject ( projectPHID varchar(64) BINARY NOT NULL, subprojectPHID varchar(64) BINARY NOT NULL, PRIMARY KE...
INSERT INTO images_external(image_id, height, width, size_in_bytes, content_type, image_type, source, url) VALUES (?, ?, ?, ?, ?, ?, ?, ?)
<gh_stars>0 -- Script Date: 5/4/2020 10:25 PM - ErikEJ.SqlCeScripting version 3.5.2.86 INSERT INTO [Products] ([LocationId] ,[ProductName] ,[UnitCost] ,[Quantity] ) VALUES (1,"Mango",".75","50"), (1,"Tangerine",".50","35");
CREATE TABLE series( id INT PRIMARY KEY, user_id INT REFERENCES users(id), name TEXT, description TEXT, created TIMESTAMP DEFAULT now() )
<reponame>SkillsFundingAgency/DC-ILR-2021-DataStore CREATE TABLE [Valid].[LearnerHEFinancialSupport] ( [UKPRN] INT NOT NULL, [LearnRefNumber] VARCHAR (12) NOT NULL, [FINTYPE] INT NOT NULL, [FINAMOUNT] INT NOT NULL, PRIMARY KEY CLUSTERED ([UKPRN] ASC, ...
<filename>tool/PG_SQL/time_point_events.sql /* * 书籍 - 设定 - 其他 * t_p_e_id < 主键 > * t_p_e_time 字段名称 * t_p_e_title 字段类型 * t_p_e_introduction 字介绍 */ CREATE TABLE if NOT EXISTS public.time_point_events ( t_p_e_id SERIAL NOT NULL PRIMARY KEY, t_p_e_tim...
<gh_stars>0 -- https://www.iana.org/assignments/dns-parameters/dns-parameters.xhtml CREATE TABLE IF NOT EXISTS DHCPIdentifierResourceRecordIdentifierTypeCodes ( code SMALLINT UNSIGNED NOT NULL PRIMARY KEY, identifier TINYTEXT NOT NULL, definingRFCs TINYTEXT ...
create database points26; use points26; CREATE TABLE `points` ( `x` double NOT NULL, `y` double NOT NULL ) ENGINE=InnoDB; insert into points (x, y) values (0, 0); insert into points (x, y) values (1, 1); insert into points (x, y) values (2, 2); insert into points (x, y) values (3, 3); insert into points (x, y) v...
-- phpMyAdmin SQL Dump -- version 5.0.1 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Jun 12, 2020 at 05:38 PM -- Server version: 10.4.11-MariaDB -- PHP Version: 7.2.27 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OL...
<gh_stars>1-10 ------------------------------------------- -- Let's first investigate what we have ------------------------------------------- create or replace package deathstar_room_manager as subtype varchar2_nn is varchar2 not null; /** Adds a new room to a section */ procedure add_room( i_name varch...
<filename>data/train/sql/8efd6da447793876139e1d5444a0fc83f3e2e025Example3_Exadata.sql -- -- This is an example launcher script for OraLatencyMap -- The sqlplus script reads from gv$event_histogram data the latency drilldown for the cell single block physical read wait event -- This is a wait event for Exadata storage....
<reponame>mshick/pg-versioning create schema if not exists test;
.echo on select printf('A\nB'); select printf('A\tB'); select printf('A B'); select printf('A B'); select printf('A' || cahr(10) || 'B'); select printf('A' || char(9) || 'B');
<reponame>drewburr/postgres-operator-examples create table employee (empid int, first_name varchar(40), last_name varchar(40), status varchar(10), hiredt date, terminationdt date); alter table employee add primary key (empid); create table department (deptid int, department varchar(40), glcode varchar(20)); alter table...
<filename>chapter_007/create.sql create database system_items; create table user_ ( id serial, first_name varchar(50) not null, last_name varchar(50) not null, primary key(id) ); create table category ( name_category varchar(50), primary key(name_category) ); create table state ( name_state varchar(50), che...
DROP TRIGGER resolwe_bio_kb_feature_biut ON resolwe_bio_kb_feature; DROP FUNCTION resolwe_bio_kb_feature_biut(); DROP FUNCTION generate_resolwe_bio_kb_feature_search(resolwe_bio_kb_feature);
<filename>standalone-metastore/src/main/sql/mysql/upgrade-1.2.0-to-1.2.1000.mysql.sql SELECT 'Upgrading MetaStore schema from 1.2.0 to 1.2.1000' AS MESSAGE; -- SOURCE 023-HIVE-12807.mysql.sql; ALTER TABLE `COMPACTION_QUEUE` ADD `CQ_HIGHEST_TXN_ID` bigint; -- SOURCE 024-HIVE-12814.mysql.sql; ALTER TABLE `COMPACTION_QU...
<gh_stars>1000+ ALTER TABLE `{$NAMESPACE}_draft`.`draft` ADD `metadata` longtext AFTER `draft`; UPDATE `{$NAMESPACE}_draft`.`draft` SET `metadata` = '[]';
select /* pgwatch2_generated */ (extract(epoch from now()) * 1e9)::int8 as epoch_ns, device as tag_device, retcode from get_smart_health_per_device();
INSERT INTO `ninja_saved_filters` (`username`, `filter_name`, `filter_table`, `filter`, `filter_description`) VALUES ('monitor', 'error messages', 'log_messages', '[log_messages] severity <= 3', 'error messages'), ('monitor', 'warning messages', 'log_messages', '[log_messages] severity = 4', 'warning messages'), ('moni...
drop schema ims; CREATE SCHEMA IF NOT EXISTS `ims`; USE `ims` ; CREATE TABLE IF NOT EXISTS `ims`.`customers` ( `cid` INT(11) NOT NULL AUTO_INCREMENT, `first_name` VARCHAR(40) DEFAULT NULL, `surname` VARCHAR(40) DEFAULT NULL, PRIMARY KEY (`cid`) ); CREATE TABLE IF NOT EXISTS `ims`.`items` ( `iid` IN...
<filename>conf/journalisthelper.sql -- phpMyAdmin SQL Dump -- version 4.8.0 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Oct 14, 2018 at 07:21 AM -- Server version: 10.1.31-MariaDB -- PHP Version: 7.2.4 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_...
<reponame>Santa0727/Hospital-Chat-App /* SQLyog Community v13.1.5 (64 bit) MySQL - 10.4.8-MariaDB : Database - kelowna_urgolive ********************************************************************* */ /*!40101 SET NAMES utf8 */; /*!40101 SET SQL_MODE=''*/; /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHE...
<filename>_MAIN SQL SOLUTIONS/Oft Used Code/Oft Used Code/Oft Used Code/1 Code for updating TASKPAD.sql use partner select top 2 * from Cm_Agendas where ItemID = 31880084 select * from diary_tasks where /*Description like '%25 day issues%' and */ EntityRef like 'chi000000000611%' and MatterNoRef = 1 Select * from...
-- phpMyAdmin SQL Dump -- version 4.3.8 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: Feb 19, 2018 at 02:58 AM -- Server version: 5.5.51-38.2 -- PHP Version: 5.6.30 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT...
<filename>backend/infra/appsync/resolvers/Query.passengers/request.sql #set($includeUnverified = $util.defaultIfNull($ctx.args.includeUnverified, true)) with recursive split ( passenger, str ) as ( select '', remarks || ', ' from manifest left join meta using(id) where meta.logistical = false union all ...
/* intentional: this will not drop and recreate the database if it already exists */ /* Mainly for CI. If you install with brew, you likely have authentication configured as "TRUST" for all */ CREATE USER nexia WITH PASSWORD '<PASSWORD>'; GRANT ALL ON DATABASE history_store TO nexia;
<gh_stars>1-10 -- ============================================= -- Author: <NAME> -- Create date: March 01, 2012 -- Description: Delete Vendors index prior to downloading vendors data. -- Modifications: -- 2012-06-23 by kjt: Converted from partitioned/swap table loading to direct table loading. -- ===================...
<filename>data/open-source/extracted_sql/lastzero_test-tools.sql SELECT * FROM users WHERE id = 2 SELECT username FROM users WHERE id = 2'); SELECT * FROM example'); SELECT * FROM users'); UPDATE users SET username = ? WHERE id = ? CREATE TABLE `users` ( `id` int(11) NOT NULL AUTO_INCREMENT, `username` varchar(45) DEF...
DELETE FROM attendances; INSERT INTO attendances SELECT Attendance_ID, family_id, Date, Husband_Present, Wife_Present, Date, Date FROM `veritasclass`.Attendance where Attendance_Type_ID = 1
-- create the database \i 'database/db_geography.sql'; -- switch to using the database \c geography_test; -- setup any extensions \i 'database/db_extensions.sql'; -- set client encoding set client_encoding = 'UTF8'; -- create tables \i 'tables/tbl_county_boundary.sql'; \i 'tables/tbl_country_boundary.sql'; \i 'tabl...
<gh_stars>1-10 -- 1. Show the total population of the world. SELECT SUM(population) FROM world; -- 2. List all the continents - just once each. SELECT DISTINCT continent FROM world; -- 3. Give the total GDP of Africa SELECT SUM(gdp) FROM world WHERE continent = 'Africa'; -- 4. How many countries have an area ...
insert into exchange_value(id,currency_from,currency_to,conversion_multiple) values(10001,'USD','INR',65); insert into exchange_value(id,currency_from,currency_to,conversion_multiple) values(10002,'EUR','INR',75); insert into exchange_value(id,currency_from,currency_to,conversion_multiple) values(10003,'AUD','INR',25);
<reponame>tabulon-ext/atomiadns<gh_stars>100-1000 CREATE OR REPLACE FUNCTION MarkAllUpdatedExcept ( zonearg varchar, change_id bigint ) RETURNS void AS $$ DECLARE nameserver_id_var int; BEGIN SELECT nameserver_id INTO nameserver_id_var FROM change WHERE zone = zonearg AND id = change_id; IF N...
<reponame>alexgalkin/odin INSERT INTO odin.migration VALUES('app', '003-app-role.blue.sql'); -- APP ROLE CREATE TABLE odin.app_role ( app_id TEXT NOT NULL, FOREIGN KEY (app_id) REFERENCES odin.app (app_id) MATCH SIMPLE ON UPDATE NO ACTION ON DELETE NO ACTION DEFERRABLE, role TEXT NOT NULL C...
<gh_stars>0 do $$ begin if not exists (select 1 from "pg_type" where "typname" = 'setting_key') then create type "setting_key" as enum('AllowRegistration', 'DefaultNewUserRole'); end if; end$$; create table if not exists "setting_values" ( "k" setting_key primary key, "v" character varying(4096) not null )...
<filename>src/main/resources/db/migration/V1__user_info.sql<gh_stars>0 CREATE TABLE USER_INFO ( ID INTEGER PRIMARY KEY NOT NULL AUTO_INCREMENT, FIRST_NAME VARCHAR(20), LAST_NAME VARCHAR(20), MAIL_ID VARCHAR(20), PASSWORD1 VARCHAR(20), CREATED_TIME TIMESTAMP );
<reponame>aravi5/drill-test-framework<gh_stars>0 set `planner.slice_target`=1; select * from `json/empty`; reset `planner.slice_target`;
COPY( select invoice_number, stock_code, detail, quantity, invoice_date, unit_price, customer_id, country from retail.user_purchase where quantity > 2 and cast(invoice_date as date)='{{ ds }}') TO '{{ params.temp_filtered...
<gh_stars>1-10 BEGIN; DROP INDEX graveler_commits_idx_first_parent; DROP FUNCTION first_parent; DROP INDEX graveler_branches_idx_commit_id; COMMIT;
<reponame>cmarincia/tidb<gh_stars>100-1000 /*!40101 SET NAMES binary*/; CREATE DATABASE `views` /*!40100 DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_bin */ /*!80016 DEFAULT ENCRYPTION='N' */;
<reponame>ie3-institute/PowerSystemDatamodel<gh_stars>1-10 CREATE TABLE public.time_series_c ( uuid uuid PRIMARY KEY, time_series uuid NOT NULL, time timestamp with time zone NOT NULL, price double precision ) WITHOUT OIDS TABLESPACE pg_default; CREATE INDEX time_series_c_series_id ON time_seri...
<reponame>hyoklee/hdf5 Opened "TEST.h5" with sec2 driver. Monitoring dataset /DSET_CMPD... dimension 0: 10->13 (increases) Data: (10) {field1=1, field2={a=2, b={a=2, b=2, c=2}, c=2}, field3=3, (10) field4={a=4, b=4}}, (11) {field1=2, field2={a=3, b={a=3, b=3, c=3}, c=3}, field3=4, ...
 CREATE TABLE [Test].[MultiPk] ( [Part1] INT NOT NULL, [Part2] INT NOT NULL, [Value] DECIMAL(16,4) NULL, [Parts] AS (CAST(Part1 AS NVARCHAR(32)) + '.' + CAST(Part2 AS NVARCHAR(32))) CONSTRAINT [PK_Test_MultiPk] PRIMARY KEY ([Part1], [Part2]) )
-- MySQL dump 10.13 Distrib 8.0.19, for Win64 (x86_64) -- -- Host: localhost Database: onlinetailoringsystem -- ------------------------------------------------------ -- Server version 8.0.19 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTE...
CREATE TABLE dbo.Building( IDbuilding INT NOT NULL, Address NCHAR(25) NOT NULL, PRIMARY KEY (IDbuilding) ) CREATE TABLE dbo.Departament( IDdepartament INT NOT NULL, IDfacultry INT NOT NULL, NameDepartament NCHAR(25) NOT NULL, HeadDepartament NCHAR(25) NOT NULL, Specialization NCHAR(25) NOT NULL, LabN NCHAR(1...
<reponame>ankushTripathi/WebAppAuthentication -- -------------------------------------------------------- -- Host: 127.0.0.1 -- Server version: 10.1.10-MariaDB - mariadb.org binary distribution -- Server OS: Win32 -- HeidiSQL Version: 9.4.0.5125 -- --...
<gh_stars>1-10 CREATE TYPE report_type AS ENUM ('SELF_REPORT', 'VERIFIED'); CREATE TYPE report_result AS ENUM ('UNKNOWN', 'POSITIVE', 'NEGATIVE'); CREATE TABLE token (token_value bytea PRIMARY KEY, report_type report_type NOT NULL, report_result report_result NOT NULL); COMMENT ON TABLE token is 'Contains one row ...
--DROP PROC uspSelMemberItems CREATE PROC uspSelMemberItems ( @Page bigint , @PageSize bigint , @MemberID varchar(max) ) AS SET NOCOUNT ON SET TRANSACTION ISOLATION LEVEL READ UNCOMMITTED; WITH TBL_PAGELIST AS ( SELECT ROW_NUMBER() OVER (ORDER BY MemberItems.CreatedAt) AS ROWNUM, ItemLists.ItemL...
-- MySQL dump 10.13 Distrib 8.0.26, for Win64 (x86_64) -- -- Host: localhost Database: northwind -- ------------------------------------------------------ -- Server version 8.0.26 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /...
CREATE OR ALTER PROCEDURE InsertObservationRows @Observations dbo.ObservationRowType READONLY, @ObservationFilterItems dbo.ObservationRowFilterItemType READONLY AS BEGIN TRANSACTION CREATE TABLE #InsertedObservations( Id BIGINT NOT NULL, CsvRow BIGINT NOT NULL ); CREATE INDEX IX_In...
<reponame>serverless-components/tencent-discuzq -- MySQL dump 10.13 Distrib 5.7.31, for Linux (x86_64) -- -- Host: localhost Database: dzqdatabase_placeholder -- ------------------------------------------------------ -- Server version 5.7.31 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!4010...
<filename>spring-boot-jdbc-example/src/test/resources/oracle/basic_mapping_oracle.sql /* Oracle create DB tables and init sample data */ /* CREATE SEQUENCE user_seq START WITH 13 INCREMENT by 1$ */ CREATE TABLE USER_ ( ID NUMBER DEFAULT user_seq.nextval NOT NULL, USERNAME varchar2(45) NOT NULL, PASSWORD varchar...
-- file:polymorphism.sql ln:292 expect:true CREATE AGGREGATE myaggn13a(BASETYPE = int, SFUNC = tfnp, STYPE = anyarray, FINALFUNC = ffnp, INITCOND = '{}')