Remove or Strip a Slash
I know that this is a pretty basic technique, but I'm having troubles finding the solution for it. Any help is appreciated...
I'm running a simple sql db query, and if I pull the following data: "A/P", then I need to use coldfusion to strip that slash out, so that I just have "AP".
So for example, let's say that "#GetData.LineCode#" = "A/P":
<cfquery name="InsertInventory" datasource="#Request.ds#" username="#Request.user#" password="#Request.pass#">
INSERT INTO Products
(LineCode)
VALUES
(
'#GetData.LineCode#'
)
</cfquery>
I need it to insert just "AP". How do I do that??
Also, there are some instances where I might have "APP", so I can't just remove the 2nd character every time. It has to recognize the slash and remove only it.
Thanks in advance everyone!
