Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8928965
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T08:34:12+00:00 2026-06-15T08:34:12+00:00

MySql IN Parameter – Does a VarChar IN Parameter val need to be single

  • 0

MySql IN Parameter – Does a VarChar IN Parameter val need to be single quoted when used in Stored Procedure?

I have created my classic ASP code just like normal but I am not getting the column to update.

Do I need to quote a VarChar parameter?

DELIMITER $$

DROP PROCEDURE IF EXISTS `usp_update_map_record` $$
CREATE DEFINER=`ddddddd`@`%` PROCEDURE `usp_update_map_record`(
  IN p_intGrillId INT(10),
  IN p_intPartId INT(10),
  IN p_ManRef VARCHAR(10)
)
BEGIN

UPDATE parts_map SET manualref = 'p_ManRef' WHERE grillid = p_intGrillId AND partid = p_intPartId;

END $$

DELIMITER ;

VBSCRIPT PORTION:

With comm
    .ActiveConnection = conn
    .CommandType = adCmdStoredProc
    .CommandText = "usp_update_map_record"
    .Parameters.Append .CreateParameter("p_intGrillId", adInteger, adParamInput, 10, intGrillId)
    .Parameters.Append .CreateParameter("p_intPartId", adInteger, adParamInput, 10, CIntPartId)
    .Parameters.Append .CreateParameter("p_ManRef", adVarChar, adParamInput, 10, strManualRef)
    .Execute
End With

Also I tested all 3 values and they are not empty.

Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T08:34:13+00:00Added an answer on June 15, 2026 at 8:34 am

    This is incorrect:

    UPDATE parts_map SET manualref = 'p_ManRef'
                                     ^--      ^--
    

    The quotes turn that “field” into a string. – you’re not comparing two fields, you’re comparing the manualref field against a string whose value happens to be the NAME of a parameter for your sproc.

    Try:

    UPDATE parts_map SET manualref = @p_ManRef
                                     ^--- variable/parameter indicator
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to get a output parameter from MySQL stored procedure, let's have look
I have a stored procedure in mySQL with a parameter, How can i create
I've created procedure with IN parameter inside my database(MySql->Routines->Create Procedure). I am using it
I need to create mysql stored procedure which makes more than one insert at
I have a MySQL stored routine that has an IN parameter that is of
Last night I added a parameter to a stored procedure in a mySQL database.
I'm having issues when trying to call a MySQL (5.0.77) stored procedure with parameters,
I'm trying to get parameter from MYSQL procedure. My proc: CREATE PROCEDURE proc(someIn INT
I need to have a single row of data printed out through php. So,
I have used mysql mysql_real_escape_string($somevariable) in my code developed using Joomla! api. Everything is

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.