Для PostgreSQL появилась #opensource поддержка C# и F# как языков процедур.
Внутри используется модифицированная библиотека Npgsql, в которой сетевые вызовы заменены на прямые вызовы функций бд. Это позволяет писать в хранимых процедурах такой же код, как при работе с базой через библиотеку, с привычными Npgsql типами.
CREATE OR REPLACE FUNCTION dynamic_record_generator_srf(lim INT8) RETURNS SETOF record AS $$ upperLimit = lim.HasValue ? lim : System.Int32.MaxValue; for(long i=0;i<upperLimit;i++){ yield return new object?[] { i, $"Number is {i}" }; } $$ LANGUAGE plcsharp;
CREATE OR REPLACE FUNCTION dynamic_record_generator_srf_fsharp(lim INT8) RETURNS SETOF record AS $$ let upperLimit = Option.defaultValue (int64 System.Int32.MaxValue) lim seq { for i in 0L .. upperLimit - 1L do yield [| box i; $"Number is {i}" |] } $$ LANGUAGE plfsharp;
Для PostgreSQL появилась #opensource поддержка C# и F# как языков процедур.
Внутри используется модифицированная библиотека Npgsql, в которой сетевые вызовы заменены на прямые вызовы функций бд. Это позволяет писать в хранимых процедурах такой же код, как при работе с базой через библиотеку, с привычными Npgsql типами.
CREATE OR REPLACE FUNCTION dynamic_record_generator_srf(lim INT8) RETURNS SETOF record AS $$ upperLimit = lim.HasValue ? lim : System.Int32.MaxValue; for(long i=0;i<upperLimit;i++){ yield return new object?[] { i, $"Number is {i}" }; } $$ LANGUAGE plcsharp;
CREATE OR REPLACE FUNCTION dynamic_record_generator_srf_fsharp(lim INT8) RETURNS SETOF record AS $$ let upperLimit = Option.defaultValue (int64 System.Int32.MaxValue) lim seq { for i in 0L .. upperLimit - 1L do yield [| box i; $"Number is {i}" |] } $$ LANGUAGE plfsharp;
Bitcoin is a decentralized digital currency that you can buy, sell and exchange directly, without an intermediary like a bank. Bitcoin’s creator, Satoshi Nakamoto, originally described the need for “an electronic payment system based on cryptographic proof instead of trust.” Each and every Bitcoin transaction that’s ever been made exists on a public ledger accessible to everyone, making transactions hard to reverse and difficult to fake. That’s by design: Core to their decentralized nature, Bitcoins aren’t backed by the government or any issuing institution, and there’s nothing to guarantee their value besides the proof baked in the heart of the system. “The reason why it’s worth money is simply because we, as people, decided it has value—same as gold,” says Anton Mozgovoy, co-founder & CEO of digital financial service company Holyheld.
What is Telegram?
Telegram is a cloud-based instant messaging service that has been making rounds as a popular option for those who wish to keep their messages secure. Telegram boasts a collection of different features, but it’s best known for its ability to secure messages and media by encrypting them during transit; this prevents third-parties from snooping on messages easily. Let’s take a look at what Telegram can do and why you might want to use it.