简体   繁体   English

没有“成员”列,它可以正常工作。 但是当我使用“成员”列时,它会在实时服务器中引发错误

[英]Without 'member' column it works fine. But when i am using 'member' column it is throwing an error in live server

Here is my php code with laravel framework below:这是我的 php 代码,下面是 laravel 框架:

 $migrationData = array(
    'po_code' => 184,
    'mnyr' => "06/2022",
    'dist_code' => $request->district_code[$i],
    'thana_code' => $request->thana_code[$i],
    'loan_code' => $request->loan_code[$i],
    'cum_disb' => $request->cum_disb[$i] ?? 0,
    'member' => $request->member[$i] ?? 0,
    'borrower' => $request->borrower[$i] ?? 0,
    'loan_fy' => $request->loan_fy[$i] ?? 0,
    'cum_borr' => $request->cum_borr[$i] ?? 0,
);

$findRecord =  array(
    'po_code'                   => 123,
    'mnyr'                      => "06/2022",
    'dist_code'                 =>  $request->district_code[$i],
    'thana_code'                => $request->thana_code[$i],
    'loan_code'                 => $request->loan_code[$i],
);

DB::connection('oracle')->table('PRA_LN_DIST_WISE_DISB')
    ->updateOrInsert(
        $findRecord,
        $migrationData
    );

Here is table structer:这是表结构:

create table PRA_LN_DIST_WISE_DISB
(
  po_code      VARCHAR2(4) not null,
  mnyr         VARCHAR2(7) not null,
  dist_code    VARCHAR2(4) not null,
  thana_code   VARCHAR2(6) not null,
  loan_code    VARCHAR2(7) not null,
  cum_disb     NUMBER(17,2),
  member       NUMBER(17,2),
  borrower     NUMBER(17,2),
  loan_fy      NUMBER(17,2),
  cum_borr     NUMBER(17,2),
  ins_user     VARCHAR2(50),
  ins_date     DATE,
  upd_user     VARCHAR2(50),
  upd_date     DATE,
  posting_flag VARCHAR2(3),
  status_date  DATE
);
alter table PRA_LN_DIST_WISE_DISB
  add constraint PK_PRA_LN_DIST_WISE_DISB primary key (PO_CODE, MNYR, DIST_CODE, THANA_CODE, LOAN_CODE);

When I am trying to do Insert/Update this Error is being thrown:当我尝试执行插入/更新时,会抛出此错误:

/home/microfinplus/public_html/dus/vendor/laravel/framework/src/Illuminate/Database/Connection.php 647 Error Code: 904 Error Message: ORA-00904: "member": invalid identifier Position: 142 Statement: update "PRA_LN_DIST_WISE_DISB" set "PO_CODE" =:p0, "MNYR" =:p1, "DIST_CODE" =:p2, "THANA_CODE" =:p3, "LOAN_CODE" =:p4, "CUM_DISB" =:p5, "member" =:p6, "BORROWER" =:p7, "LOAN_FY" =:p8, "CUM_BORR" =:p9 where ("PO_CODE" =:p10 and "MNYR" =:p11 and "DIST_CODE" =:p12 and "THANA_CODE" =:p13 and "LOAN_CODE" =:p14) Bindings: [184,06/2022,1009,100965,038,326286984,1473,1108,37558000,8606,184,06/2022,1009,100965,038] (SQL: update "PRA_LN_DIST_WISE_DISB" set "PO_CODE" = 184, "MNYR" = 06/2022, "DIST_CODE" = 1009, "THANA_CODE" = 100965, "LOAN_CODE" = 038, "CUM_DISB" = 326286984, "member" = 1473, "BORROWER" = 1108, "LOAN_FY" = 37558000, "CUM_BORR" = 8606 where ("PO_CODE" = 184 and "MNYR" = 06/2022 and "DIST_CODE" = 1009 and "THANA_CODE" = 100965 and /home/microfinplus/public_html/dus/vendor/laravel/framework/src/Illuminate/Database/Connection.php 647 Error Code: 904 Error Message: ORA-00904: "member": invalid identifier Position: 142 Statement: update "PRA_LN_DIST_WISE_DISB " 设置 "PO_CODE" =:p0, "MNYR" =:p1, "DIST_CODE" =:p2, "THANA_CODE" =:p3, "LOAN_CODE" =:p4, "CUM_DISB" =:p5, "成员" =:p6 , "BORROWER" =:p7, "LOAN_FY" =:p8, "CUM_BORR" =:p9 其中 ("PO_CODE" =:p10 and "MNYR" =:p11 and "DIST_CODE" =:p12 and "THANA_CODE" =:p13和“LOAN_CODE”=:p14)绑定:[184,06/2022,1009,100965,038,326286984,1473,1108,37558000,8606,184,06/2022,1009,100965,038](SQL:更新“ PRA_LN_DIST_WISE_DISB" 设置 "PO_CODE" = 184, "MNYR" = 06/2022, "DIST_CODE" = 1009, "THANA_CODE" = 100965, "LOAN_CODE" = 038, "CUM_DISB" = 326286984, "member" = 1473, "BORROWER" = 1108, "LOAN_FY" = 37558000, "CUM_BORR" = 8606 其中 ("PO_CODE" = 184 和 "MNYR" = 06/2022 和 "DIST_CODE" = 1009 和 "THANA_CODE" = 100965 和 "LOAN_CODE" = 038)) "LOAN_CODE" = 038))

Now what should I do?现在我该怎么办?

hope this helps Why do I have ORA-00904 even when the column is present?希望这会有所帮助为什么即使存在列,我也会有 ORA-00904?

TL:DR Oracle database queries, if enclosed with double-quotes becomes case-sensitive. TL:DR Oracle 数据库查询,如果用双引号括起来,则区分大小写。 Please check the database and make sure your member column is spelled and cased correctly.请检查数据库并确保您的member列拼写和大小写正确。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 尝试通过php使用soap返回“无法连接到主机”错误。 使用SoapUi的相同wsdl文件可以正常工作。 我想念什么? - Trying to use soap through php returns a “Could not connect to host” error. Same wsdl file using SoapUi works fine. What am I missing? codeigniter sql 备份在本地服务器中工作正常,但在实时显示错误 - codeigniter sql backup works fine in local server but in live it shows error MySQL 查询在本地服务器上工作正常,但在实时中出错 - MySQL query works fine on local server but gives error in live 为什么在实时服务器上出现此错误? - Why on live server I am getting this error? 为什么使用Aerys出现“错误:在null上调用成员函数end()”? - Why am I getting “Error: Call to a member function end() on null” using Aerys? 我错过了什么一直给成员函数错误打电话? - What am I missing that keeps giving call to member function error? 针对另一列的每个成员搜索一列 - Search a column against each member of another column 在实时服务器上的 phpmyadmin 上运行任何查询时出错。 但是当我在 adminer.php 上运行它时,它正在执行 - Error in running any query on the phpmyadmin on the live server . But when i am runnign it on the adminer.php it is executing 在Xampp上工作时,使用语言类的实时服务器上的网站抛出错误:Codeigniter - Site throwing error on live server with language class while works on Xampp: Codeigniter 我的codeigniter webapp有问题,它在我的本地主机上工作正常但在实时服务器上没有 - I have problems with my codeigniter webapp it works fine on my local host but not on live server
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM