User Profile


person albydarned   starPREMIUM

Member since 08/6/2019


Karma

9

Public Bits


1
Posted by albydarned 1 year ago
        
SELECT 
   SCHEMA_NAME(SCHEMA_ID) AS [Schema]
  ,SO.name AS [ObjectName]			   
  ,SO.Type_Desc AS [Ob...        
      
MORE

2
Posted by albydarned 2 years ago
        
import os
if not os.path.exists('my_folder'):
    os.makedirs('my_folder')        
      

1
Posted by albydarned 2 years ago
        
import subprocess
subprocess.run(["ls", "-l"])        
      

0
Posted by albydarned 2 years ago
How to use the OAuth2 Library (https://github.com/scrogson/oauth2) to connect with GitHub in Elixir. ...
        
defmodule App.GitHub do
  use OAuth2.Strategy

  # Public API

  def client do
    OAuth2.Client.new(...        
      
MORE

0
Posted by albydarned 2 years ago
From: https://docs.microsoft.com/en-us/sql/t-sql/functions/row-number-transact-sql?view=sql-server-ve...
        
SELECT 
  ROW_NUMBER() OVER(ORDER BY name ASC) AS Row#,
  name, recovery_model_desc
FROM sys.database...        
      
MORE

0
Posted by albydarned 3 years ago
Credit: https://blog.sqlauthority.com/2016/06/07/sql-server-much-free-space-database/
        
SELECT
   SUBSTRING(a.FILENAME, 1, 1) Drive,
   [FILE_SIZE_MB] = convert(decimal(12, 2), round(a.size...        
      
MORE

0
Posted by albydarned 3 years ago
How to pass arguments to system.util.invokeAsynchronous in Inductive Automation Ignition using a pyth...
        
from functools import partial

def myfunc(someArg1, someArg2, optionalKwarg=None, optionalKwarg2=None...        
      
MORE

1
Posted by albydarned 3 years ago
As you may know, COUNT(*) if often very slow on large tables. With this query I have been able to que...
        
SELECT SUM (row_count)
FROM sys.dm_db_partition_stats
WHERE object_id=OBJECT_ID('TableName')   
AND (...        
      
MORE

1
Posted by albydarned 3 years ago
        
<?php echo "Hello there, world!" ?>        
      

0
Posted by albydarned 3 years ago
Useful snippet for converting millisecond timestamp to date in MS SQL Server
        
DECLARE @UTC BIGINT
SET @UTC = 1348203320997 

-- This is a comment

SELECT DATEADD(MILLISECOND, @UTC...        
      
MORE

2
Posted by albydarned 3 years ago
From pythonforbeginners.com
        
# Import the modules
import sys
import random

ans = True

while ans:
    question = raw_input("Ask t...        
      
MORE