Calculation cannot escape :\ with python mode

More
1 year 3 months ago #25087 by prashant
I have a simple script 

Result.value = [F001] + "|" + [F002]

F001- C:\aopos\Superadmin\Autsv_columns.txt
F002- abba

Output 
C:opos\Superadmin\Autsv_columns.txt|abba


[F001] - When I make it below - C:\users\eowise_2025\ignored_csv_columns.txt

SyntaxError: (unicode error) 'unicodeescape' codec can't
decode bytes in position 2-3: truncated \u00 escape (line 2,
offset 16): 'Result.value =
'Clusers)eowise_2025\ignored_csv_columns.txt + T" + 'abba"
 
The following user(s) said Thank You: Peter.Jonson

Please Log in or Create an account to join the conversation.

More
1 year 3 months ago #25088 by Peter.Jonson
We will have a look it

Peter Jonson
ETL Developer

Please Log in or Create an account to join the conversation.

More
1 year 3 months ago #25117 by admin
This one works



From wiki
  • Input variables are passed into the script as strings by default.
  • Always use raw strings for file paths: 
    Code:
    r'C:\path oile'

Mike
ETL Architect
The following user(s) said Thank You: prashant

Please Log in or Create an account to join the conversation.

More
1 year 3 months ago #25118 by prashant
Thank you. I will update my ChatGPT prompt also to include this. cheers. 

Please Log in or Create an account to join the conversation.

Cookies user preferences
We use cookies to ensure you to get the best experience on our website. If you decline the use of cookies, this website may not function as expected.
Accept all
Decline all
Read more
Marketing
Set of techniques which have for object the commercial strategy and in particular the market study.
Google
Accept
Decline
Analytics
Tools used to analyze the data to measure the effectiveness of a website and to understand how it works.
Google Analytics
Accept
Decline
Google Analytics
Accept
Decline
Functional
Tools used to give you more features when navigating on the website, this can include social sharing.
Advertisement
If you accept, the ads on the page will be adapted to your preferences.
Google Ad
Accept
Decline
Save