[SPARK-15863][SQL][DOC] Initial SQL programming guide update for Spark 2.0
[SPARK-15863][SQL][DOC] Initial SQL programming guide update for Spark 2.0

## What changes were proposed in this pull request?

Initial SQL programming guide update for Spark 2.0. Contents like 1.6 to 2.0 migration guide are still incomplete.

We may also want to add more examples for Scala/Java Dataset typed transformations.

## How was this patch tested?

N/A

Author: Cheng Lian <lian@databricks.com>

Closes #13592 from liancheng/sql-programming-guide-2.0.

dbtsai/spark,hhbyyh/spark,esi-mineset/spark,publicRoman/spark,Aegeaner/spark,LantaoJin/spark,mike0sv/spark,vinodkc/spark,skonto/spark,adrian-ionescu/apache-spark,shuangshuangwang/spark,WeichenXu123/spark,caneGuy/spark,liyichao/spark,bOOm-X/spark,skonto/spark,metamx/spark,poffuomo/spark,mdespriee/spark,publicRoman/spark,shubhamchopra/spark,huang1900/spark,patrick-nicholson/spark,zuotingbing/spark,debugger87/spark,zuotingbing/spark,zuotingbing/spark,ajaysaini725/spark,maropu/spark,aokolnychyi/spark,JerryLead/spark,icexelloss/spark,jrshust/spark,ueshin/apache-spark,hvanhovell/spark,metamx/spark,icexelloss/spark,jianran/spark,jianran/spark,bravo-zhang/spark,actuaryzhang/spark,sureshthalamati/spark,milliman/spark,actuaryzhang/spark,SnappyDataInc/spark,cin/spark,szhem/spark,stanzhai/spark,zhouyejoe/spark,brad-kaiser/spark,witgo/spark,nilsgrabbert/spark,janewangfb/spark,aray/spark,ptkool/spark,spark-test/spark,rikima/spark,poffuomo/spark,adrian-ionescu/apache-spark,joseph-torres/spark,guoxiaolongzte/spark,loneknightpy/spark,publicRoman/spark,patrick-nicholson/spark,BryanCutler/spark,ddna1021/spark,patrick-nicholson/spark,minixalpha/spark,jkbradley/spark,janewangfb/spark,dhruve/spark,kevinyu98/spark,jlopezmalla/spark,jianran/spark,big-pegasus/spark,lvdongr/spark,michalsenkyr/spark,xuanyuanking/spark,kiszk/spark,michalsenkyr/spark,eyalfa/spark,wzhfy/spark,michalsenkyr/spark,rekhajoshm/spark,lvdongr/spark,sachintyagi22/spark,mahak/spark,lvdongr/spark,mdespriee/spark,adrian-ionescu/apache-spark,lvdongr/spark,publicRoman/spark,wangmiao1981/spark,caneGuy/spark,aokolnychyi/spark,debugger87/spark,hhbyyh/spark,map222/spark,shuangshuangwang/spark,icexelloss/spark,wangmiao1981/spark,jiangxb1987/spark,WeichenXu123/spark,zero323/spark,debugger87/spark,mzl9039/spark,apache-spark-on-k8s/spark,shuangshuangwang/spark,witgo/spark,sachintyagi22/spark,kissmetrics/spark,janewangfb/spark,shaneknapp/spark,ibm-research-ireland/sparkoscope,UndeadBaneGitHub/spark,setjet/spark,wzhfy/spark,rekhajoshm/spark,liutang123/spark,bOOm-X/spark,WeichenXu123/spark,guoxiaolongzte/spark,brad-kaiser/spark,byakuinss/spark,wangyum/spark,eyalfa/spark,srowen/spark,JoshRosen/spark,alunarbeach/spark,saltstar/spark,ioana-delaney/spark,narahari92/spark,kimoonkim/spark,ron8hu/spark,hvanhovell/spark,cloud-fan/spark,guoxiaolongzte/spark,joseph-torres/spark,maropu/spark,ron8hu/spark,someorz/spark,ptkool/spark,map222/spark,michalsenkyr/spark,byakuinss/spark,narahari92/spark,kissmetrics/spark,bdrillard/spark,apache/spark,tengpeng/spark,panfengfeng/spark,huang1900/spark,apache/spark,WindCanDie/spark,maropu/spark,akopich/spark,apache/spark,saltstar/spark,narahari92/spark,MLnick/spark,wangmiao1981/spark,skonto/spark,mdespriee/spark,spark-test/spark,SnappyDataInc/spark,andrewor14/spark,saturday-shi/spark,debugger87/spark,rikima/spark,icexelloss/spark,actuaryzhang/spark,shuangshuangwang/spark,rekhajoshm/spark,LantaoJin/spark,JoshRosen/spark,mike0sv/spark,hvanhovell/spark,goldmedal/spark,ioana-delaney/spark,tejasapatil/spark,pgandhi999/spark,akopich/spark,loneknightpy/spark,apache-spark-on-k8s/spark,esi-mineset/spark,dhruve/spark,zzcclp/spark,big-pegasus/spark,rekhajoshm/spark,nilsgrabbert/spark,ericvandenbergfb/spark,tejasapatil/spark,Aegeaner/spark,Panos-Bletsos/spark-cost-model-optimizer,liyichao/spark,kissmetrics/spark,nchammas/spark,sachintyagi22/spark,Panos-Bletsos/spark-cost-model-optimizer,nchammas/spark,yanboliang/spark,shuangshuangwang/spark,jrshust/spark,wangyum/spark,kimoonkim/spark,taroplus/spark,jiangxb1987/spark,darionyaphet/spark,ptkool/spark,JerryLead/spark,saltstar/spark,srowen/spark,darionyaphet/spark,ueshin/apache-spark,maropu/spark,shubhamchopra/spark,ajaysaini725/spark,dongjoon-hyun/spark,dongjoon-hyun/spark,darionyaphet/spark,zuotingbing/spark,jkbradley/spark,SHASHANKB/spark,kevinyu98/spark,Aegeaner/spark,dbtsai/spark,jiangxb1987/spark,hvanhovell/spark,stanzhai/spark,UndeadBaneGitHub/spark,actuaryzhang/spark,tejasapatil/spark,jrshust/spark,alunarbeach/spark,taroplus/spark,markhamstra/spark,ahnqirage/spark,mahak/spark,srowen/spark,HyukjinKwon/spark,nlalevee/spark,sureshthalamati/spark,shaneknapp/spark,milliman/spark,pgandhi999/spark,wangyum/spark,aray/spark,rednaxelafx/apache-spark,andrewor14/spark,chuckchen/spark,jrshust/spark,vinodkc/spark,skonto/spark,BryanCutler/spark,hhbyyh/spark,mzl9039/spark,tejasapatil/spark,michalsenkyr/spark,Aegeaner/spark,ueshin/apache-spark,caneGuy/spark,ibm-research-ireland/sparkoscope,cloud-fan/spark,aray/spark,zero323/spark,HyukjinKwon/spark,alunarbeach/spark,SnappyDataInc/spark,wangmiao1981/spark,panfengfeng/spark,jrshust/spark,bdrillard/spark,JerryLead/spark,kiszk/spark,jianran/spark,cloud-fan/spark,cin/spark,ConeyLiu/spark,zhouyejoe/spark,sahilTakiar/spark,mdespriee/spark,markhamstra/spark,metamx/spark,rezasafi/spark,JoshRosen/spark,spark-test/spark,map222/spark,xuanyuanking/spark,mahak/spark,LantaoJin/spark,highfei2011/spark,setjet/spark,szhem/spark,kimoonkim/spark,1haodian/spark,mzl9039/spark,facaiy/spark,shaneknapp/spark,techaddict/spark,xuanyuanking/spark,zhouyejoe/spark,big-pegasus/spark,goldmedal/spark,holdenk/spark,loneknightpy/spark,gengliangwang/spark,alunarbeach/spark,zhouyejoe/spark,bravo-zhang/spark,sachintyagi22/spark,chuckchen/spark,ioana-delaney/spark,ptkool/spark,adrian-ionescu/apache-spark,zhouyejoe/spark,WeichenXu123/spark,ibm-research-ireland/sparkoscope,apache/spark,nlalevee/spark,Panos-Bletsos/spark-cost-model-optimizer,sureshthalamati/spark,shubhamchopra/spark,kevinyu98/spark,ddna1021/spark,gengliangwang/spark,huang1900/spark,spark-test/spark,mzl9039/spark,icexelloss/spark,poffuomo/spark,janewangfb/spark,wzhfy/spark,setjet/spark,ddna1021/spark,nlalevee/spark,mike0sv/spark,liutang123/spark,aosagie/spark,wzhfy/spark,apache/spark,goldmedal/spark,ConeyLiu/spark,chuckchen/spark,UndeadBaneGitHub/spark,kimoonkim/spark,techaddict/spark,sahilTakiar/spark,zzcclp/spark,rednaxelafx/apache-spark,caneGuy/spark,srowen/spark,cin/spark,sachintyagi22/spark,HyukjinKwon/spark,ibm-research-ireland/sparkoscope,WindCanDie/spark,pgandhi999/spark,bdrillard/spark,andrewor14/spark,saturday-shi/spark,kimoonkim/spark,mzl9039/spark,witgo/spark,highfei2011/spark,Panos-Bletsos/spark-cost-model-optimizer,xflin/spark,setjet/spark,SHASHANKB/spark,maropu/spark,ajaysaini725/spark,cin/spark,michalsenkyr/spark,tejasapatil/spark,gengliangwang/spark,zero323/spark,facaiy/spark,mike0sv/spark,hhbyyh/spark,huang1900/spark,esi-mineset/spark,vinodkc/spark,sahilTakiar/spark,map222/spark,nlalevee/spark,hvanhovell/spark,sureshthalamati/spark,vinodkc/spark,MLnick/spark,HyukjinKwon/spark,publicRoman/spark,WindCanDie/spark,cloud-fan/spark,kimoonkim/spark,akopich/spark,JerryLead/spark,gengliangwang/spark,map222/spark,actuaryzhang/spark,ConeyLiu/spark,nilsgrabbert/spark,jlopezmalla/spark,goldmedal/spark,rednaxelafx/apache-spark,wzhfy/spark,saturday-shi/spark,liutang123/spark,poffuomo/spark,shubhamchopra/spark,guoxiaolongzte/spark,someorz/spark,liutang123/spark,LantaoJin/spark,rezasafi/spark,bravo-zhang/spark,ptkool/spark,actuaryzhang/spark,ConeyLiu/spark,loneknightpy/spark,dbtsai/spark,JerryLead/spark,chuckchen/spark,HyukjinKwon/spark,jiangxb1987/spark,dongjoon-hyun/spark,spark-test/spark,liutang123/spark,facaiy/spark,bravo-zhang/spark,big-pegasus/spark,rikima/spark,metamx/spark,1haodian/spark,kevinyu98/spark,byakuinss/spark,cloud-fan/spark,guoxiaolongzte/spark,BryanCutler/spark,liutang123/spark,kimoonkim/spark,someorz/spark,MLnick/spark,maropu/spark,esi-mineset/spark,zhouyejoe/spark,darionyaphet/spark,stanzhai/spark,zzcclp/spark,byakuinss/spark,nchammas/spark,LantaoJin/spark,mahak/spark,shaneknapp/spark,aokolnychyi/spark,stanzhai/spark,alunarbeach/spark,aosagie/spark,xflin/spark,BryanCutler/spark,maropu/spark,mahak/spark,apache/spark,caneGuy/spark,sureshthalamati/spark,jiangxb1987/spark,wangyum/spark,liyichao/spark,JoshRosen/spark,facaiy/spark,JerryLead/spark,taroplus/spark,spark-test/spark,jianran/spark,esi-mineset/spark,Panos-Bletsos/spark-cost-model-optimizer,WindCanDie/spark,milliman/spark,highfei2011/spark,akopich/spark,eyalfa/spark,gengliangwang/spark,alunarbeach/spark,esi-mineset/spark,shaneknapp/spark,sahilTakiar/spark,shuangshuangwang/spark,ptkool/spark,ueshin/apache-spark,loneknightpy/spark,sahilTakiar/spark,vinodkc/spark,shaneknapp/spark,jlopezmalla/spark,saturday-shi/spark,lxsmnv/spark,adrian-ionescu/apache-spark,UndeadBaneGitHub/spark,yanboliang/spark,sachintyagi22/spark,dbtsai/spark,ron8hu/spark,yanboliang/spark,debugger87/spark,skonto/spark,huang1900/spark,xuanyuanking/spark,wangmiao1981/spark,WeichenXu123/spark,WeichenXu123/spark,Panos-Bletsos/spark-cost-model-optimizer,someorz/spark,lxsmnv/spark,witgo/spark,dhruve/spark,nlalevee/spark,wzhfy/spark,aosagie/spark,ddna1021/spark,zhouyejoe/spark,ron8hu/spark,saltstar/spark,ericvandenbergfb/spark,sachintyagi22/spark,minixalpha/spark,aray/spark,apache-spark-on-k8s/spark,dhruve/spark,MLnick/spark,lxsmnv/spark,taroplus/spark,ioana-delaney/spark,liyichao/spark,nchammas/spark,ahnqirage/spark,eyalfa/spark,jkbradley/spark,apache-spark-on-k8s/spark,debugger87/spark,rednaxelafx/apache-spark,milliman/spark,ahnqirage/spark,ericvandenbergfb/spark,lvdongr/spark,saturday-shi/spark,big-pegasus/spark,Aegeaner/spark,bOOm-X/spark,dbtsai/spark,szhem/spark,holdenk/spark,xuanyuanking/spark,ConeyLiu/spark,ajaysaini725/spark,minixalpha/spark,map222/spark,debugger87/spark,loneknightpy/spark,markhamstra/spark,someorz/spark,milliman/spark,xflin/spark,bOOm-X/spark,kevinyu98/spark,mdespriee/spark,darionyaphet/spark,1haodian/spark,witgo/spark,holdenk/spark,poffuomo/spark,aokolnychyi/spark,andrewor14/spark,liyichao/spark,bdrillard/spark,rikima/spark,rekhajoshm/spark,narahari92/spark,cin/spark,wangmiao1981/spark,nlalevee/spark,bravo-zhang/spark,1haodian/spark,saturday-shi/spark,markhamstra/spark,ahnqirage/spark,BryanCutler/spark,aokolnychyi/spark,tengpeng/spark,skonto/spark,ibm-research-ireland/sparkoscope,rezasafi/spark,brad-kaiser/spark,mike0sv/spark,shubhamchopra/spark,techaddict/spark,kissmetrics/spark,minixalpha/spark,shubhamchopra/spark,tengpeng/spark,joseph-torres/spark,joseph-torres/spark,SHASHANKB/spark,techaddict/spark,panfengfeng/spark,jkbradley/spark,nlalevee/spark,poffuomo/spark,JoshRosen/spark,stanzhai/spark,gengliangwang/spark,panfengfeng/spark,saturday-shi/spark,srowen/spark,nchammas/spark,shubhamchopra/spark,sureshthalamati/spark,setjet/spark,milliman/spark,ueshin/apache-spark,saltstar/spark,JerryLead/spark,rezasafi/spark,ahnqirage/spark,zero323/spark,JoshRosen/spark,aray/spark,srowen/spark,SHASHANKB/spark,kiszk/spark,poffuomo/spark,zuotingbing/spark,panfengfeng/spark,zzcclp/spark,xflin/spark,cloud-fan/spark,narahari92/spark,jianran/spark,rezasafi/spark,publicRoman/spark,metamx/spark,aray/spark,highfei2011/spark,SHASHANKB/spark,hhbyyh/spark,cin/spark,ioana-delaney/spark,ron8hu/spark,alunarbeach/spark,BryanCutler/spark,holdenk/spark,dongjoon-hyun/spark,bOOm-X/spark,facaiy/spark,joseph-torres/spark,mike0sv/spark,brad-kaiser/spark,holdenk/spark,aosagie/spark,Panos-Bletsos/spark-cost-model-optimizer,ron8hu/spark,shuangshuangwang/spark,setjet/spark,wzhfy/spark,szhem/spark,lxsmnv/spark,taroplus/spark,ahnqirage/spark,ericvandenbergfb/spark,mzl9039/spark,darionyaphet/spark,eyalfa/spark,jlopezmalla/spark,eyalfa/spark,apache-spark-on-k8s/spark,techaddict/spark,hhbyyh/spark,dongjoon-hyun/spark,ericvandenbergfb/spark,esi-mineset/spark,kissmetrics/spark,gengliangwang/spark,pgandhi999/spark,goldmedal/spark,caneGuy/spark,dhruve/spark,1haodian/spark,icexelloss/spark,mahak/spark,nilsgrabbert/spark,kiszk/spark,ibm-research-ireland/sparkoscope,panfengfeng/spark,joseph-torres/spark,rekhajoshm/spark,markhamstra/spark,stanzhai/spark,huang1900/spark,lvdongr/spark,WindCanDie/spark,WeichenXu123/spark,vinodkc/spark,SnappyDataInc/spark,bravo-zhang/spark,sahilTakiar/spark,goldmedal/spark,ioana-delaney/spark,dbtsai/spark,rezasafi/spark,zzcclp/spark,actuaryzhang/spark,jlopezmalla/spark,ajaysaini725/spark,facaiy/spark,rednaxelafx/apache-spark,stanzhai/spark,1haodian/spark,wangyum/spark,ahnqirage/spark,kevinyu98/spark,wangmiao1981/spark,aosagie/spark,nilsgrabbert/spark,zero323/spark,techaddict/spark,pgandhi999/spark,kissmetrics/spark,yanboliang/spark,MLnick/spark,patrick-nicholson/spark,metamx/spark,ConeyLiu/spark,nchammas/spark,nchammas/spark,mdespriee/spark,ddna1021/spark,big-pegasus/spark,pgandhi999/spark,dongjoon-hyun/spark,hvanhovell/spark,holdenk/spark,jlopezmalla/spark,ueshin/apache-spark,jrshust/spark,apache-spark-on-k8s/spark,kiszk/spark,byakuinss/spark,mdespriee/spark,witgo/spark,yanboliang/spark,wangyum/spark,HyukjinKwon/spark,bravo-zhang/spark,techaddict/spark,byakuinss/spark,ibm-research-ireland/sparkoscope,jkbradley/spark,aokolnychyi/spark,ajaysaini725/spark,hvanhovell/spark,markhamstra/spark,vinodkc/spark,LantaoJin/spark,ddna1021/spark,1haodian/spark,MLnick/spark,liutang123/spark,ptkool/spark,zuotingbing/spark,cin/spark,brad-kaiser/spark,guoxiaolongzte/spark,BryanCutler/spark,lxsmnv/spark,guoxiaolongzte/spark,akopich/spark,chuckchen/spark,lvdongr/spark,szhem/spark,darionyaphet/spark,jkbradley/spark,UndeadBaneGitHub/spark,big-pegasus/spark,rikima/spark,jiangxb1987/spark,andrewor14/spark,Aegeaner/spark,shaneknapp/spark,jrshust/spark,ericvandenbergfb/spark,loneknightpy/spark,zero323/spark,dhruve/spark,akopich/spark,SnappyDataInc/spark,MLnick/spark,skonto/spark,ueshin/apache-spark,bOOm-X/spark,patrick-nicholson/spark,akopich/spark,ioana-delaney/spark,dbtsai/spark,JoshRosen/spark,yanboliang/spark,caneGuy/spark,mzl9039/spark,aosagie/spark,xuanyuanking/spark,brad-kaiser/spark,janewangfb/spark,markhamstra/spark,huang1900/spark,liyichao/spark,byakuinss/spark,aokolnychyi/spark,SnappyDataInc/spark,rikima/spark,jlopezmalla/spark,xflin/spark,taroplus/spark,kevinyu98/spark,setjet/spark,highfei2011/spark,rednaxelafx/apache-spark,taroplus/spark,facaiy/spark,adrian-ionescu/apache-spark,ConeyLiu/spark,panfengfeng/spark,kissmetrics/spark,szhem/spark,matthewfranglen/spark,chuckchen/spark,witgo/spark,tengpeng/spark,apache/spark,xuanyuanking/spark,aosagie/spark,yanboliang/spark,WindCanDie/spark,mike0sv/spark,milliman/spark,hhbyyh/spark,nilsgrabbert/spark,ajaysaini725/spark,Aegeaner/spark,tejasapatil/spark,cloud-fan/spark,bOOm-X/spark,liyichao/spark,ericvandenbergfb/spark,minixalpha/spark,highfei2011/spark,aray/spark,pgandhi999/spark,icexelloss/spark,janewangfb/spark,zzcclp/spark,patrick-nicholson/spark,UndeadBaneGitHub/spark,lxsmnv/spark,metamx/spark,bdrillard/spark,HyukjinKwon/spark,map222/spark,minixalpha/spark,andrewor14/spark,tengpeng/spark,kiszk/spark,mahak/spark,SnappyDataInc/spark,SHASHANKB/spark,lxsmnv/spark,tengpeng/spark,someorz/spark,dongjoon-hyun/spark,jkbradley/spark,sureshthalamati/spark,narahari92/spark,bdrillard/spark,rikima/spark,michalsenkyr/spark,UndeadBaneGitHub/spark,rezasafi/spark,andrewor14/spark,jiangxb1987/spark,ron8hu/spark,nilsgrabbert/spark,zero323/spark,rednaxelafx/apache-spark,srowen/spark,apache-spark-on-k8s/spark,jianran/spark,SHASHANKB/spark,publicRoman/spark,tejasapatil/spark,brad-kaiser/spark,janewangfb/spark,spark-test/spark,LantaoJin/spark,xflin/spark,eyalfa/spark,tengpeng/spark,minixalpha/spark,bdrillard/spark,sahilTakiar/spark,zzcclp/spark,rekhajoshm/spark,kiszk/spark,chuckchen/spark,goldmedal/spark,xflin/spark,zuotingbing/spark,joseph-torres/spark,saltstar/spark,holdenk/spark,dhruve/spark,wangyum/spark,patrick-nicholson/spark,ddna1021/spark,saltstar/spark,highfei2011/spark,adrian-ionescu/apache-spark,narahari92/spark,WindCanDie/spark,someorz/spark,szhem/spark