0

I am trying to insert data from csv to a table using sql loader. My csv has data in small Caps .But I want the data in the table to be in Large cap for some columns For some Columns it should be InitCap.

        INFILE 'abc.csv'
        INSERT INTO TABLE T_DETAILS
        FIELDS TERMINATED BY ',' OPTIONALLY ENCLOSED BY '"' TRAILING NULLCOLS
        (   
    INITCAP(f_name), 
    UPPER(f_code)```

But i am getting error like

> **SQL*Loader-350: Syntax error at line 16. Expecting "," or ")", found "(".
>     INITCAP(f_name),**
>            ^

1 Answer 1

3

You can, but not like that. Should've been

load data
infile 'abc.csv' 
insert
into table t_details
fields terminated by ',' optionally enclosed by '"' trailing nullcols
(f_name     "initcap(:f_name)",
 f_code     "upper(:f_code)"
)
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.