IMPORT $ and repository
I am taking the LN Intro to ECL and I’m having some issues with the repository. It seems that when I add folders/files to the repository, those items are not visible on anyone else’s instance of the repository. Additionally, using IMPORT $; does not make the other EXPORTed files in the folder available. This is the code:
//EXPORT BWR_BasicQueries := 'todo';
import $;
$.Persons;
count($.Persons);
Err msgs rcvd:
Error: syntax error near ";" : expected '.' (3, 10), 3002,
Error: syntax error near ")" : expected '.' (5, 17), 3002,
Any help greatly appreciated.
//EXPORT BWR_BasicQueries := 'todo';
import $;
$.Persons;
count($.Persons);
Err msgs rcvd:
Error: syntax error near ";" : expected '.' (3, 10), 3002,
Error: syntax error near ")" : expected '.' (5, 17), 3002,
Any help greatly appreciated.
- 215joec
- Posts: 1
- Joined: Wed Sep 08, 2021 2:25 pm
Hi,
In ECL, the repository you are using is local on your machine only. To allow others to see your repository folders there is usually a version control repository set up by your team, like GitHub.
Regarding the use of $ and IMPORT. $ is a shortcut to the name of your current folder where your ECL file is created. For example, if your folder name is Training, your new ECL file created in the Training folder can reference other EXPORTed definitions in that same folder by using:
or
The error you are reporting is telling you that the Persons definition is either in a different folder, OR, you haven't EXPORTed the Persons definition. For example:
Please feel free to reach out to me directly via email if you have any additional questions.
[email protected]
Regards,
Bob
In ECL, the repository you are using is local on your machine only. To allow others to see your repository folders there is usually a version control repository set up by your team, like GitHub.
Regarding the use of $ and IMPORT. $ is a shortcut to the name of your current folder where your ECL file is created. For example, if your folder name is Training, your new ECL file created in the Training folder can reference other EXPORTed definitions in that same folder by using:
- Code: Select all
IMPORT Training;
or
- Code: Select all
IMPORT $;
The error you are reporting is telling you that the Persons definition is either in a different folder, OR, you haven't EXPORTed the Persons definition. For example:
- Code: Select all
EXPORT Persons := DATASET('~ONLINE::Intro::Persons',Layout,FLAT);
Please feel free to reach out to me directly via email if you have any additional questions.
[email protected]
Regards,
Bob
- bforeman
- Community Advisory Board Member
- Posts: 1006
- Joined: Wed Jun 29, 2011 7:13 pm
2 posts
• Page 1 of 1
Who is online
Users browsing this forum: No registered users and 1 guest