------------------------------------------------------------------------------------------------------------

with a as (select distinct round(a.x + b.x) x,round(a.y + b.y) y from
(select (sum(x) over(order by n)) x,
round(sum(y) over(order by n)) y
from (select n, cos(n/30 * 3.1415926)*2 x,
sin(n/30 * 3.1415926) y
from (select rownum - 1 n from all_objects where rownum <= 30 +30))) a,
(select n, (sum(x) over(order by n)) x,
round(sum(y) over(order by n)) y
from (select n,
cos( m /3 * 3.1415926) * 2 * 15 x,
sin( m /3 * 3.1415926)* 15 y
from (select case when rownum <= 2 then 3
when rownum = 3 then -2 else -6 end m, rownum - 1 n
from all_objects where rownum <= 5))) b
)
select replace(sys_connect_by_path(point, '/'), '/', null) star
from (select b.y, b.x, decode(a.x, null, ' ', '*') point
from a,
(select *
from (select rownum - 1 + (select min(x) from a) x
from all_objects
where rownum <= (select max(x) - min(x) + 1 from a)),
(select rownum - 1 + (select min(y) from a) y
from all_objects
where rownum <= (select max(y) - min(y) + 1 from a))) b
where a.x(+) = b.x
and a.y(+) = b.y)
where x = (select max(x) from a)
start with x = (select min(x) from a)
connect by y = prior y
and x = prior x + 1;

----------------------------------------------------------------------

---------------------------------------------------------------------------------------------------

with a as (
select distinct round(sum(x) over(order by n)) x,
round(sum(y) over(order by n)) y
from (select n,
cos(trunc(n / 20) * (1-1/5) * 3.1415926) * 2 x,
sin(trunc(n / 20) * (1-1/5) * 3.1415926) y
from (select rownum - 1 n from all_objects where rownum <= 20 * 5))
)

select replace(sys_connect_by_path(point, '/'), '/', null) star
from (select b.y, b.x, decode(a.x, null, ' ', '*') point
from a,
(select *
from (select rownum - 1 + (select min(x) from a) x
from all_objects
where rownum <= (select max(x) - min(x) + 1 from a)),
(select rownum - 1 + (select min(y) from a) y
from all_objects
where rownum <= (select max(y) - min(y) + 1 from a))) b
where a.x(+) = b.x
and a.y(+) = b.y)
where x = (select max(x) from a)
start with x = (select min(x) from a)
connect by y = prior y
and x = prior x + 1;

sql画图的更多相关文章

  1. 画图解释SQL联合语句

    画图解释SQL联合语句 http://blog.jobbole.com/40443/ 我认为 Ligaya Turmelle 的关于SQL联合(join)语句的帖子对于新手开发者来说是份很好的材料.S ...

  2. 转:画图解释 SQL join 语句

    画图解释 SQL join 语句 我认为 Ligaya Turmelle 的关于SQL联合(join)语句的帖子对于新手开发者来说是份很好的材料.SQL 联合语句好像是基于集合的,用韦恩图来解释咋一看 ...

  3. ZEDGRAPH画图心得,SQL语句构造!!!

    /// <summary> /// 画折线 /// </summary> public void Drawline() { OleDbConnection odcConnect ...

  4. 画图解释 SQL join 语句

    转:http://blog.jobbole.com/40443/ 本文由 伯乐在线 - 奇风余谷 翻译.未经许可,禁止转载!英文出处:Jeff Atwood.欢迎加入翻译组. 我认为 Ligaya T ...

  5. SQL join 语句 画图果然更容易理解

    我认为 Ligaya Turmelle 的关于SQL联合(join)语句的帖子对于新手开发者来说是份很好的材料.SQL 联合语句好像是基于集合的,用韦恩图来解释咋一看是很自然而然的.不过正如在她的帖子 ...

  6. 数据分析画图,使用原生sql查询数据

    1.使用工具 https://www.hcharts.cn/ http://echarts.baidu.com/ 2.子表查询 id 创建时间 内容 处理者 1 2017-02-01 11:11 1 ...

  7. 【转载】十步完全理解SQL

    很多程序员视 SQL 为洪水猛兽.SQL 是一种为数不多的声明性语言,它的运行方式完全不同于我们所熟知的命令行语言.面向对象的程序语言.甚至是函数语言(尽管有些人认为 SQL 语言也是一种函数式语言) ...

  8. 转载文章----十步完全理解SQL

    转载地址:http://blog.jobbole.com/55086/ 很多程序员视 SQL 为洪水猛兽.SQL 是一种为数不多的声明性语言,它的运行方式完全不同于我们所熟知的命令行语言.面向对象的程 ...

  9. 十步完全理解SQL

    转载于:http://blog.jobbole.com/55086/ 很多程序员视 SQL 为洪水猛兽.SQL 是一种为数不多的声明性语言,它的运行方式完全不同于我们所熟知的命令行语言.面向对象的程序 ...

随机推荐

  1. 入门oj 5499: 讲话模式

    Description 每个人说话都有口头禅,现给出一个字符串,请求出其中出现次数最多的单词(不区分大小写). Input 输入一行,长度小于等于1048576的字符串输入至少包含一个字母或数字 Ou ...

  2. LeapMotion控制器 java语言开发笔记--(连接控制器)

    (1)为了连接LeapMotion控制器,创建controller对象,这个对象自动创建与控制器的服务或者后台程序连接,然后捕获数据提供给你的应用程序.可以使用该对象来获取连接信息. (2)获取Fra ...

  3. Centos7安装(本文档采用CentOS7 mini版本)

    选择[语言],点击[继续]等待出现以下界面 一.下载 centos: centos/7/isos/x86_64/CentOS-7-x86_64-Minimal-1611.iso 二.VMware Wo ...

  4. Kubernetes官方java客户端之六:OpenAPI基本操作

    欢迎访问我的GitHub https://github.com/zq2599/blog_demos 内容:所有原创文章分类汇总及配套源码,涉及Java.Docker.Kubernetes.DevOPS ...

  5. Python使用urllib,urllib3,requests库+beautifulsoup爬取网页

    Python使用urllib/urllib3/requests库+beautifulsoup爬取网页 urllib urllib3 requests 笔者在爬取时遇到的问题 1.结果不全 2.'抓取失 ...

  6. JavaScript—深入理解函数

    当程序在调用某个函数时,做了以下的工作:准备执行环境,初始函数作用域链和arguments参数对象. 函数的声明语句 function命令声明的代码区块,就是一个函数.function命令后面是函数名 ...

  7. C++ 简单输出当前日期时间

    根据https://www.runoob.com/cplusplus/cpp-date-time.html编写. 首先介绍2个数据类型. 一个是time_t,与时间函数相关的变量,定义的变量记录着自 ...

  8. Linux学习笔记 | 常见错误之账户密码正确但是登录不进去系统

    前言: 笔者今日由于Linux版本的原因,需要Linux内核版本不能太高的系统,而日常使用的ubuntu系统不能满足需求,于是新建了一个虚拟机,选用的系统是Ubuntu16的,配置了一下午的各种依赖环 ...

  9. 【Java】集合综合案例 - 播放器管理

    集合综合案例 文章目录 集合综合案例 需求分析 项目演示 详细设计 代码实现 歌曲类 播放器类 播放列表类 测试 参考资料 播放器管理 需求分析 项目演示 详细设计 代码实现 重新搞一波 复习巩固 简 ...

  10. 【ORA】ORA-19602: cannot backup or copy active file in NOARCHIVELOG mode

    ORA-19602: cannot backup or copy active file in NOARCHIVELOG mode 这个问题是rman备份的时候,发现有问题 原因: 数据库没有开启归档 ...