VoiceGuide IVR Software Main Page
Jump to content

Insert Into Mysql

Recommended Posts

I use SIP for outbound campaign.

I would like to write responses to MySQL database.

 

Look pleasy into attached file, where I specified Querry Database module.

Is it correct?

What else should I check?

Database Querry.zip

Share this post


Link to post

I managed to have connection with my database.

The problem is there are no any answers. Records are coming to database but they are null.

Please look into log file - there is a line like that:

 

134219.421 6 3 1 state [save Responses] DB Query

134219.421 6 3 1 rv replace start [iNSERT INTO results (resp1, resp2, resp3, resp4) VALUES ('$RV[Question 1]', '$RV[Question 2]', '$RV[Question 3]', '$RV[Question 4]')]

134219.437 6 rv dbg rv_retrieve did not find [Question 1] ( 51 75 65 73 74 69 6f 6e 20 31)

134219.437 6 rv dbg rv_retrieve did not find [Question 2] ( 51 75 65 73 74 69 6f 6e 20 32)

134219.437 6 rv dbg rv_retrieve did not find [Question 3] ( 51 75 65 73 74 69 6f 6e 20 33)

134219.437 6 rv dbg rv_retrieve did not find [Question 4] ( 51 75 65 73 74 69 6f 6e 20 34)

 

what means I think there is another issue.

0731_1341_vgEngine.zip

Share this post


Link to post

In your script the module names that are used are Question1 - Question4

 

There is no space between 'Question' and the number.

 

But in the $RVs in SQL query there are spaces between 'Question' and the number. - so VG cannot find any values for them, so the are null at insertion.

 

Change

 

 

INSERT INTO results (resp1, resp2, resp3, resp4) VALUES ('$RV[Question 1]', '$RV[Question 2]', '$RV[Question 3]', '$RV[Question 4]')

to:

 

 

INSERT INTO results (resp1, resp2, resp3, resp4) VALUES ('$RV[Question1]', '$RV[Question2]', '$RV[Question3]', '$RV[Question4]')

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×