Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

115
Views
Convertir variables SQL en copo de nieve

Estoy convirtiendo un procedimiento almacenado de SQL en copo de nieve, cuyo código es el siguiente:

 Create PROCEDURE <sp_name> (@parameter) AS BEGIN SET NOCOUNT ON Declare @A varchar(max), @B smallint = 0, @C int = 0, DECLARE @D smallint, @E smalldatetime, @F smallint

Necesito ayuda para entender cómo convertiré las variables anteriores en copos de nieve para que sean consumidas por la declaración sql.

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Buscaría Snowflake Scripting, puede usar variables en expresiones y declaraciones SQL. Esto debería tener la funcionalidad equivalente que está buscando.

https://docs.snowflake.com/en/developer-guide/snowflake-scripting/ https://docs.snowflake.com/en/sql-reference-snowflake-scripting.html https://docs.snowflake.com /es/guia-del-desarrollador/snowflake-scripting/variables.html#ejemplos-de-uso-de-variables

 create or replace procedure myprocedure() returns table(A varchar, B smallint, C integer, D smallint, E timestamp_ntz, F smallint) language SQL as $$ declare A varchar default null; B smallint default 0; C integer default 0; D smallint default -1; E timestamp_ntz default current_timestamp(); F smallint default 0; res RESULTSET default (select :A,:B,:C,:D,:E,:F); begin return table(res); end $$ ; call myprocedure(); ABCDEF 0 0 -1 2022-02-23 11:53:21.230 0
about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!