cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
537
Views
0
Helpful
2
Replies

Help with DBwrite step

anthoney_murphy
Level 1
Level 1

I am attempting to create a new record and append new information stored in a variable to a table.  I am able to get the script  to do a static string but it will not use the value of the string variable I have setup.

For example:

user calls in and inputs their phone number.

script places the number in a variable called PhoneNumber

The DBwrite step attempts to upload and create a new record to table with the phonenumber field populated by the value in the variable PhoneNumber.

INSERT INTO tivr_test
(phonenumber)
VALUES
('PhoneNumber')

Ayn assistance would be welcome and appreciated.

1 Accepted Solution

Accepted Solutions

khambetea
Level 1
Level 1

Did you try using $PhoneNumber?

View solution in original post

2 Replies 2

khambetea
Level 1
Level 1

Did you try using $PhoneNumber?

Its the oddest thing.  After I originally posted this I did use the

$PhoneNumber statement and it still did not work.  I then read somewhere that

IPCC and SQL handle string variables differently and that I would need

to convert the string to and integer in order to do this.  I did this but neglected to

change the SQL statement to use the int variable.

  I tested and was able to write the string to the
table.  It wasnt until I checked the SQL statement that I realized that i was writing a string to the database.  I am still investigating why it is now working.

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: