我有下面的insert查询
include("ORCLconfig.php");
$addAclaim = oci_parse($conn, "INSERT INTO claims_accidents (ID, CLAIM_NUMBER, DATE_OF, TIME, LOCATION, PURPOSE, WEATHER, ROAD, STREET_LIGHTS, SPEED_LIMIT, SPEED_PRIOR, SPEED_AT_MOMENT, AIRBAGS, AMBULANCE, SIGNALS, OCCUPANTS, DESCRIPTION, ROAD_LOCATION, PH_DRIVING, NAME_OF_DRIVER, DRIVER_DOB, DRIVER_OCCUPATION, MEDICAL_CONDITIONS, DRIVER_CONVICTIONS, AUTHORISED, DRIVER_ADDRESS1, DRIVER_ADDRESS2, DRIVER_ADDRESS3, DRIVER_ADDRESS4, DRIVER_POSTCODE, DRIVER_TELEPHONE, MATCH, V5_NUMBER, KEY_SETS, OS_FINANCE, VEHICLE_VALUE, VEHICLE_REG, VEHICLE_MAKE, VEHICLE_MODEL, NAMED_DRIVER, FATALITIES, DRIVEABLE) VALUES (null, :claimnum, :date_of_accident, :time_of_acc, :location_of_acc, :purpose, :weather, :road, :lights, :speedLimit, :speedPrior, :speedImpact, :airbags, :ambulance, :signals, :occupants , :accdesc, :street_of_acc :ph_driving, :driverName, :DRIVER_DOB, :driverOccupation, :driverMedical, :driverConvictions, :auth, :driverAddress1, :driverAddress2, :driverAddress3, :driverAddress4, :driverPostcode, :driverTelephone, :match, :v5number, :keySets, :osf, :vehicle_value, :vehicle_reg, :vehicle_make, :vehicle_model, :named, :fatal, :driveable)");
oci_bind_by_name($addAclaim, ":claimnum", $claimnum);
oci_bind_by_name($addAclaim, ":date_of_accident", $date_of_accident);
oci_bind_by_name($addAclaim, ":time_of_acc", $time_of_acc);
oci_bind_by_name($addAclaim, ":location_of_acc", $location_of_acc);
oci_bind_by_name($addAclaim, ":purpose", $purpose);
oci_bind_by_name($addAclaim, ":weather", $weather);
oci_bind_by_name($addAclaim, ":road", $road);
oci_bind_by_name($addAclaim, ":lights", $lights);
oci_bind_by_name($addAclaim, ":speedLimit", $speedLimit);
oci_bind_by_name($addAclaim, ":speedPrior", $speedPrior);
oci_bind_by_name($addAclaim, ":speedImpact", $speedImpact);
oci_bind_by_name($addAclaim, ":airbags", $airbags);
oci_bind_by_name($addAclaim, ":ambulance", $ambulance);
oci_bind_by_name($addAclaim, ":signals", $signals);
oci_bind_by_name($addAclaim, ":occupants", $occupants);
oci_bind_by_name($addAclaim, ":accdesc", $accdesc);
oci_bind_by_name($addAclaim, ":street_of_acc", $street_of_acc);
oci_bind_by_name($addAclaim, ":ph_driving", $ph_driving);
oci_bind_by_name($addAclaim, ":driverName", $driverName);
oci_bind_by_name($addAclaim, ":DRIVER_DOB", $DRIVER_DOB);
oci_bind_by_name($addAclaim, ":driverOccupation", $driverOccupation);
oci_bind_by_name($addAclaim, ":driverMedical", $driverMedical);
oci_bind_by_name($addAclaim, ":driverConvictions", $driverConvictions);
oci_bind_by_name($addAclaim, ":auth", $auth);
oci_bind_by_name($addAclaim, ":driverAddress1", $driverAddress1);
oci_bind_by_name($addAclaim, ":driverAddress2", $driverAddress2);
oci_bind_by_name($addAclaim, ":driverAddress4", $driverAddress4);
oci_bind_by_name($addAclaim, ":driverPostcode", $driverPostcode);
oci_bind_by_name($addAclaim, ":driverTelephone", $driverTelephone);
oci_bind_by_name($addAclaim, ":match", $match);
oci_bind_by_name($addAclaim, ":v5number", $v5number);
oci_bind_by_name($addAclaim, ":keySets", $keySets);
oci_bind_by_name($addAclaim, ":osf", $osf);
oci_bind_by_name($addAclaim, ":vehicle_value", $vehicle_value);
oci_bind_by_name($addAclaim, ":vehicle_reg", $vehicle_reg);
oci_bind_by_name($addAclaim, ":vehicle_make", $vehicle_make);
oci_bind_by_name($addAclaim, ":vehicle_model", $vehicle_model);
oci_bind_by_name($addAclaim, ":named", $named);
oci_bind_by_name($addAclaim, ":fatal", $fatal);
oci_bind_by_name($addAclaim, ":driveable", $driveable);
oci_execute($addAclaim, OCI_COMMIT_ON_SUCCESS);
每次我尝试运行此查询时,都会出现此错误
oci_bind_by_name(): ORA-01036: illegal variable name/number
我做了一些研究,显然这意味着其中一个变量不在SQL语句中。对我来说不是这样,我检查了语句、数据库(oracle)表和所有绑定变量,它们都匹配。
错误上的行号将表明它是$driveable变量。我做了一个检查,这是被发送到页面罚款。
不知道还有什么地方可以看,所以任何帮助都会很好。
如果您也有可视化工作室,并且正在使用详细信息视图。我建议重新配置您的数据源。我收到了ORA-01036错误,我所要做的就是重新配置我的SQL源,它为我正确地生成了它。对我来说,当我试图更新数据源时,我没有正确处理原始值。
我也在甲骨文。
除了@bonCodigos answer,您还没有绑定:driveradress3
你似乎错过了一个逗号,
:street_of_acc :ph_driving,
应该是,,
:street_of_acc, :ph_driving,
请帮帮我 获取日期范围的数据时出错 错误 ora-01036非法变量名称/编号
为什么在Oracle DB中出现此错误? cx_Oracle。ORA-01036:非法变量名称/数字
我已经创建了一个API,希望将数据插入oracle数据库。但我收到一条错误消息“error:ORA-01036:非法变量名/编号”。我不知道我犯了什么错误。希望能帮我解决这个问题。先谢谢你。 [错误:ORA-01036:非法变量名/编号]{errorNum:1036,偏移量:0}
我正在尝试使用oracledb客户端从nodejs对oracle数据库执行查询,并得到“ORA-01036:非法变量名/编号”。我尝试了多种建议的方法来传递我的变量,但失败了。使用硬代码值的查询。 以下是我的示例代码: 获取"ORA-01036:非法变量名称/数字"或空结果
我想更新gridview中的行的单元格。但我得到的错误是 ORA-01036:非法变量名称/编号 在 下面是我的代码:-
我面临的问题,在更新表单视图值使用sqldatasSource绑定与Oracle数据库。 我的选择和插入事件工作正常,所有列和参数都正确。 但当我点击下面的更新按钮时,出现了错误: "ORA-01036:非法变量名称/数字" 以下是我在sqldatasource(与oracle绑定)中使用的更新命令: 我的问题解决了,因为我没有使用主键来匹配在哪里条件,当我用主键更改在哪里条件时,它开始工作。 在