0

Error while inserting email address in the table

**[perl] my $username=$CGI->{salesrep}; return $username;[/perl]@gmail.com**

I want to insert this value in the table.

But It gives null when executed.

[query type=list sql="INSERT tech4less.outofstock_sku SET name='[value name]',customer_email='[value email]', phone='[value phone]', state='[value b_state]', postalcode='[value zip]', country='[value country]', **salesperson='[perl]$username[/perl]@gmail.com**', product='[value wish_product]', item_description='[value wish_descrip]', manufacturer='[value wish_man]',  category = '[value wish_cat]', business_yn='[value option]', date = now()"]

[/query]

Mat
  • 202,337
  • 40
  • 393
  • 406
rachel
  • 225
  • 2
  • 5
  • 16
  • What framework are you using for this? – Mat Feb 03 '12 at 11:19
  • Interchange ..this is an HTML page – rachel Feb 03 '12 at 11:27
  • Not familiar with it, is that [this framework](http://www.icdevgroup.org/i/dev)? (Asking because the [data-interchange] tag isn't really useful here - a separate tag for that framework would be welcome.) – Mat Feb 03 '12 at 11:31
  • http://www.icdevgroup.org/interchange-doc-5.2.0/frames/ictags_87.html pls see this – rachel Feb 03 '12 at 11:50

1 Answers1

1

If $CGI is a CGI object then access a parammeter this way:

my $username=$CGI->param('salesrep');

Read this: http://perldoc.perl.org/CGI.html#FETCHING-THE-VALUE-OR-VALUES-OF-A-SINGLE-NAMED-PARAMETER:

Regards

user1126070
  • 5,059
  • 1
  • 16
  • 15