This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var state = true; | |
var i = 0; | |
while (state){ | |
i += 1; | |
if (i >= 9){ | |
state = false; | |
} | |
console.log("i: ", i); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
task :send_weekly_report => :environment do | |
Ticket.send_weekly_report | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
USE [OMNIA_ESUM_P_SUMD_CM] | |
GO | |
/****** Object: StoredProcedure [dbo].[DAIS_FST_TT_Close_Update] Script Date: 7/18/2017 8:57:15 AM ******/ | |
SET ANSI_NULLS ON | |
GO | |
SET QUOTED_IDENTIFIER ON | |
GO |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CSV.open("test_file.txt", "w+", {force_quotes: false}) do |csv| | |
csv << ["#{ticket.attributes['TroubleTicketCreateDate'].strftime("%H:%M:%S")} | |
|#{ticket.attributes['TroubleTicketNumber']} | |
|#{ticket.attributes['WireCenter']}"] | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def invalid_match | |
@match_not_found = [ | |
:match_found => false, | |
:transfer_flag => false | |
] | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def validate(item, offering_type) | |
if item == offering_type | |
"1" | |
else | |
"0" | |
end | |
end | |
CSV.open("tve-export.csv", "w") do |csv| | |
csv << ["HBO"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
USE [TVAnywhere] | |
GO | |
/****** Object: StoredProcedure [dbo].[TVAnywhereNameAccountIDRefresh] Script Date: 6/13/2017 11:08:24 PM ******/ | |
SET ANSI_NULLS ON | |
GO | |
SET QUOTED_IDENTIFIER ON | |
GO |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
USE [OMNIA_ESUM_P_SUM_CM] | |
GO | |
/****** Object: StoredProcedure [dbo].[SUM_TVAnywhere] Script Date: 6/13/2017 11:05:07 PM ******/ | |
SET ANSI_NULLS ON | |
GO | |
SET QUOTED_IDENTIFIER ON | |
GO |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
using std::cout; | |
using std::endl; | |
int main(){ | |
int a = 10; | |
if (a > 0){ | |
a = 0; | |
} else { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ENV["lookup_phone_query"]="select distinct dd.AccountCode,dd.AccountID,dd.BalanceCurrent,dd.Phone,'Summit' as Property | |
,fm.Id,fm.sMAC,fm.sSerialNumber,fm.EQUIPMENTTYPE_Name,fm.Comment,fm.ADDRESS_Zip,fm.iItemID,ServiceStatus,fm.iVideoSystemID,fm.PrdWireCenter_WireCenter as WireCenter | |
from | |
(select distinct dd.AccountCode,dd.AccountID,dd.BalanceCurrent,coalesce(pp.phone,dd.Phone) as Phone,ServiceStatus from | |
(select distinct ar.AccountCode,ca.AccountID,ar.BalanceCurrent, | |
coalesce( | |
nc.PHONE,nc.AlternatePhone) as Phone,sv.ServiceStatus from | |
[OMNIA_ESUM_P_SUM_AR].[dbo].[ArAccount] ar | |
left join [OMNIA_ESUM_P_SUM_CM].[dbo].[CusAccount]ca on ar.AccountCode=ca.AccountCode | |
left join [OMNIA_ESUM_P_SUM_CM].[dbo].[SrvService]sv on ca.AccountID=sv.AccountID |