I am submitting a simple form to enter a new business and I send it to the function create.
function create( event, rc, prc ) {
var id = createUUID();
query.from("citidel_consern")
.insert( {
"concernID" : #id#,
"concernName": rc.concernName,
"businessAddressOne": rc.businessAddressOne,
"businessAddressTwo": rc.businessAddressTwo,
"businessCity": rc.businessCity,
"businessState": rc.businessState,
"businessZipcode": rc.businessZipcode,
"businessPrimaryPhone": rc.businessPrimaryPhone,
"Country": rc.Country,
"timeInBusiness": rc.timeInBusiness,
"Description" : rc.Description,
"datecreated": now(),
"userIDfk": auth().getUserId()
});
query.from( "user_concern" )
.insert( {
"userIDfk" = auth().getUserId(),
"concernIDfk" = #id#
} );
relocate( "concerns" );
}
The first insert does just fine but the second one blows up:
Parameter index out of range (3 > number of parameters, which is 2).
Database
Datasource | citidel5 |
---|---|
Name-Value Pairs | â |
SQL Sent | Parameter index out of range (3 > number of parameters, which is 2). |
INSERT
INTO
``user_concern (
concernIDfk,
userIDfk)
VALUES
(
'297846 New Drive'
,
''
)
|
|SQL State|S1009|
|NativeErrorCode|0|
|Driver Error Message|INSERT INTO user_concern
(concernIDfk
, userIDfk
) VALUES (â297846 New Driveâ, ââ)|
|Exception Detail|Parameter index out of range (3 > number of parameters, which is 2).|
|Additional Info|Struct (ordered)|
the one value it tries to put into the user_concern database isnât even the correct value. I canât seem to figure this one out, it seems like it should be simple.
thank you for your help,
Rick