Replies: 3 comments
-
Your database is telling you that your attempted insert violates a constraint on the location id column. That constraint says it can't be NULL. You have to fix that in your source data and/or however you are building the SQL for the insert. |
Beta Was this translation helpful? Give feedback.
-
If your table does not allow NULL columns, you need to do something before you try and insert it, such as setting the locationID variable to be an empty string instead of being NULL. But, that doesn't seem like it would make sense because I would imagine LocationID needs to be present at all times or the record is useless. So, the CSV looks to have bad data you need to resolve on the source end. In the meantime, you could just instead check to see if the locationID variable is NULL, then bypass the insert. It is also possible that you did something wrong in your transformer step and you are not setting it correctly. I would verify that you are pulling the value from the CSV and assigning it to a variable correctly before doing anything else, as it may not be actually NULL to begin with. |
Beta Was this translation helpful? Give feedback.
-
Dear rjkroll Nextgenhealthcare/Connect,
Thanks a lot for your quick and kind reply, Your advice is really
appreciated and will try as you informed me. If i got any errors in Mirth
or if i need your help, i will be in touch with you.
Thanks
Malik Rashid Ahmad.
00966596885997
…On Wed, Jun 23, 2021 at 6:50 PM rjkroll ***@***.***> wrote:
If your table does not allow NULL columns, you need to do something before
you try and insert it, such as setting the locationID variable to be an
empty string instead of being NULL. But, that doesn't seem like it would
make sense because I would imagine LocationID needs to be present at all
times or the record is useless. So, the CSV looks to have bad data you need
to resolve on the source end. In the meantime, you could just instead check
to see if the locationID variable is NULL, then bypass the insert.
It is also possible that you did something wrong in your transformer step
and you are not setting it correctly. I would verify that you are pulling
the value from the CSV and assigning it to a variable correctly before
doing anything else, as it may not be actually NULL to begin with.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#4609 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABTAF5UT45UHI5JLOILJM2DTUH7CVANCNFSM47FCU5ZQ>
.
--
Best Regards.
*Malik Rashid Ahmad ::..*
-----------------------------------------------------------------------------------
*Mobile : 00966596885997*
*Skype ID : rashidLahore*
*Email : ***@***.*** ***@***.***>*
Freelancing *:* http://www.fiverr.com/mrakftech
-----------------------------------------------------------------------------------
KF Tech - URL *:* http://kftech.ihostfull.com
KF Tech - Alibaba Store *:* http://pk116173297.fm.alibaba.com
KF Tech - Online Store *:* http://ChampianOnline.ecwid.com
KF Tech - Etsy Store *:* http://zipansion.com/3937t
KF Tech - Twitter *:* http://twitter.com/kftechnologies
KF Tech - Facebook *:* http://facebook.com/kftech
KF Tech - Facebook Store *:* http://goo.gl/NvWvfm
KF Tech - Google+ *:* http://zipansion.com/391k8
KF Tech - Google Business *:* http://zipansion.com/393Kk
KF Tech - Instagram *:* http://instagram.com/mrakftech786
KF Tech - Linkedin Company *:* http://zipansion.com/39yau
EasyTechX - Youtube Channel *:* http://zipansion.com/392Hk
EasyTechX - Blogspot *:* *http://zipansion.com/392nz*
<http://zipansion.com/392nz>
-----------------------------------------------------------------------------------
*<< Note >>*
It is not our intention to send e-mail to someone, who is not interested in
receiving.Just simply reply this e-mail
with "REMOVE" in the subject with exact e-mail address you wish to remove.
We will immediately remove your
email address from our database and you will not receive our e-Newsletter
again. Thanks.
|
Beta Was this translation helpful? Give feedback.
-
I am trying to enter into database from XML to JSON using JavaScript or either using JSON payload. But i receive below error in both ways.
{
"0" : {
"requestId" : "d61e6b28-1b34-4895-ad24-7916ad6852b4",
"status" : 400,
"datixId" : null,
"error" : "An exception occurred while executing 'INSERT INTO user_location (created, updated, location_id, user_id, tenant_id) VALUES (?, ?, ?, ?, ?)' with params ["2021-06-22 13:22:52", "2021-06-22 13:22:52", null, 584, 1]:\n\nSQLSTATE[23000]: Integrity constraint violation: 1048 Column 'location_id' cannot be null"
},
"1" : {
"requestId" : "99e49325-095d-45df-b866-5ae8378d5364",
"status" : 400,
"datixId" : null,
"error" : "The EntityManager is closed."
My Channel receive data from CSV file and convert to XML then i map XML to JSON either using JavaScript or by Payload, but above mentioned error appear when Start Channel.
Please Please help me to solve this error, i am maintaining Hospital data, so i need urgent help. Waiting for you quick and kind reply from fellows.
My WhatsApp 00966596885997 and email [email protected]
Beta Was this translation helpful? Give feedback.
All reactions