Skip to content

Instantly share code, notes, and snippets.


Leonid Bushuev leo-from-spb

View GitHub Profile
View Show DB Synthetic Stuff Option
When a user write a database creation script, they give names for most of database objects (i.e. table names,
column names, constraint names, etc). When the DB author performs this script using a DBMS it creates a database
that contains objects with the names specified in the script. If the author perfroms this script several times,
the result will be several database with the same object names (as specified in the script).
However, sometimes the DB author can omit some names (i.e. names of constraints, indices, etc.), in this case
the DBMS makes names for these objects automatically (usually by concatenating a hardcoded prefix with a kind of
random or sequential number). When the author performs their script several times, the result will be databases
with different names (because that names were not specified in the script). We call such auto-genertated names
synthetic ones. So, the mentioned option includes such auto-generated stuff.
View Билд-завис.txt
2018-06-19 21:00:31
Full thread dump Java HotSpot(TM) 64-Bit Server VM (25.171-b11 mixed mode):
"Attach Listener" #29 daemon prio=9 os_prio=0 tid=0x00007fd748001000 nid=0x28cf waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"DestroyJavaVM" #28 prio=5 os_prio=0 tid=0x00007fd774017800 nid=0x20c8 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"TimerQueue" #25 daemon prio=5 os_prio=0 tid=0x00007fd72527b000 nid=0x210a waiting on condition [0x00007fd72275d000]
View SQL-Inserts-MultirowSynthax.sql.groovy
SEP = ", "
QUOTE = "\'"
NEWLINE = System.getProperty("line.separator")
begin = true
def record(columns, dataRow) {
if (begin) {
OUT.append("INSERT INTO ")
leo-from-spb / fun42.sql
Created Oct 23, 2017
Postgres function result record
View fun42.sql
create function fun42(a integer, b integer, OUT c bigint, OUT d character varying)
returns record
language plpgsql
as $$
c = a + b;
d = c::varchar;
View idea_modifies_files_again_20171019.patch
Index: .idea/codeStyles/codeStyleConfig.xml
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
--- .idea/codeStyles/codeStyleConfig.xml (date 1508413887000)
+++ .idea/codeStyles/codeStyleConfig.xml (date 1508413887000)
@@ -0,0 +1,5 @@
+<component name="ProjectCodeStyleConfiguration">
+ <state>