Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
In the data load editor...how do I add a new field that concatenates three other existing fields?
Load script below:
Patient_Ledger_2017:
LOAD
ENCID,
ITEMTYPE,
"Transaction Date",
"Transaction Time",
"Service Date"
Trans,
CPT,
UNITS,
PracticeName,
LocationName,
RenderingPhysician,
BillingProvider,
"Encounter Total Charges",
PATIENTID
FROM [lib://BACKUP/PTLEDGER_2017.csv]
(txt, utf8, embedded labels, delimiter is ',', msq);
I want to load an additional field that concatenates "Service Date", RenderingPhysician, and PATIENTID for each row.
May be this
Patient_Ledger_2017:
LOAD
ENCID,
ITEMTYPE,
"Transaction Date",
"Transaction Time",
"Service Date"
Trans,
CPT,
UNITS,
PracticeName,
LocationName,
RenderingPhysician,
BillingProvider,
"Encounter Total Charges",
PATIENTID,
"Service Date" & RenderingPhysician & PATIENTID as New_Fields
FROM [lib://BACKUP/PTLEDGER_2017.csv]
(txt, utf8, embedded labels, delimiter is ',', msq);
May be this
Patient_Ledger_2017:
LOAD
ENCID,
ITEMTYPE,
"Transaction Date",
"Transaction Time",
"Service Date"
Trans,
CPT,
UNITS,
PracticeName,
LocationName,
RenderingPhysician,
BillingProvider,
"Encounter Total Charges",
PATIENTID,
"Service Date" & RenderingPhysician & PATIENTID as New_Fields
FROM [lib://BACKUP/PTLEDGER_2017.csv]
(txt, utf8, embedded labels, delimiter is ',', msq);
Hi,
try in your script
"Service Date"&'-'&RenderingPhysician&'-'&PATIENTID as NewFiled.
You add an extra line before the FROM clause:
"Service Date & RenderingPhysician & PATIENTID AS NewField,
Often you want to add some separator between the concatenated values:
"Service Date" & ' ' & RenderingPhysician & ' ' & PATIENTID AS NewField,
Thank you they all work.
Good one can you close the thread now with appropriate answers for the responses.
Another and good way also by using Dash for field separators
"Service Date" & '- ' & RenderingPhysician & '-' & PATIENTID AS NewField