07 2021 档案

摘要:CREATE FUNCTION fu_getwords(@cc VARCHAR(100))RETURNS VARCHAR(100)ASbeginDECLARE @n INT,@i INT,@clearstr VARCHAR(100),@gg VARCHAR(10)SET @n=LEN(@cc)SET 阅读全文

posted @ 2021-07-28 16:06 打杂滴 阅读(148) 评论(0) 推荐(0) 编辑 |

摘要:sdt=`date -d"$(date -d'20210108 ' +'%Y%m01')" +"%Y%m%d"`edt=`date -d "$(date -d '20210104' +'%Y%m%d')" +"%Y%m%d"`echo $sdt,$edttb="tt"while [[ $sdt -l 阅读全文

posted @ 2021-07-28 13:42 打杂滴 阅读(87) 评论(0) 推荐(0) 编辑 |

摘要:IP转为bigint create function [dbo].[iptobigint](@ipinfo varchar(16)) returns bigint as begin declare @ret bigint if PATINDEX('%[^.0-9]%',@ipinfo)>0 retu 阅读全文

posted @ 2021-07-14 16:43 打杂滴 阅读(128) 评论(0) 推荐(0) 编辑 |

摘要:explode称之为Hive爆炸函数,意思就是将一行数据炸开。Usage:explode(array/map) explode函数传递的参数必须是一个array或者是map hivescala> spark.sql("select explode(split('41,52,62,35&98','[, 阅读全文

posted @ 2021-07-06 15:39 打杂滴 阅读(252) 评论(0) 推荐(0) 编辑 |

摘要:随机生成100以内的整数 select top 10 number,ceiling(rand(checksum(newid()))*100) from master.dbo.spt_valueswhere type='p' 阅读全文

posted @ 2021-07-06 14:31 打杂滴 阅读(187) 评论(0) 推荐(0) 编辑 |

摘要:mysql> SELECT a.user, @i:=@i+1 as id FROM user a,(SELECT @i:=0) b; + + +| user | id |+ + +| hive | 1 || root | 2 || mysql.infoschema | 3 || mysql.sess 阅读全文

posted @ 2021-07-06 14:22 打杂滴 阅读(623) 评论(0) 推荐(0) 编辑 |

摘要:import org.apache.spark.graphx._import org.apache.spark.rdd.RDDval vertexArray = Array( (1L, ("Alice", 28)), (2L, ("Bob", 27)), (3L, ("Charlie", 65)), 阅读全文

posted @ 2021-07-01 15:13 打杂滴 阅读(177) 评论(0) 推荐(0) 编辑 |

随笔 - 224, 文章 - 0, 评论 - 1, 阅读 - 12万

Copyright © 2025 打杂滴
Powered by .NET 9.0 on Kubernetes

点击右上角即可分享
微信分享提示