sql
stringlengths
6
1.05M
create table People ( ID integer primary key autoincrement, Name text not null, Surname text not null, Email int not null ); create table Courses ( ID integer primary key autoincrement, Title text not null ); create table Answers ( CourseID int not null constraint Answers_Courses_ID_fk references Courses (...
CREATE PROCEDURE [dbo].[h3giAccChangeEnableServiceRequestTypes] @enable VARCHAR(1), @classDesc VARCHAR(50) AS BEGIN UPDATE b4nClassCodes SET b4nValid = @enable WHERE b4nClassSysID = 'ServiceRequestType' AND b4nClassDesc = @classDesc END GRANT EXECUTE ON h3giAccChangeEnableServiceRequestTypes TO b4n...
create view "postgres"._airbyte_test_normalization."nested_stream_with_c__ion_double_array_data_ab1__dbt_tmp" as ( -- SQL model to parse JSON blob stored in a single column and extract into separated field columns as described by the JSON Schema select _airbyte_partition_hashid, jsonb_extract_path_text...
CREATE TABLE subdivision_AT (id VARCHAR(6) NOT NULL, name VARCHAR(255) NOT NULL, level VARCHAR(64) NOT NULL, PRIMARY KEY(id)) DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci ENGINE = InnoDB; INSERT INTO `subdivision_AT` (`id`, `name`, `level`) VALUES ('AT-1', 'Burgenland', 'state'); INSERT INTO `subdivision_AT` (`i...
INSERT INTO user (user_id, username, password) VALUES (1, 'user', 'password'); INSERT INTO user (user_id, username, password) VALUES (2, 'admin','password'); INSERT INTO user (user_id, username, password) VALUES (3, 'mary','password'); INSERT INTO role (role_id, role) VALUES (1, 'USER'); INSERT INTO role (role_id, rol...
<gh_stars>100-1000 ALTER TABLE releases ADD hashed BOOL DEFAULT false; CREATE INDEX ix_releases_hashed ON releases(hashed); UPDATE releases SET hashed = true WHERE searchname REGEXP '[a-fA-F0-9]{32}' OR name REGEXP '[a-fA-F0-9]{32}'; DROP TRIGGER IF EXISTS hash_check_insert; DROP TRIGGER IF EXISTS hash_check_update; ...
DROP SCHEMA IF EXISTS public CASCADE; CREATE SCHEMA public; CREATE EXTENSION pgcrypto; --- Table with Reviews CREATE TABLE public.REVIEW_05 ( ReviewID UUID DEFAULT public.gen_random_uuid() NOT NULL, Review_Timestamp TIMESTAMPTZ, Nickname VARCHAR(40), Review_Body TEXT, Score INT, CHECK (Score >= 1...
<filename>datasets/broedvogel-atlas-occurrences/sql/dwc_occurrence.sql USE [BroedvogelAtlas_IPT] GO /****** Object: View [ipt].[vwGBIF_BroedvogelAtlasOccurrence] Script Date: 19/09/2016 11:34:14 ******/ SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO ALTER VIEW [ipt].[vwGBIF_BroedvogelAtla...
CREATE TABLE users( id int primary key, registered_at timestamp not null ); CREATE TABLE guides( id serial primary key, delay int8, title varchar(255) not null, text varchar(2048) not null ); CREATE TABLE user_guides( user_id int not null, guide_id int not null, PRIMARY KEY (user_i...
-- Databricks notebook source -- MAGIC %md-sandbox -- MAGIC <div style="text-align: center; line-height: 0; padding-top: 9px;"> -- MAGIC <img src="https://cdn2.hubspot.net/hubfs/438089/docs/training/dblearning-banner.png" alt="Databricks Learning" width="555" height="64"> -- MAGIC </div> -- COMMAND ---------- -- MA...
-- MODULE DML019 -- SQL Test Suite, V6.0, Interactive SQL, dml019.sql -- 59-byte ID -- TEd Version # -- AUTHORIZATION HU SELECT USER FROM HU.ECCO; -- RERUN if USER value does not match preceding AUTHORIZATION comment -- date_time print -- TEST:0074 GROUP BY col with SELECT col., SUM! SELECT PNUM, SUM(HOURS...
SET TIME ZONE 'UTC'; -- Count downloads per user per year WITH dpupm AS ( SELECT DATE_PART('year', created) AS year, SUM(total_records) AS totalRecords, COUNT(key) AS totalDownloads, created_by AS username FROM occurrence_download WHERE status IN('SUCCEEDED', 'FILE_ERASED') A...
#standardSQL # 21_04: Popular resource types to preload/prefetch. CREATE TEMPORARY FUNCTION getResourceHintTypes(payload STRING) RETURNS ARRAY<STRUCT<name STRING, href STRING>> LANGUAGE js AS ''' var hints = new Set(['preload', 'prefetch']); try { var $ = JSON.parse(payload); var almanac = JSON.parse($._almanac); ...
//// CHANGE name=change0 CREATE MEMORY TABLE TABLE469(ID INTEGER NOT NULL PRIMARY KEY,FIELD1 VARCHAR(30),USERTYPE4FIELD USERTYPE4,USERTYPE5FIELD USERTYPE5) GO
/* Navicat MySQL Data Transfer Source Server : mysql-9-3306 Source Server Version : 50636 Source Host : 192.168.110.9:3306 Source Database : chonglou Target Server Type : MYSQL Target Server Version : 50636 File Encoding : 65001 Date: 2017-12-28 01:39:49 */ SET FOREIGN_KEY_CHECKS=...
CREATE TABLE tmp_contracts_summary AS SELECT r.id, ORDINALITY - 1 AS contract_index, r.release_type, r.collection_id, r.ocid, r.release_id, r.data_id, value AS contract, value ->> 'awardID' AS awardid FROM tmp_release_summary_with_release_data r CROSS JOIN jsonb_array_element...
<reponame>amankapoor/pkgsite -- Copyright 2021 The Go Authors. All rights reserved. -- Use of this source code is governed by a BSD-style -- license that can be found in the LICENSE file. BEGIN; DROP INDEX idx_symbol_history_module_path_id; DROP INDEX idx_symbol_history_since_version; DROP INDEX idx_symbol_history_sy...
<gh_stars>0 -- phpMyAdmin SQL Dump -- version 4.8.5 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Waktu pembuatan: 15 Des 2019 pada 16.35 -- Versi server: 10.1.38-MariaDB -- Versi PHP: 7.3.2 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SE...
DROP DATABASE IF EXISTS HOLTERDB; CREATE DATABASE IF NOT EXISTS holterdb DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci; USE holterdb; create table parametros( id_parametro int not null auto_increment, frecardiacamin int unsigned not null, frecardiacamax int unsigned not null, cantidadmediciones int unsigne...
<reponame>kreako/soklaki -- Could not auto-generate a down migration. -- Please write an appropriate down migration for the SQL below: -- alter table "public"."student" add column "school_exit" date null;
--- This file has been generated by scripts/build_db.py. DO NOT EDIT ! INSERT INTO "other_transformation" VALUES('EPSG','1258','Bogota 1975 (Bogota) to Bogota 1975 (Greenwich)','','EPSG','9601','Longitude rotation','EPSG','4802','EPSG','4218',NULL,'EPSG','8602','Longitude offset',-74.04513,'EPSG','9110',NULL,NULL,NULL...
<filename>user_group.sql -- phpMyAdmin SQL Dump -- version 4.8.1 -- https://www.phpmyadmin.net/ -- -- Host: localhost -- Waktu pembuatan: 07 Sep 2018 pada 23.29 -- Versi server: 8.0.12 -- Versi PHP: 7.2.7-0ubuntu0.18.04.2 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+...
<filename>database/scrapbook.sql -- phpMyAdmin SQL Dump -- version 4.5.1 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: Nov 26, 2016 at 11:04 PM -- Server version: 10.1.16-MariaDB -- PHP Version: 5.6.24 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARAC...
create procedure [dbo].[dnn_AddAffiliate] @VendorId int, @StartDate datetime, @EndDate datetime, @CPC float, @CPA float as insert into dbo.dnn_Affiliates ( VendorId, StartDate, EndDate, CPC, Clicks, CPA, Acquisitions ) values ( @VendorId, @Start...
CREATE TABLE Clients ( Id INT PRIMARY KEY IDENTITY NOT NULL, FirstName NVARCHAR(50) NOT NULL, LastName NVARCHAR(50) NOT NULL, ) CREATE TABLE AccountTypes ( Id INT PRIMARY KEY IDENTITY NOT NULL, [Name] NVARCHAR(50) NOT NULL, ) CREATE TABLE Accounts ( Id INT PRIMARY KEY IDENTITY NOT NULL, AccountTypeId INT FOREI...
create table tt_project_history (id bigint not null, rev integer not null, revtype tinyint, name varchar(250), primary key (id, rev)) select ta from TaskAssignment ta where ta.user.id = :userId and ta.startingFrom <= :until and ( ta.until is null or ta.until >= :from ) create table revinfo (rev integer generated by def...
/****** Object: User Defined Function dbo.SectorThreadViews Script Date: 5/1/2004 6:12:44 PM ******/ CREATE FUNCTION dbo.SectorThreadViews ( @ThreadID int ) RETURNS int BEGIN RETURN(SELECT [Views] FROM SectorForumsThreads WHERE ThreadID = @ThreadID) END
create view "integrationtests"._airbyte_test_normalization."renamed_dedup_cdc_excluded_ab3__dbt_tmp" as ( with __dbt__cte__renamed_dedup_cdc_excluded_ab1 as ( -- SQL model to parse JSON blob stored in a single column and extract into separated field columns as described by the JSON Schema select case when...
<filename>SQLServer/2008/ZGWSecurity/Stored Procedures/Get_Security_Entity.sql<gh_stars>1-10 /* Usage: DECLARE @P_Security_Entity_SeqID AS INT = 1, @P_Debug INT = 1 exec ZGWSecurity.Get_Security_Entity @P_Security_Entity_SeqID, @P_Debug */ -- ============================================= -- Author: <NAME>...
Rem Rem $Header: sh_olp_d.sql 29-aug-2002.11:56:57 hyeh Exp $ Rem Rem sh_olp_d.sql Rem Rem Copyright (c) 2001, 2015, Oracle Corporation. All rights reserved. Rem Rem Permission is hereby granted, free of charge, to any person obtaining Rem a copy of this software and associated documentation files (the Rem "Softwar...
<filename>samples/features/ssms-templates/Sql/Service Broker/Queue/Turn Off Queue.sql -- ============================================= -- Turn Queue Off Template -- ============================================= ALTER QUEUE <queue-name, sysname, test_queue> WITH STATUS = OFF
-- +migrate Up CREATE TABLE IF NOT EXISTS worlds ( id INTEGER PRIMARY KEY AUTOINCREMENT, name TEXT, translated_name TEXT ); CREATE TABLE IF NOT EXISTS regions ( id INTEGER PRIMARY KEY, world_id INTEGER, name TEXT, type TEXT, FOREIGN KEY(world_id) REFERENCES worlds(id) ); CREATE TABLE IF NOT EXISTS undergroun...
<gh_stars>1-10 --<snippetFilteredStats1> USE AdventureWorks2012; GO SELECT OBJECT_NAME(s.object_id) AS object_name, COL_NAME(sc.object_id, sc.column_id) AS column_name, s.name AS statistics_name FROM sys.stats AS s Join sys.stats_columns AS sc ON s.stats_id = sc.stats_id WHERE s.name like '_WA%' OR...
<reponame>one-touch-pipeline/otp<filename>migrations/changelogs/2020/otp-411.sql -- previously used for CellRanger and RunYapsa configs UPDATE config_per_project_and_seq_type SET program_version = external_script_version WHERE program_version IS NULL AND external_script_version IS NOT NULL; ALTER TABL...
select stratum_1 DOMAIN_BITS,stratum_2 PERCENT_VALUE, count_value COUNT_VALUE from @results_database_schema.achilles_results where analysis_id = 2004;
--Put SQL statements here to create columns, tables, etc.
/* Navicat MySQL Data Transfer Source Server : localhost_3306 Source Server Version : 50725 Source Host : localhost:3306 Source Database : gamefc Target Server Type : MYSQL Target Server Version : 50725 File Encoding : 65001 Date: 2019-03-23 17:53:35 */ SET FOREIGN_KEY_CHECKS=0; ...
SELECT SUM(CNT) FROM ( SELECT COUNT(*) AS CNT FROM ACT_RU_TASK T INNER JOIN ACT_PROC_STATE S ON T.PROC_INST_ID_=S.PROC_INST_ID INNER JOIN ACT_HI_PROCINST P ON T.PROC_INST_ID_=P.PROC_INST_ID_ LEFT JOIN ACT_BACKLOG_CONFIG C ON S.BUS_CODE=C.BUS_CODE WHERE ( T.ASSIGNEE_='U0000001'/*$1*/ OR ...
<gh_stars>1-10 CREATE TABLE candidates ( candidate_id BIGINT NOT NULL AUTO_INCREMENT, first_name VARCHAR(64) NOT NULL, last_name VARCHAR(32) NOT NULL, email VARCHAR(64) NOT NULL, create_date DATETIME NOT NULL, is_active BOOLEA...
ALTER TABLE sessions ALTER COLUMN props TYPE jsonb USING props::jsonb;
<reponame>Siyanda-Mzam/grassroot-platform drop table acl_entry; drop table acl_object_identity; drop table acl_class; drop table acl_sid;
-- @testpoint:openGauss保留关键字freeze作为作为表空间名, --不带引号,合理报错 drop tablespace if exists freeze; CREATE TABLESPACE freeze RELATIVE LOCATION 'hdfs_tablespace/hdfs_tablespace_1'; --加双引号,创建成功 drop tablespace if exists "freeze"; CREATE TABLESPACE "freeze" RELATIVE LOCATION 'hdfs_tablespace/hdfs_tablespace_1'; --清理环境 drop table...
<reponame>lol768/tabula DROP TABLE FEEDBACK; DROP TABLE SUBMISSION; DROP TABLE ASSIGNMENT; DROP TABLE FORMFIELD; DROP TABLE FILEATTACHMENT; DROP TABLE USERGROUP; DROP TABLE USERGROUPEXCLUDE; DROP TABLE USERGROUPINCLUDE; DROP TABLE AUDITEVENT; DROP TABLE ACCREDITEDPRIORLEARNING; DROP TABLE ADDRESS; DROP TABLE ASSESSM...
<reponame>Groundhog-Day/gallery-service /* * Execute this file from the terminal: * `psql -d postgres -U root < schema.sql` * */ DROP DATABASE IF EXISTS airbnb; CREATE DATABASE airbnb; \c airbnb; DROP TABLE IF EXISTS public.listings; CREATE TABLE public.listings ( list_id SERIAL, title VARCHAR(256) NOT NUL...
<reponame>ahadimuhsin/pendataan -- phpMyAdmin SQL Dump -- version 4.7.0 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Feb 08, 2018 at 09:58 AM -- Server version: 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...
<reponame>calian-pace/QuikRide CREATE TABLE [dbo].[Reservation] ( [ReservationId] UNIQUEIDENTIFIER NOT NULL, [UserId] INT NOT NULL, [PickUpLocationId] UNIQUEIDENTIFIER NOT NULL, [DestinationLocationId] UNIQUEIDENTIFIER...
<reponame>yanrodrigues205/YanCode-SiteComercial -- phpMyAdmin SQL Dump -- version 4.1.4 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: 01-Jan-2022 às 23:44 -- Versão do servidor: 5.6.15-log -- PHP Version: 5.5.8 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @O...
SELECT Salary FROM Employees WHERE Salary >= 50000 ORDER BY SALARY desc
<filename>vault-deploy-api/db/statements/select_package_by_id.sql SELECT rowid AS id, user_id, application_version, STRFTIME('%s', createdAt) AS build_timestamp, be_version, fe_version, processed, error_message, stdout, stderr, processingCompletedAt, createdAt FROM packages WHERE rowid = $pa...
select octet_length(cleaned_content::text) / 1048576.0 as mb from responses where format = 'xml' order by mb desc;
--- Lists users by what percentage of their messages have a mention in them. --- Only counts users with more than 400 messages. SELECT users.name, users.int_user_id, users.real_user_id, users.is_bot, 100.0 * COUNT(messages.int_user_id) / total_messages.count AS percentage FROM ( SELECT ...
<filename>storage/bdetect.sql -- phpMyAdmin SQL Dump -- version 4.9.5deb2 -- https://www.phpmyadmin.net/ -- -- Хост: localhost -- Час створення: Лис 06 2020 р., 19:14 -- Версія сервера: 8.0.22-0ubuntu0.20.04.2 -- Версія PHP: 7.4.3 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_...
<reponame>iafb/greatreadingadventure<filename>GRA.Database/dbo/Stored Procedures/app_SentEmailLog_Insert.sql  /****** Object: StoredProcedure [dbo].[app_SentEmailLog_Insert] Script Date: 01/05/2015 14:43:26 ******/ --Create the Insert Proc CREATE PROCEDURE [dbo].[app_SentEmailLog_Insert] ( @SentDateTime DATETIME,...
-- phpMyAdmin SQL Dump -- version 4.7.0 -- https://www.phpmyadmin.net/ -- -- Host: 1192.168.3.11 -- Czas generowania: 18 Gru 2017, 18:23 -- Wersja serwera: 10.1.26-MariaDB -- Wersja PHP: 7.1.8 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_C...
SET DEFINE OFF; CREATE INDEX AFW_19_CLE_FK3 ON AFW_19_CLE (REF_LANG) LOGGING /
<reponame>brightman9/VueNote /* Navicat MySQL Data Transfer Source Server : vuenote_prod Source Server Version : 80013 Source Host : 172.16.17.32:3306 Source Database : vuenote Target Server Type : MYSQL Target Server Version : 80013 File Encoding : 65001 Date: 2019-06-10 09:35:39 ...
<filename>darby/update.sql -- UPDATE ALTER TABLE attendance_logs add lat FLOAT after attendence_date; ALTER TABLE attendance_logs add lng FLOAT after lat; desc attendance_logs;
<filename>aguascalientes/createdAt_aguascalientes.sql insert into datetime_at(id, created_at, updated_at) value(UUID_TO_BIN('2b8c4a52-2da8-4869-b143-4ba4a62600d4'), '2020-06-15 23:18:07', '2020-06-15 23:18:07');
<gh_stars>1-10 select SUM(col3) from order_small;
CREATE DATABASE BANCO; USE BANCO; -- TABELA DE CLIENTES CREATE TABLE Clientes ( ID_Cliente INTEGER PRIMARY KEY AUTO_INCREMENT, NomeCliente VARCHAR(100) NOT NULL, EnderecoCliente VARCHAR(100) NOT NULL, Email VARCHAR(50) NOT NULL UNIQUE, CPF_CNPJ BIGINT NOT NULL UNIQUE, Telefone VARCHAR(15) NOT ...
<reponame>danieldiamond/gitlab-analytics {% snapshot gitlab_dotcom_gitlab_subscriptions_snapshots %} {{ config( unique_key='id', strategy='timestamp', updated_at='updated_at', ) }} WITH source AS ( SELECT *, ROW_NUMBER() OVER (PARTIT...
<reponame>Shuttl-Tech/antlr_psql -- file:portals.sql ln:37 expect:true DECLARE foo16 SCROLL CURSOR FOR SELECT * FROM tenk2
<reponame>Shuttl-Tech/antlr_psql<gh_stars>10-100 -- file:aggregates.sql ln:655 expect:true select * from aggordview1 order by ten
-- UPDATE VERSION NUMBER UPDATE myems_system_db.tbl_versions SET version='1.0.6', release_date='2021-02-27' WHERE id=1;
CREATE TABLE [dbo].[DDL] ( [DDLID] BIGINT IDENTITY (1, 1) NOT NULL, [DDLHash] BINARY (32) NOT NULL, [DDL] VARBINARY (MAX) NULL, CONSTRAINT PK_DDL PRIMARY KEY CLUSTERED ([DDLID] ASC) ); GO CREATE UNIQUE NONCLUSTERED INDEX IX_DDL_DDLHash ON dbo.DDL(DDLHash)
<gh_stars>100-1000 CREATE PROCEDURE [dbo].[BugNet_Role_RemoveUserFromRole] @UserName nvarchar(256), @RoleId Int AS DECLARE @UserId UNIQUEIDENTIFIER SELECT @UserId = UserId FROM Users WHERE UserName = @UserName DELETE BugNet_UserRoles WHERE UserId = @UserId AND RoleId = @RoleId
<filename>backend/de.metas.swat/de.metas.swat.base/src/main/sql/postgresql/system/48-de.metas.payment/5496810_sys_gh4221-app_add_M_DiscountSchemaBreak_PaymentDiscount.sql -- 2018-06-28T15:40:06.998 -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator INSERT INTO AD_Element (AD_Client_ID,AD_Element_ID,AD_Or...
-- MySQL -- HackerRank SQL Aggregation 15 -- https://www.hackerrank.com/challenges/weather-observation-station-18/problem -- Author: Hasol select round((max(LAT_N) - min(LAT_N)) + (max(LONG_W) - min(LONG_W)),4) from STATION;
select cast(null as int) as analysis_id, stratum_1, cast(null as varchar(255)) as stratum_2, count(*) as statistic_value, cast('UnmappedDataByDomain:SourceValueCnt' as varchar(255)) as measure_id into @scratchDatabaseSchema@schemaDelim@tempHeelPrefix_@heelName from @resultsDatabaseSchema.ACHILLES_results whe...
alter session SET NLS_DATE_FORMAT='dd/mm/rr hh24:mi:ss'; SELECT a.SID, a.SERIAL# serial, spid,SOFAR, TOTALWORK, ROUND(SOFAR/TOTALWORK*100,2) "%_COMPLETE", s.CLIENT_INFO FROM V$SESSION_LONGOPS a,V$PROCESS p, V$SESSION s WHERE a.sid=s.sid AND p.ADDR = s.PADDR AND CLIENT_INFO LIKE 'rman%' AND OPNAME LIKE 'RMAN%' AND OPNA...
-- phpMyAdmin SQL Dump -- version 4.8.5 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1:3306 -- Waktu pembuatan: 11 Okt 2019 pada 15.44 -- Versi server: 5.7.26 -- Versi PHP: 7.2.18 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTE...
/* Navicat Premium Data Transfer Source Server : 192.168.2.101_3306 Source Server Type : MySQL Source Server Version : 50728 Source Host : 192.168.2.101:3306 Source Schema : appversion Target Server Type : MySQL Target Server Version : 50728 File Encoding : 65001 Dat...
<gh_stars>0 # test schema # --- !Ups CREATE TABLE test ( id INT NOT NULL PRIMARY KEY, field_1 VARCHAR(45) NOT NULL, field_2 VARCHAR(45) NOT NULL, field_3 VARCHAR(45) NOT NULL, field_4 VARCHAR(45) NOT NULL, field_5 VARCHAR(45) NOT NULL, field_6 VARCHAR(45) NOT NULL, field_7 VARCHAR(45) ...
/* Insert statement for Currency */ INSERT INTO currency (id, entity_code, symbol, name, description) VALUES (1, 'USD', '$', 'US Dollar', 'US Dollar'); /* Insert statement for Location Type */ INSERT INTO locationtype (id, entity_code, name, description) VALUES (1, 'COUNTRY', 'Country', 'Country'); INSERT INTO locatio...
<filename>root_VS2019/files/resource/Sql/sqlserver/Workflow/SQL/Table/M_User_Insert(sample).sql USE [Workflow] GO INSERT INTO [dbo].[M_User]([Id], [Section], [Name], [PositionTitlesId]) VALUES (1 , 'AAAA' , 'A御中' , 1 ), (1000, 'AAAA' , 'AAAA0' , 1 ), (2 , 'BBBB' , 'B御中' , 1 ), (2000, 'BBBB' , 'BBBB0...
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Host: localhost -- Generation Time: Oct 06, 2020 at 06:30 AM -- Server version: 10.4.13-MariaDB -- PHP Version: 7.4.8 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIEN...
-- Copyright 2020 <NAME> -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writi...
-- -------------------------------------------------------- -- Хост: 127.0.0.1 -- Версия сервера: 10.4.11-MariaDB - mariadb.org binary distribution -- Операционная система: Win64 -- HeidiSQL Версия: 11.1.0.6116 -- -----------------------------------------------...
<filename>db/characters/get_char_closest.sql<gh_stars>10-100 SELECT * FROM characters WHERE name LIKE $1 ORDER BY char_id;
<filename>openGaussBase/testcase/SQL/DATATYPE/decimal/float/Opengauss_Function_Datatype_Float_Case0013.sql<gh_stars>0 -- @testpoint: 插入0值 drop table if exists float13; create table float13 (name float); insert into float13 values (0); insert into float13 values (0); insert into float13 values (0); select * from float1...
<filename>mydb/padi_hr(1)_06122018.sql<gh_stars>0 -- phpMyAdmin SQL Dump -- version 4.8.3 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1:3306 -- Waktu pembuatan: 06 Des 2018 pada 02.21 -- Versi server: 5.7.23 -- Versi PHP: 7.2.10 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET ...
<reponame>pntone/apex-flowsforapex create or replace PACKAGE BODY flow_notif_pkg AS FUNCTION get_transf_value ( in_value VARCHAR2 ) RETURN CLOB IS BEGIN IF instr(in_value, '&') = 1 THEN RETURN to_clob(v('''' || translate(in_value, '&.', '') ...
CREATE TABLE diseases( id int primary key identity(1, 1), diseaseName varchar(64) not null, treatment varchar(1024), startDate date not null, discharged boolean, patientId int not null foreign key references patients(id) );
<filename>25__F2__12_03_left-join.sql -- Listar todas as localidades cujos utentes nunca realizaram consulta SELECT CP.codigo_postal, CP.localidade FROM codigo_postal CP LEFT JOIN utente U ON CP.codigo_postal = U.codigo_postal LEFT JOIN consulta_medica CM ON U.numero_utente = CM.utente WHERE ...
# Write your MySQL query statement below SELECT DISTINCT a.num AS ConsecutiveNums FROM (SELECT num, (CASE WHEN @record = num THEN @count := @count + 1 WHEN @record := num THEN @count := 1 END) AS count_result FROM Logs, (SELECT @record := NULL, @count := 0)...
<reponame>ulvia-10/TA-SenyumDesa -- phpMyAdmin SQL Dump -- version 5.0.4 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Apr 01, 2021 at 09:23 AM -- Server version: 10.4.17-MariaDB -- PHP Version: 8.0.0 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!4...
<gh_stars>10-100 -- View: public."V_Poly_Elev" -- DROP VIEW public."V_Poly_Elev"; CREATE OR REPLACE VIEW public."V_Poly_Elev" AS SELECT "V_Stream_Activity".ath_id, st_expand(st_collect("V_Stream_Activity".point), (0.0005)::double precision) AS poly, avg("V_Stream_Activity".altitude) AS e FROM "V_Stream_...
<filename>resources/migrations/20190206000020-create-form_template_prompt-table.down.sql DROP TABLE IF EXISTS vetd.form_template_prompt;
<reponame>SergL77/SQLServerTools<filename>SQL-Server-TempDB/Информация о расположении данных временных таблица в базе.sql SELECT T.name, T.[object_id], AU.type_desc, AU.first_page, AU.data_pages, P.[rows] FROM tempdb.sys.tables AS T JOIN tempdb.sys.partitions AS P ON P.[object_id] = T.[objec...
<reponame>viswaratha12/dbwarden<gh_stars>0 /****** Object: Table [T_Instrument_Name_Bkup] ******/ /****** RowCount: 100 ******/ /****** Columns: IN_name, Instrument_ID, IN_class, IN_source_path_ID, IN_storage_path_ID, IN_capture_method, IN_default_CDburn_sched, IN_Room_Number, IN_Description, IN_Created ******/ INS...
<filename>DMS5/udfParseDelimitedListOrdered.sql /****** Object: UserDefinedFunction [dbo].[udfParseDelimitedListOrdered] ******/ SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO CREATE FUNCTION [dbo].[udfParseDelimitedListOrdered] /**************************************************** ** ** Parses the te...
<filename>schema/deploy/policies/certification_url_policies@v1.5.0.sql -- Deploy ggircs-portal:policies/certification_url_policies to pg -- requires: tables/certification_url begin; do $policy$ declare industry_user_statement text; certifier_user_statement text; begin -- ciip_administrator RLS per...
<gh_stars>10-100 select sum(lo_extendedprice * lo_discount) as revenue from denormalized where d_weeknuminyear = 6 and d_year = 1994 and lo_discount between 5 and 7 and lo_quantity between 26 and 35;
<filename>components/automate-workflow-server/schema/verify/scanner_add_nodes_secrets.sql -- Verify delivery:scanner_add_nodes_secrets on pg BEGIN; SELECT node_id, secret_id FROM nodes_secrets WHERE FALSE; ROLLBACK;
-- @author prabhd -- @created 2012-12-05 12:00:00 -- @modified 2012-12-05 12:00:00 -- @tags dml -- @db_name dmldb -- @skip MPP-19148 -- @description update_test22: Update on table wit composite distribution key \echo --start_ignore set gp_enable_column_oriented_table=on; \echo --end_ignore SELECT SUM(a) FROM dml_he...
<reponame>pratikpc/Pracs-Sem-V CREATE OR REPLACE function F1 (a integer) RETURNS integer as $$ DECLARE ret integer := 0; BEGIN if (a <= 2) THEN return a; ELSE return a * F1(a-1); END IF; RAISE Notice 'a is %',a; RETURN 0; END $$ language "plpgsql"; select * from F1(3);
<filename>insert_dolaze.sql --INSERT INTO dolaze(id,ime_i_prezime,razred_id) select ROW_NUMBER() OVER () row_number,IME_I_PREZIME,r.id from KO_DOLAZI k,razredi r where substr(k.razred,3,2)=substr(r.razred,4,2) order by r.id
<reponame>miku/jpul<gh_stars>1-10 START TRANSACTION; INSERT INTO options(`option`, `value`, `type`, `help`, `option_human`) VALUES ( 'activation-notification-bcc', '', 'string', 'Soll eine BCC der Arbeitgeber-Veröffentlichungs-Benachrichtigung-E-Mail an jemanden geschickt werden? Wenn ja, an wen? Falls keine BCC ...
INSERT Items(ID,Titel,Categorie,Postcode,Locatie,Land,Verkoper,Prijs,Valuta,Conditie,Thumbnail,Beschrijving) VALUES (120854575732,'WINNIE-DE-POEH EN MANAGEMENT - <NAME>',32680,'1601JP','Nederland','NL','haveanicedaytoday','5.0','EUR','Heel goed','img120854575732.jpg',' <TABLE CELLSPACING="28" CELLPADDING="0" WID...
<filename>server/service/store_procedure/funct_count_questions.sql<gh_stars>0 DELIMITER // DROP FUNCTION IF EXISTS `func_count_questions` // CREATE FUNCTION `func_count_questions`(the_user INT, the_word INT) RETURNS INT NOT DETERMINISTIC BEGIN DECLARE ret_count INT DEFAULT 0; -- check for no ask question DE...