Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Not applicable

Odd syntax error in load script

I have looked through every single syntax error post in the forum, and I don't think my issue is the same as any of them.

I wrote this script based on a template that works, and just changed file names and headers. It should work but it doesn't

I have attached the sample data.

Any help is appreciated.error.png

1 Solution

Accepted Solutions

Re: Odd syntax error in load script

Try the attached

9 Replies

Re: Odd syntax error in load script

The new names you are assigning have spaces in them... you need to cover them with [] or ""

Capture.PNG

Not applicable

Re: Odd syntax error in load script

same.png

still results in same error. I have _, not spaces in my code, im not sure why the script error shows it as spaces

Re: Odd syntax error in load script

Try this

Fact2:

  Load

    Data1 as [$(vName1)],

    Data2 as [$(vName2)],

    Data3 as [$(vName3)],

    Data4 as [$(vName4)]

   

    Resident Fact;

These variables are created using data from cutoffar.dat and not the inline table

antoniotiman
Honored Contributor III

Re: Odd syntax error in load script

Hi Aaron

from Your attachment


Fact2:
Load
Data1 as $(vName1),
Data2 as $(vName2),
Data3 as $(vName3),
Data4 as $(vName4)

Resident Fact;

Re: Odd syntax error in load script

Here you go...

Capture.PNG

Not applicable

Re: Odd syntax error in load script

Thank you, one more issue however.

Now I have double the amount of tables.

I think putting the 4 things in  [ ] resulted in it making 2 separate tables.

Any idea how to fix this?result2.png

Re: Odd syntax error in load script

Try the attached

Not applicable

Re: Odd syntax error in load script

Ah yes thank you. For some reason the template I was working off of, the script code worked for them. But thank you this solves my problem

Not applicable

Re: Odd syntax error in load script

Thanks

Community Browser