Login
Register
Search
Home
Forums
Jobs
LawsonGuru
LawsonGuru Letter
LawsonGuru Blog
Worthwhile Reading
Infor Lawson News Feed
Store
Store FAQs
About
Forums
Integration / Customization
IPA/ProcessFlow
double quotes in column name - can't assign column to a variable
Home
Forums
Jobs
LawsonGuru
LawsonGuru Letter
LawsonGuru Blog
Worthwhile Reading
Infor Lawson News Feed
Store
Store FAQs
About
Who's On?
Membership:
Latest:
HireIQ
Past 24 Hours:
0
Prev. 24 Hours:
0
Overall:
5264
People Online:
Visitors:
378
Members:
1
Total:
379
Online Now:
New Topics
Lawson S3 Procurement
Tolerance Settings
3/31/2025 2:01 PM
I've been trying to set a tolerance for some t
Dealing with Lawson / Infor
Printing Solutions other than MHC
3/27/2025 1:00 PM
What are others using for printing solutions besid
Lawson S3 Procurement
Green check marks in Lawson 9.0.1
3/20/2025 4:55 PM
Hi, How to remove green check mark on items when o
Lawson S3 HR/Payroll/Benefits
Pay Rate History to Show All Positions
2/26/2025 3:34 PM
Does anyone know how to modify payratehistory.htm
Infor CloudSuite
How to build a Pre-Prod tenant
2/7/2025 1:28 AM
After we finished our implementation and ended our
Lawson S3 Procurement
Browser issue with RQC Shopping
1/28/2025 5:49 PM
Since the recent Chrome/Edge updates, our RQC shop
Lawson S3 Procurement
S3-Procurement New Company
1/22/2025 10:38 PM
My Accounting Department has created a new Company
S3 Customization/Development
JUSTIFIED RIGHT
1/15/2025 7:41 PM
Is there a way in Lawson COBOL to make a character
S3 Systems Administration
ADFS certificate - new cert
12/3/2024 9:38 PM
The certificates on the windows boxes expired and
Lawson S3 HR/Payroll/Benefits
Post Tax Benefit Plan Table
11/14/2024 9:16 PM
Hi, totally new to Laswon. I have a repor
Top Forum Posters
Name
Points
Greg Moeller
4184
David Williams
3349
JonA
3291
Kat V
2984
Woozy
1973
Jimmy Chiu
1883
Kwane McNeal
1437
Ragu Raghavan
1375
Roger French
1315
mark.cook
1244
Forums
Filtered Topics
Unanswered
Unresolved
Announcements
Active Topics
Most Liked
Most Replies
Search Forums
Search
Advanced Search
Topics
Posts
Prev
Next
Forums
Integration / Customization
IPA/ProcessFlow
double quotes in column name - can't assign column to a variable
Please
login
to post a reply.
17 Replies
0
Subscribed to this topic
52 Subscribed to this forum
Sort:
Oldest First
Most Recent First
Author
Messages
Steve11
Basic Member
Posts: 11
8/24/2010 10:10 PM
I'm using a query in the SQL Query node and the query references a column called UNION. Well, UNION is a keyword in Oracle (no, I didn't create the table, it's Lawson table) so I have to put double quotes around the name for a valid query. The query works fine but the problem is trying to access the "UNION" variable in the query (jobGradeQuery_"UNION"). The Assign node does not like those double quotes. When I try to assign the UNION string to a variable I get an error basically stating that the expression is invalid.
Here's the query:
SELECT ACTIVE, "UNION", SALARYSTRUCTUREGRADE, PAYGRADE FROM LTM.POSITION WHERE HRORGANIZATION = '500'
Here's the assign statement:
foobar = jobGradeQuery_"UNION"
Is there a way to get around this?
thanks,
Steve
Jimmy Chiu
Veteran Member
Posts: 641
8/25/2010 4:13 PM
Split
SELECT ACTIVE, '"UNION"'. SALARYSTRUCT..............
Steve11
Basic Member
Posts: 11
8/25/2010 6:02 PM
Split
I'm already doing that. The problem is trying to assign the data in the "UNION" column to a variable in a processFlow assign node.
Because of the quotes in "UNION" you get a sysax error when trying to assign the column data to a variable.
e.g.
foobar is a varible of type string-
jobGradeQuery is tghe query node name.
the following assignment (done in an assign node) generates a systax error:
foobar = jobGradeQuery_"UNION"
David Williams
Veteran Member
Posts: 1127
8/25/2010 6:07 PM
Split
I was wondering since the field variable name is actually jobGradeQuery_UNION and not just UNION if the quote was really needed? If so then does it make sense that the quotes should go around the whole variable name and not just the end: "jobGradeQuery_UNION" ?
David Williams
Veteran Member
Posts: 1127
8/25/2010 6:07 PM
Split
If you're getting an error on an Assign node, leave the quotes out completely.
Steve11
Basic Member
Posts: 11
8/25/2010 7:09 PM
Split
The field variable name is jobGradeQuery_"UNION". The double quotes are part of the variable name! It can't be changed as it was generated by processFlow. Other field names don't have quotes, as there are no quotes used for those columns in the select clause.
e.g.,
SELECT ACTIVE, "UNION", SALARYSTRUCTUREGRADE, PAYGRADE FROM LTM.POSITION WHERE HRORGANIZATION = '500'
results in variable names of:
jobGradeQuery_"UNION"
jobGradeQuery_ACTIVE
jobGradeQuery_PAYGRADE
etc.
Maybe I could edit the processFlow xml file and try to change the jobGradeQuery_"UNION" variable name?
--Steve
Deleted User
New Member
Posts: 0
8/25/2010 7:23 PM
Split
I had a similar issue which I resolved by using an alias in the sql query:
SELECT ACTIVE, "UNION" as myunion, SALARYSTRUCTUREGRADE, PAYGRADE FROM LTM.POSITION WHERE HRORGANIZATION = '500'
Then the variable would be:
jobGradeQuery_MYUNION
Steve11
Basic Member
Posts: 11
8/25/2010 7:38 PM
Split
Unfortunately the variable becomes
jobGradeQuery_"UNION" as myunion
that's even more of a mess!
I also tried
SELECT ACTIVE, "UNION" "myunion", SALARYSTRUCTUREGRADE, PAYGRADE FROM LTM.POSITION WHERE HRORGANIZATION = '500'
which produces a variable of
jobGradeQuery_"UNION" "myunion"
thanks,
Steve
Deleted User
New Member
Posts: 0
8/25/2010 7:46 PM
Split
Can you reference "union" as r_union instead?
Steve11
Basic Member
Posts: 11
8/25/2010 7:53 PM
Split
sorry, I don't follow you. Do you mean changing the query, or?
Deleted User
New Member
Posts: 0
8/25/2010 8:04 PM
Split
In S3, when the column name in dbdef is an oracle reserved word, the column name inside oracle is preceded by r_.
I am not sure if that is the case with LTM, if so, you could change the sql from select "union" to select r_union.
If that is not the case I am fairly sure that you can use the column number in the variable instead of the name:
jobquery_2 (if this is the second column returned).
Steve11
Basic Member
Posts: 11
8/25/2010 8:26 PM
Split
ah! I'm new to Oracle...
I tried your suggestion and LTM doesn't recognize the r_. I get an "invalid identifier" error.
Nor can I use jobquery_2, it's not recognized as a variable...
thanks,
Steve
John Henley
Posts: 3351
8/25/2010 10:18 PM
Split
Have you tried escaping the double quote character, e.g. "=
Steve11
Basic Member
Posts: 11
8/25/2010 11:43 PM
Split
I tried escaping the processFlow variable name when I made the assignment:
foobar = jobGradeQuery_\"UNION\"
and
foobar = jobGradeQuery_'"UNION"'
and
foobar = jobGradeQuery_""UNION""
none of the above works. Is that what you had in mind?
thanks,
Steve
KK - Infor
Veteran Member
Posts: 61
8/26/2010 3:13 PM
Split
Steve,
Try to assign in the free form JavaScript area in the Assign node.(using the 'Add JavaScript' button).
And then, after the JS Expression, in the same assign node, put - foobar = foobar (using the usual Lawson Assign way). This way you'll be able to see the value in the WU logs.
Hope this helps!
Cheers,
KK
Steve11
Basic Member
Posts: 11
8/26/2010 3:34 PM
Split
KK,
Adding
foobar = jobGradeQuery_LTM.POSITION."UNION"
in the javscript tab of the assign node results in the error msg:
Error while validating expression: foobar = jobGradeQuery_LTM.POSITION."UNION" missing name after . operator.
If Iuse another query variable that doesn't have the double quotes it works fine.
thanks,
Steve
ailsally
New Member
Posts: 2
6/21/2012 2:48 PM
Split
Steve,
You may already have a solution to this issue since this posting is a couple of years old. Anyway, I found that you can use \ as the escape character for the double quote. For example: "\"" + UNION + "\"" will give you the result as "UNION".
Shari
Veteran Member
Posts: 78
6/21/2012 3:34 PM
Split
I will be out of the office Thursday, June 21 through Wednesday, July 4, 2012. If you need immediate assistance, please contact the Service Desk at (215) 542-0730 (support@support.actslife.org). Otherwise I will return your message when I am back in the office. Thank you!
-Shari
>>>
06/21/12 12:00 >>>
Lawson ProcessFlow Forum Notification
----------------------------------------------------------------
Posted by:ailsally
Date: 06/21/2012 09:48 AM
Subject: RE: double quotes in column name - can't assign column to a variable
Message:
----------------------------------------------------------------
Steve,
You may already have a solution to this issue since this posting is a couple of years old. Anyway, I found that you can use \ as the escape character for the double quote. For example: "\"" + UNION + "\"" will give you the result as "UNION".
----------------------------------------------------------------
To view the complete thread and reply via your browser, please visit:
https://www.lawsonguru.co...olumn-to-a-variable/
Thank you,
LawsonGuru.com
You were sent this email because you opted to receive email notifications when someone posted and/or responded to a message on this forum. To unsubscribe to this thread please visit your user profile page and change your subscription options.
Please
login
to post a reply.