Cisco Support Community
Showing results for 
Search instead for 
Did you mean: 

Welcome to Cisco Support Community. We would love to have your feedback.

For an introduction to the new site, click here. And see here for current known issues.

New Member

DB Write again, again..


I´ve been reading the other DBwrite conversions in the forum, and i seems that noone has a solution, if you want to use DB write with a $var.

are there another way to write variables in databases from scripts.




Re: DB Write again, again..

Did you check my earlier post out. DBwrite works. You can use insert/update statement with variables. What issues are you having?


When you are using variables in the sql statement, use the $ before the variable name.

For example, If your telnum variable name is varTelNum and CallerID is in variable varCLID and your table name is TestTable with fields TelNum and ClID, then your insert statement will be as follows:

Insert into TestTable(TelNum, CLID) values ($varTelNum, $varCallerID)

So, the format is

Insert into (

) values ($, $,....,$)

Hope this helps. You can dummy some data into the variables and use the test button in the DBWrite node to test the insert.

Good luck. Please rate posts

New Member

Re: DB Write again, again..

I get the NullPointerException when I try..

the Update works fine..

i´ve tried with String and Integer..

DBwrite : INSERT INTO ny VALUES('9') works fine but

INSERT INTO ny VALUES('$nummer') or

INSERT INTO ny VALUES($nummer) doesn´t.


New Member

Re: DB Write again, again..


Tried once more... without the ' ' - and didn´t test the insert.. and it worked...



Re: DB Write again, again..

If you put the '', then you have to give the actual value if the value is a string. If you are using the $ and the variable, you don't put the quotes because if the variable is a string, then it already has the quotes built in (which is not seen).

Anywayz, good that you got it figured out.

CreatePlease login to create content