永发信息网

ORA-00923: 未找到要求的 FROM

答案:3  悬赏:10  手机版
解决时间 2021-04-11 07:56
SELECt
VIPCARD.FFreezeStatus AS FREEZESTATUS,
VIPCARD.FCardStatus AS CARDSTATUS,
VIPCARD.FMasterFlag AS MASTERFLAG,
VIPCARD.FVipCardNumber AS VIPCARDNUMBER,
VIPCARD.FPanelNumber AS PANELNUMBER,
PARENTCARDNUMBER.FVipCardNumber AS PARENTCARDNUMBER.VIPCARDNUMBER,
VIPNUMBER.FNumber AS VIPNUMBER.NUMBER,
VIPNUMBER.FName_l2 AS VIPNUMBER.NAME,
CARDTYPE.FName_l2 AS CARDTYPE.NAME,
VIPCARD.FCardKind AS CARDKIND,
CARDCATEGORY.FName_l2 AS CARDCATEGORY.NAME,
CARDGRADE.FName_l2 AS CARDGRADE.NAME,
VIPCARD.FParValue AS PARVALUE,
VIPCARD.FCostFee AS COSTFEE,
VIPCARD.FIsSecurity AS ISSECURITY,
VIPCARD.FIsEffectCtrl AS ISEFFECTCTRL,
VIPCARD.FEffectRange AS EFFECTRANGE,
VIPCARD.FEffectDate AS EFFECTDATE,
VIPCARD.FInValidateDate AS INVALIDATEDATE,
VIPCARD.FCurrentBonus AS CURRENTBONUS,
VIPCARD.FCumulateBonus AS CUMULATEBONUS,
VIPCARD.FCurrentValue AS CURRENTVALUE,
VIPCARD.FCumulateValue AS CUMULATEVALUE,
VIPCARD.FReturnProfitAmount AS RETURNPROFITAMOUNT,
VIPCARD.FCumulateProfit AS CUMULATEPROFIT,
VIPCARD.FLastReturnDate AS LASTRETURNDATE,
VIPCARD.FFirstConsumeDate AS FIRSTCONSUMEDATE,
VIPCARD.FLastConsumeDate AS LASTCONSUMEDATE,
VIPCARD.FConsumeCount AS CONSUMECOUNT,
VIPCARD.FCumulateConsumeAmout AS CUMULATECONSUMEAMOUT,
VIPCARD.FTeamCustomer AS TEAMCUSTOMER,
VIPCARD.FRemark AS REMARK,
ISSUEORG.FName_l2 AS ISSUEORG.NAME,
BIZMAN.FName_l2 AS BIZMAN.NAME,
VIPCARD.FID AS ID,
ISSUEBY.FName_l2 AS ISSUEBY.NAME,
VIPCARD.FIssueDate AS ISSUEDATE,
VIPCARD.FCheckCode AS CHECKCODE,
VIPCARD.FConsumWay AS CONSUMWAY,
VIPCARD.FIsCreditCard AS ISCREDITCARD,
VIPCARD.FCheckWay AS CHECKWAY,
VIPCARD.FCurrentCount AS CURRENTCOUNT,
SONCARDCATE.FName_l2 AS SONCARDCATE.NAME,
SONCARDCATE.FNumber AS SONCARDCATE.NUMBER,
VIPCARD.FValidityUnit AS VALIDITYUNIT
FROM orcl0320.T_RT_VipCard AS VIPCARD

LEFT OUTER JOIN orcl0320.T_BD_Person AS BIZMAN

ON VIPCARD.FBizManID = BIZMAN.FID
LEFT OUTER JOIN orcl0320.T_RT_CardCategory AS CARDCATEGORY

ON VIPCARD.FCardCategoryID = CARDCATEGORY.FID
LEFT OUTER JOIN orcl0320.T_RT_VIPBaseData AS VIPNUMBER

ON VIPCARD.FVipNumber = VIPNUMBER.FID
LEFT OUTER JOIN orcl0320.T_RT_VipCard AS PARENTCARDNUMBER

ON VIPCARD.FParentCardNumberID = PARENTCARDNUMBER.FID
LEFT OUTER JOIN orcl0320.T_ORG_Sale AS ISSUEORG

ON VIPCARD.FIssueOrgID = ISSUEORG.FID
LEFT OUTER JOIN orcl0320.T_RT_CardType AS CARDTYPE

ON VIPCARD.FCardTypeID = CARDTYPE.FID
LEFT OUTER JOIN orcl0320.T_RT_CardGrade AS CARDGRADE

ON VIPCARD.FCardGradeID = CARDGRADE.FID
LEFT OUTER JOIN orcl0320.T_PM_User AS ISSUEBY

ON VIPCARD.FIssueByID = ISSUEBY.FID
LEFT OUTER JOIN orcl0320.T_RT_CardCategory AS SONCARDCATE

ON VIPCARD.FSonCardCategoryId = SONCARDCATE.FID

在php运行这条SQL语句总是提示Warning: oci_execute() [function.oci-execute]: ORA-00923: 未找到要求的 FROM
关键字 实在找不到原因了请大神指教
最佳答案
估计是SQL语句字符太多 导致你用某个字符串类型变量存放的时候 被自动截取了一部分sql语句 导致sql语句不完整(调试的时候在你执行SQL语句的那行加个断点 看看SQL语句是否完整)
那个最快回答完全是SB
全部回答
size,date都是oracle关键字,不能出现在sql的as后面。 写成 size1,date1 会解决“未找到要求的 from 关键字”问题。 另外, filecontenttype = 'folders'filepath = ''出现的地方也不对,不应该在select子句中,而是在where后。 修改成: select folderguid as fileguid, foldername as name, null as size1, creatdate as date1, '' as username, convert(nvarchar, belongtype) as type from misc_netharddiskfolder where parentfolderguid = '46a73c5e-51e1-4056-bedc-6039a26478e5' and filecontenttype = 'folders' and filepath = '' union all select fileguid as fileguid, filename as name, filelength as size2, uploaddate as date2, uploaddisplayname as username, filecontenttype as filecontenttype, attachtype as type, filepath as filepath from misc_netharddiskfiles where folderguid = '46a73c5e-51e1-4056-bedc-6039a26478e5' 可以保证至少没有语法错误。
少了一个逗号 应该是: SELECt inst_id, dbid, NAME, TO_CHAr(created, 'yyyy-mm-dd hh24:mi:ss') created, log_mode,TO_CHAr(version_time, 'yyyy-mm-dd hh24:mi:ss') version_time, open_mode FROM gv$database;
我要举报
如以上问答信息为低俗、色情、不良、暴力、侵权、涉及违法等信息,可以点下面链接进行举报!
大家都在看
有什么好看的小说?麻烦介绍一下作者哦!~
怎样用面粉油糖制作可口小点心
计算:|-6|-18+9.
大嘴小吃地址在哪,我要去那里办事
37级鞋改了4次还没成四像 用个无暇魂能成四象
进DNF出现这个?什么意思?高手进
怎么QQ升级快?
过好今天的概念是什么?
在洛阳名门地产做保安怎么样?
已知⊙O1的半径是2cm,⊙O2的半径是3cm,若这
伍氏猪脚粉面馆地址有知道的么?有点事想过去
找个会做平面广告的高手帮吗
太容易得到.是不是真的不会珍惜
大家觉得是冰冻宝石好还是激光宝石好呢?(4399
问答互助,自主择业可以可以滞留一年吗
推荐资讯
国家电网宁阳磁窑供电所在哪里啊,我有事要去
一个数除以95,商是4,并且有余数,余数最大
原命题的逆命题是假命题的是A.若|a|=|b|,则a
谁下载MFC71U.DLL给我
安阳市环保建议书
山东省汶上县至浙江无锡有多少公里
湖南电视机厂家属区在什么地方啊,我要过去处
50传承套装怎么获得。
初恋时怎样的
单选题我国历史上唯一的女皇帝是A.吕后B.武则
真的有海伦之衣吗???
深圳机场在那里?
正方形一边上任一点到这个正方形两条对角线的
阴历怎么看 ?