Compare commits

...

107 Commits

Author SHA1 Message Date
yabwon
5ecccacdce SAS Packages Framework, version 20201001
SAS Packages Framework, version 20201001
- `%installPackage` macro allows to install/download the framework file like any other package, e.g. `%installPackage(SPFinit)`,
- improvement in testing if HASHING_FILE function is available,
- documentation updated.
2020-10-01 20:02:26 +02:00
yabwon
b274d0dcda macroArray, version 0.5
spelling corrected
2020-09-18 23:09:49 +02:00
yabwon
3881f936ca SQLinDS, version 2.2 and macroArray, version 0.5
SQLinDS, version 2.2
- documentation updated, macroarray.md created

macroArray, version 0.5
- documentation updated, macroarray.md created
- the do_overs automatically unquote `betwee=` parameter
2020-09-15 13:03:31 +02:00
yabwon
d53f622776 SQLinDS, version 2.2
SQLinDS, version 2.2
- documentation updated, macroarray.md created
2020-09-15 13:02:37 +02:00
yabwon
8c584c8030 macroArray, version 0.5
macroArray, version 0.5
- documentation updated, macroarray.md created
- the do_overs automatically unquote `betwee=` parameter
2020-09-15 12:15:37 +02:00
yabwon
5c640cba21 macroArray, version 0.5
macroArray, version 0.5
- documentation updated
- the do_overs automatically unquote `betwee=` parameter
2020-09-15 11:28:54 +02:00
yabwon
73e8d10200 macroArray, version 0.5
macroArray, version 0.5
- documentation updated
- the do_overs automatically unquote `betwee=` parameter
2020-09-14 22:29:48 +02:00
yabwon
93904a03cb macroArray, version 0.5
macroArray, version 0.5
- documentation updated
- the do_overs automatically unquote `betwee=` parameter
2020-09-14 22:27:11 +02:00
yabwon
55aaa8748c version 20200911
SAS Packages Framework, version 20200911:
- New macros added: %loadPackageS() and %verifyPackage()
- %installPackage() allow to install multiple packages with in run
- %listPackages() updated
- %generatePackage() provides hash digest of the package zip file (for SAS 9.54M6 and later)
- Bug fixes
- New version of documentation and "getting started"

Packages recompiled with new version of SAS Packages Framework:
- BasePlus [0.62]
  - getVars() modified to handle "long" lists of variables
  - QuickSort functions added
- SQLinDS [2.2]
  - doc updated
- DFA (Dynamic Function Arrays) [0.2]
- macroArray [0.5]
  - new parameter `which=` added to the %do_over macro
  - the do_overs automatically unquote the `between=` parameter
  - doc updated
- dynMacroArray [0.2]
2020-09-14 22:19:13 +02:00
yabwon
63f849dd24 macroArray, version 0.5
macroArray, version 0.5
- documentation updated
- the do_overs automatically unquote `betwee=` parameter
2020-09-14 22:16:37 +02:00
yabwon
ef5864dc88 version 20200911
SAS Packages Framework, version 20200911:
- New macros added: %loadPackageS() and %verifyPackage()
- %installPackage() allow to install multiple packages with in run
- %listPackages() updated
- %generatePackage() provides hash digest of the package zip file (for SAS 9.54M6 and later)
- Bug fixes
- New version of documentation and "getting started"

Packages recompiled with new version of SAS Packages Framework:
- BasePlus [0.62]
- getVars() modified to handle "long" lists of variables
- QuickSort functions added
- SQLinDS [2.2]
- DFA (Dynamic Function Arrays) [0.2]
- macroArray [0.4]
-new parameter `which=` added to the %do_over macro
- dynMacroArray [0.2]
2020-09-14 17:08:07 +02:00
yabwon
c10851e9ef SQLinDS, version 2.2 2020-09-14 17:07:11 +02:00
yabwon
10994721b4 SQLinDS, version 2.2 2020-09-14 17:03:12 +02:00
yabwon
5461c587be SQLinDS, version 2.2 2020-09-14 17:02:42 +02:00
yabwon
e97c8e31ad version 20200911
SAS Packages Framework, version 20200911:
- New macros added: %loadPackageS() and %verifyPackage()
- %installPackage() allow to install multiple packages with in run
- %listPackages() updated
- %generatePackage() provides hash digest of the package zip file (for SAS 9.54M6 and later)
- Bug fixes
- New version of documentation and "getting started"

Packages recompiled with new version of SAS Packages Framework:
- BasePlus [0.62]
- getVars() modified to handle "long" lists of variables
- QuickSort functions added
- SQLinDS [2.1]
- DFA (Dynamic Function Arrays) [0.2]
- macroArray [0.4]
-new parameter `which=` added to the %do_over macro
- dynMacroArray [0.2]
2020-09-11 13:54:04 +02:00
yabwon
16d55d7dcb version 20200911
SAS Packages Framework, version 20200911:
- New macros added: %loadPackageS() and %verifyPackage()
- %installPackage() allow to install multiple packages with in run
- %listPackages() updated
- %generatePackage() provides hash digest of the package zip file (for SAS 9.54M6 and later)
- Bug fixes
- New version of documentation and "getting started"

Packages recompiled with new version of SAS Packages Framework:
- BasePlus [0.62]
  - getVars() modified to handle "long" lists of variables
  - QuickSort functions added
- SQLinDS [2.1]
- DFA (Dynamic Function Arrays) [0.2]
- macroArray [0.4]
  -new parameter `which=` added to the %do_over macro
- dynMacroArray [0.2]
2020-09-11 13:51:19 +02:00
yabwon
c54ef20fac Getting Started with SAS Packages
macroArray, version 0.4
2020-09-08 20:29:30 +02:00
yabwon
be2af5883a macroArray, version 0.4 2020-09-08 20:28:15 +02:00
yabwon
b867ed4309 Getting Started with SAS Packages
*macroArray* version 0.4
2020-09-07 10:26:35 +02:00
yabwon
6a53bbe50a macroArray version 0.4 2020-09-07 10:24:55 +02:00
yabwon
3e44e6b8ae macroArray v.0.4
New parameter added to the %do_over macro.

The `which=` is a _SPACE_ separated list of indexes which should be used, possible special characters are `H` and `L` which means high and low bound of an array, list could be set with colons(:) in form of start:end:by (no spaces between!), if by is omitted the default is 1. If possible use `1:5` rather `1 2 3 4 5` since the firs works faster.
2020-09-07 10:07:42 +02:00
yabwon
f3f7a3896a version 20200827 2020-08-27 21:07:15 +02:00
yabwon
7491d42378 version 20200827
version 20200827,
-improvement in the testing part of the framework code
2020-08-27 21:06:04 +02:00
yabwon
16a20907af BasePlus version 0.62
bugfixes in sorting functions [experimental]
2020-08-19 16:41:16 +02:00
yabwon
f3107f0db3 BasePlus version 0.61
- getVars() modified to handle "long" lists of variables
- first iteration of QuickSort functions added [still experimental]
2020-08-18 12:27:08 +02:00
yabwon
0ca3eac3c9 BasePlus version 0.6
- getVars() modified to handle "long" lists of variables
 - first iteration of QuickSort functions added [still experimental]
2020-08-18 12:13:27 +02:00
yabwon
4eac2a0fea Merge branch 'master' of https://github.com/yabwon/SAS_PACKAGES 2020-08-15 13:18:06 +02:00
yabwon
ad81e0cb0e version 20200815
version 20200815, changes:
- Type PROTO added in the `%genaratePackge()` macro. Functions generated by Proc Proto in `externC functionName;` and `externCend;` blocks are available.
- Bug fix in the `%listPackages()` macro.
- Documentation updated.
2020-08-15 13:17:57 +02:00
yabwon
f542d70332 Getting Started with SAS Packages
recompiled with new version of the framework
2020-08-12 14:45:20 +02:00
yabwon
80fdc9f214 version 0.3
recompiled with new version of the framework
2020-08-12 14:43:05 +02:00
yabwon
f23afe7486 version 0.2
recompiled with new version of the framework
2020-08-12 14:42:48 +02:00
yabwon
e467959d77 version 2.1
recompiled with new version of the framework
2020-08-12 14:42:14 +02:00
yabwon
035e184b74 version v0.53
bug fixes and recompiled with new version of the framework
2020-08-12 14:41:48 +02:00
yabwon
61d5806e79 version 20200811
version 20200811, changes:
- in the %generatePackage() macro the filesLocation is now positional parameter (the first one),
- in the framework both `%loadPackage()` and %loadPackage(HELP)` command prints out the help information for the %loadPackage() macro,
- the %ICEloadPackage() macro extended with version testing,
- test for existence of %loadpackage macro added,
- bug fix in lazyData generation
- help section search improved
- documentation updated.
2020-08-12 14:29:47 +02:00
yabwon
98871647dd Getting Started with SAS Packages
*BasePlus* 0.53
2020-08-12 13:56:35 +02:00
yabwon
16b744a763 version 20200811 2020-08-12 13:55:35 +02:00
yabwon
4765dc5c43 Getting Started with SAS Packages
BasePlus v0.53
2020-08-12 13:54:19 +02:00
yabwon
e1c95da0b7 version 20200811 2020-08-12 13:53:06 +02:00
yabwon
319dd8c46b Merge branch 'master' of https://github.com/yabwon/SAS_PACKAGES 2020-08-12 13:52:06 +02:00
yabwon
96555584a3 version 0.53
bug fix in the %getVars() and %QgetVars() macros
2020-08-12 13:52:02 +02:00
yabwon
a6cfb9f93f Getting Started with SAS Packages
Recompiled with new version of SAS Packages Framework.
2020-08-11 16:54:45 +02:00
yabwon
63b30d7b6e version 0.3
Recompiled with new version of SAS Packages Framework.
2020-08-11 16:54:08 +02:00
yabwon
eef8649f3c version 0.2
Recompiled with new version of SAS Packages Framework.
2020-08-11 16:53:57 +02:00
yabwon
4511c812f0 version 2.1
Recompiled with new version of SAS Packages Framework.
2020-08-11 16:53:28 +02:00
yabwon
5ca878d178 version 0.52
Recompiled with new version of SAS Packages Framework.
2020-08-11 16:53:18 +02:00
yabwon
5c042cadff Merge branch 'master' of https://github.com/yabwon/SAS_PACKAGES 2020-08-11 16:44:43 +02:00
yabwon
3eb09f29cd version 20200811
version 20200811, changes:
- in the %generatePackage() macro the filesLocation is now positional parameter (the first one),
- in the framework both `%loadPackage()` and %loadPackage(HELP)` command prints out the help information for the %loadPackage() macro,
- the %ICEloadPackage() macro extended with version testing,
- test for existence of %loadpackage macro added,
- bug fix in lazyData generation
- documentation updated.
2020-08-11 16:44:38 +02:00
yabwon
da3c8df259 Getting Started with SAS Packages
Recompiled with new version of SAS Packages Framework.
2020-08-11 15:10:33 +02:00
yabwon
b9fa8fc5d7 version 2.1
Recompiled with new version of SAS Packages Framework.
2020-08-11 15:08:44 +02:00
yabwon
1fda328de8 version 0.3
Recompiled with new version of SAS Packages Framework.
2020-08-11 15:08:16 +02:00
yabwon
322a951290 version 0.2
Recompiled with new version of SAS Packages Framework.
2020-08-11 15:07:55 +02:00
yabwon
b090fdbe8d version 0.52
Recompiled with new version of SAS Packages Framework.
2020-08-11 15:07:17 +02:00
yabwon
42663d56f7 version 20200811
version 20200811, changes:
- in the %generatePackage() macro the filesLocation is now positional parameter (the first one),
- in the framework both `%loadPackage()` and %loadPackage(HELP)` command prints out the help information for the %loadPackage() macro,
- bug fix in lazyData generation
- documentation updated.
2020-08-11 14:47:41 +02:00
yabwon
bed882582e version 20200811 2020-08-11 12:34:49 +02:00
yabwon
532f1ec90e version 20200811
version 20200811, changes:
- in the %generatePackage() macro the filesLocation is now positional parameter (the first one),
- in the framework both `%loadPackage()` and %loadPackage(HELP)` command prints out the help information for the %loadPackage() macro,
- documentation updated.
2020-08-11 12:34:10 +02:00
yabwon
861c5d866b Getting Started with SAS Packages
BasePlus v0.52 recompiled
2020-08-10 14:55:10 +02:00
yabwon
f22d06fb42 version 20200810 2020-08-10 14:54:10 +02:00
yabwon
c0212cb8af version 0.52
recompiled with the new framework
2020-08-10 14:53:27 +02:00
yabwon
4ae8f23716 version 20200810
Version 20200810.
Parsing of the `description.sas` file improved.
Documentation corrected.
2020-08-10 14:52:47 +02:00
yabwon
7fd4dd9774 Getting Started with SAS Packages
BasePlus v0.52
2020-08-07 13:03:03 +02:00
yabwon
f41d73cd90 version 20200708 2020-08-07 13:02:08 +02:00
yabwon
863d6cb251 version 0.52
Help info added: "Caution! Array parameters to subroutine calls must be 1-based."

Spelling correction.
2020-08-07 13:00:52 +02:00
yabwon
790816e229 version 20200807
Framework:
Code searching help tags simplified.

Documentation:
Clarification about "description.sas" added.
2020-08-07 12:58:50 +02:00
yabwon
88ace7321b version 20200803
20200803
2020-08-05 12:29:31 +02:00
yabwon
f4ac0f1fe3 version 20200803
help info for %listPackages() added
2020-08-05 12:27:08 +02:00
yabwon
eb5cd6975c Getting Started with SAS Packages
presentation: "Getting Started with SAS Packages" added
2020-08-04 13:04:29 +02:00
yabwon
b975f75ff3 Getting Started with SAS Packages
presentation: "Getting Started with SAS Packages" added
2020-08-04 10:37:40 +02:00
yabwon
bb22a3e274 Getting Started with SAS Packages
Getting Started with SAS Packages
2020-08-04 10:33:14 +02:00
yabwon
f981751c28 Getting Started with SAS Packages
Getting Started with SAS Packages
2020-08-04 10:30:19 +02:00
yabwon
2f110adf1f Getting Started with SAS Packages
presentation: "Getting Started with SAS Packages" added
2020-08-04 10:19:55 +02:00
yabwon
5b1f8a3aae Getting Started with SAS Packages
presentation: "Getting Started with SAS Packages" added
2020-08-04 10:18:04 +02:00
yabwon
ef6473ad35 link to the doc added
link to the doc added
2020-08-04 10:14:43 +02:00
yabwon
e30261410e obsolete
obsolete
2020-08-04 07:17:31 +02:00
yabwon
3ede4541fd version 20200803
version 20200803, some code simplifications
2020-08-03 13:56:18 +02:00
yabwon
387898e01a version 20200730
Adjusted to SPF v.20200730
2020-07-31 22:20:10 +02:00
yabwon
e801f99e1c version 20200730
version 20200730, change list:

1) All elements of the SAS Packages Framework were moved to the SPFinit.sas file in directory SPF [SAS Packages Framework].

2) The public repository reordered [two new folders] and location link in the %installPackages() macro changed.

3) New directories: SPF [for SAS Packages Framework content and documentation] and packages [for packages repository]

4) Package FunctionsImissinBASE renamed to BasePlus.

5) All packages recompiled with new setup.

6) Help info improved and spellings corrected.
2020-07-31 14:43:40 +02:00
yabwon
850e003ea9 folder name corrected
folder name corrected
2020-07-31 11:34:06 +02:00
yabwon
21827e7ffa version 20200730
example added
2020-07-30 19:02:34 +02:00
yabwon
d59fb10575 version 20200730
Adjustments for version 20200730
2020-07-30 16:00:07 +02:00
yabwon
8e6a2d0da5 Update LICENSE 2020-07-30 15:30:59 +02:00
yabwon
0c75cf373e Merge branch 'master' of https://github.com/yabwon/SAS_PACKAGES 2020-07-30 15:28:43 +02:00
yabwon
42ede60e73 version 20200703
info about available packages
2020-07-30 15:28:33 +02:00
yabwon
a33d67528a version 20200730
Adjustments for version 20200730.
2020-07-30 15:25:21 +02:00
yabwon
9459b110d6 version 20200730
version 20200730, change list:

1) All elements of the SAS Packages Framework were moved to the SPFinit.sas file in directory SPF [SAS Packages Framework].

2) The public repository reordered [two new folders] and location link in the %installPackages() macro changed.

3) New directories: SPF [for SAS Packages Framework content and documentation] and packages [for packages repository]

4) Package FunctionsImissinBASE renamed to BasePlus.

5) All packages recompiled with new setup.
2020-07-30 15:01:05 +02:00
yabwon
0c49d2a5b1 version 20200730
adjusted to new setup
2020-07-30 14:56:06 +02:00
yabwon
98a6beeb8c version 0.5
recompiled with new framework setup

package FunctionsImissinBASE renamed to BasePlus
2020-07-30 14:46:45 +02:00
yabwon
6e03570afb version 0.3
recompiled with new framework setup
2020-07-30 14:46:05 +02:00
yabwon
b4bb3296c3 version 0.2
recompiled with new framework setup
2020-07-30 14:45:56 +02:00
yabwon
6841f6bd08 version 2.1
recompiled with new framework setup
2020-07-30 14:45:19 +02:00
yabwon
f4493aef1c version 20200730
version 20200730, change list:

1) All elements of the SAS Packages Framework were moved to the SPFinit.sas file in directory SPF [SAS Packages Framework].

2) The public repository reordered [two new folders] and location link in the %installPackages() macro changed.

3) New directories: SPF [for SAS Packages Framework content and documentation] and packages [for packages repository]

4) Package FunctionsImissinBASE renamed to BasePlus.

5) All packages recompiled with new setup.
2020-07-30 14:43:42 +02:00
yabwon
3e117ce8ef version 20200730
Deleted because repository was rerganised.
2020-07-30 14:39:26 +02:00
yabwon
f73e7c4c68 Update README.md
update about FunctionsImissinBASE 0.5
2020-07-27 19:37:36 +02:00
yabwon
e15ddd22cd version 0.5
some functions were renamed: arrRepNull() is now arrFillMiss(), the "shifting" functions are now arrMissToLeft/Right().
corrected help info.

thanks to ChrisNZ @ communities.sas.com for great feedback and valuable suggestions!
2020-07-27 19:35:50 +02:00
yabwon
f36dcd369e Update README.md
info about FunctionsImissinBASE 0.4
2020-07-26 17:35:59 +02:00
yabwon
84705927f1 version 0.4
some functions were renamed: arrVal() is arrFill(), replaceNull() is now arrRepNull(), kill() is now delDataset() ,and the "shifting" functions have "arr" prefix.
macros have new parameters: quote=,
new format added: boolz,
corrected help info.

thanks to ChrisNZ @ communities.sas.com for great feedback and valuable suggestions!
2020-07-26 17:35:23 +02:00
yabwon
51a921162f version 20200725
version 20200725, descriptions to macros added
2020-07-25 12:37:39 +02:00
yabwon
50adc7818b Update README.md
Latest version is 20200725.
2020-07-25 12:26:31 +02:00
yabwon
57fd048276 version 20200725
version 20200725, descriptions to macros added
2020-07-25 12:22:14 +02:00
yabwon
757d7a9ccc Update README.md
New macros: getVars() amd QgetVars() added to the functionsImissinBASE package.
2020-07-25 11:36:47 +02:00
yabwon
365f8b459e version 0.3
New macros getVars() amd QgetVars() added.
2020-07-25 11:28:57 +02:00
yabwon
c712bfd162 Update README.md
FunctionsImissinBASE 0.2
2020-06-29 21:59:30 +02:00
yabwon
70912499d5 Merge branch 'master' of https://github.com/yabwon/SAS_PACKAGES 2020-06-29 21:57:24 +02:00
yabwon
a5e428aa3f version 0.2
4 formats added
2020-06-29 21:56:59 +02:00
yabwon
d1cc2e7a8b Update README.md 2020-06-29 21:29:15 +02:00
yabwon
19f6889945 new package FunctionsImissinBASE added
new package FunctionsImissinBASE added
2020-06-25 16:50:30 +02:00
yabwon
f0336647e0 version 0.1
Functions I miss in BASE: a bunch of functions and functionalities I am missing in BASE SAS
2020-06-25 16:44:56 +02:00
yabwon
499846dbb1 [2020.06.21] Extended and up to date version of the SGF article
[2020.06.21] Extended and up to date version of the SGF article

formating update in the "User's session."
2020-06-21 12:06:00 +02:00
32 changed files with 4507 additions and 2526 deletions

View File

@@ -1,6 +1,6 @@
MIT License
Copyright (c) 2019 Bartosz Jablonski
Copyright (c) since 2019 Bartosz Jablonski
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal

106
README.md
View File

@@ -6,11 +6,15 @@ A **SAS package** is an automatically generated, single, stand alone *zip* file
The *purpose of a package* is to be a simple, and easy to access, code sharing medium, which will allow: on the one hand, to separate the code complex dependencies created by the developer from the user experience with the final product and, on the other hand, reduce developer's and user's unnecessary frustration related to a remote deployment process.
In this repository we are presenting a **standalone Base SAS framework** which allows to develop and use SAS packages. Read the **`SAS(r) packages - the way to share (a how to)- Paper 4725-2020 - extended.pdf`** to learn more.
In this repository we are presenting the **SAS Packages Framework** which allows to develop and use SAS packages. The latest version of SPF is **`20201001`**.
To get started with SAS Packages try this [**`Getting Started with SAS Packages`**](https://github.com/yabwon/SAS_PACKAGES/blob/master/SPF/Documentation/Getting_Started_with_SAS_Packages.pdf "Getting Started with SAS Packages") presentation (see the `./SPF/Documentation` directory).
The documentation and more advance reading would be the [**`SAS(r) packages - the way to share (a how to)- Paper 4725-2020 - extended.pdf`**](https://github.com/yabwon/SAS_PACKAGES/blob/master/SPF/Documentation/SAS(r)%20packages%20-%20the%20way%20to%20share%20(a%20how%20to)-%20Paper%204725-2020%20-%20extended.pdf "SAS packages - the way to share") article (see the `./SPF/Documentation` directory).
**General overview video:**
- SAS Global Forum 2020 V.E.: `https://www.youtube.com/watch?v=qCkb-bx0Dv8&t=0s`
- Sasensei Internationa Dojo: `https://www.youtube.com/watch?v=BFhdUBQgjYQ&t=0s`
- [SAS Global Forum 2020 V.E.](https://www.youtube.com/watch?v=qCkb-bx0Dv8&t=0s "SGF2020")
- [Sasensei Internationa Dojo](https://www.youtube.com/watch?v=BFhdUBQgjYQ&t=0s "SID no. 1")
### The User:
To use a package:
@@ -18,14 +22,15 @@ To use a package:
and then either:
- Download the `loadpackage.sas` file (user part of the framework) into the packages folder.
- \[Optional\] Download the `<packageName>.zip` file into the packages folder.
- Download the `SPFinit.sas` file (the SAS Packages Framework) into the local packages folder.
- \[Optional\] Manually download the `<packageName>.zip` file into the local packages folder.
- and Execute:
```
filename packages "<directory/containing/packages/>"; /* setup directory for packages */
%include packages(loadpackage.sas); /* enable the framework */
%include packages(SPFinit.sas); /* enable the framework */
/* %installPackage(packageName) */ /* install the package, unless you downloaded it manually */
%installPackage(packageName) /* install the package, unless you downloaded it manually */
%helpPackage(packageName) /* get help about the package */
%loadPackage(packageName) /* load the package content into the SAS session */
```
@@ -33,52 +38,91 @@ filename packages "<directory/containing/packages/>"; /* setup directory for pac
or if you need it just for "one time" only Execute:
```
filename packages "<directory/containing/packages/>"; /* setup directory for packages */
filename spfinit url "https://raw.githubusercontent.com/yabwon/SAS_PACKAGES/master/loadpackage.sas";
%include spfinit; /* enable the framework */
filename packages "%sysfunc(pathname(work))"; /* setup temporary directory for packages in the WORK */
filename SPFinit url "https://raw.githubusercontent.com/yabwon/SAS_PACKAGES/master/SPF/SPFinit.sas";
%include SPFinit; /* enable the framework */
%installPackage(packageName) /* install the package */
%helpPackage(packageName) /* get help about the package */
%loadPackage(packageName) /* load the package content into the SAS session */
```
**Workshop video for User**\[May 6th, 2020\]**: `https://youtu.be/qX_-HJ76g8Y`**
[**Workshop video for the User**](https://youtu.be/qX_-HJ76g8Y)\[May 6th, 2020\] [a bit outdated but gives the idea how it works]
### The Developer:
To create your own package:
- Read the **`SAS(r) packages - the way to share (a how to)- Paper 4725-2020 - extended.pdf`** to learn more.
- Download and use the `generatePackage.sas` file (developer part of the framework) and the `loadpackage.sas` file (user part of the framework but required for *testing*).
- Read the [**`SAS(r) packages - the way to share (a how to)- Paper 4725-2020 - extended.pdf`**](https://github.com/yabwon/SAS_PACKAGES/blob/master/SPF/Documentation/SAS(r)%20packages%20-%20the%20way%20to%20share%20(a%20how%20to)-%20Paper%204725-2020%20-%20extended.pdf "SAS packages - the way to share") to learn more details.
- Download and use the `SPFinit.sas` file (the SAS Packages Framework), the part of the framework required for *testing* is there too.
#### If you have any questions, suggestions, or ideas do not hesitate to contact me!
**Update**\[June 3rd, 2020\]**:** `%installPackage()` **macro is available**. The `%installPackage()` macro is embedded in the `loadpackage.sas` part of the framework.
**Update**\[June 3rd, 2020\]**:** `%installPackage()` **macro is available**. The `%installPackage()` macro is embedded in the `loadpackage.sas` part of the framework.
**Update**\[June 10th, 2020\]**:** To see help info about framework macros and their parameters just run: `%generatePackage()`, `%installPackage()`, `%helpPackage()`, `%loadPackage()`, and `%unloadPackage()` with empty parameter list.
**Update**\[June 10th, 2020\]**:** To see help info about framework macros and their parameters just run: `%generatePackage()`, `%installPackage()`, `%helpPackage()`, `%loadPackage()`, and `%unloadPackage()` with empty parameter list.
**Update**\[July 30th, 2020\]**:** All components of SAS Packages Framework are now in one file `SPFinit.sas` (located in the `./SPF` directory). Documentation moved to `./SPF/Documentation` directory. Packages zip files moved to `./packages` directory.
## Available packages:
Currently the following packages are available:
Currently the following packages are available (see the `./packages` directory):
- **SQLinDS**\[2.1\], based on Mike Rhoads' article *Use the Full Power of SAS in Your Function-Style Macros*. The package allows to write SQL queries in the datastep, e.g.
- **SQLinDS**\[2.2\], based on Mike Rhoads' article *Use the Full Power of SAS in Your Function-Style Macros*. The package allows to write SQL queries in the data step, e.g.
```
data class;
set %SQL(select * from sashelp.class order by age);
run;
data class;
set %SQL(select * from sashelp.class order by age);
run;
```
SHA256 digest for SQLinDS: B280D0B72DB77001ADAAE9C1612B67AD30C2C672371B27F1ACB12016C7A1363D
[Documentation for SQLinDS](https://github.com/yabwon/SAS_PACKAGES/blob/master/packages/sqlinds.md "Documentation for SQLinDS")
- **DFA** (Dynamic Function Arrays)\[0.2\], contains set of macros and FCMP functions which implement: a dynamically allocated array, a stack, a fifo queue, an ordered stack, and a priority queue, run `%helpPackage(DFA,createDFArray)` to find examples.
- **macroArray**\[0.3\], implementation of an array concept in a macrolanguage, e.g.
SHA256 digest for DFA: BB8768E977D62429368CFF2E5338A6553C35C998AEC09AF24088BA713BB54DDA
- **macroArray**\[0.5\], implementation of an array concept in a macrolanguage, e.g.
```
%array(ABC[17] (111:127), macarray=Y);
%macro test();
%do i = 1 %to 17;
%put &i.) %ABC(&i.);
%end;
%mend;
%test()
%let %ABC(13,i) = 99999; /* i = insert */
%do i = 1 %to 17;
%put &i.) %ABC(&i.);
%end;
%let %ABC(13,i) = 999; /* i = insert */
%do i = 1 %to 17;
%put &i.) %ABC(&i.);
%end;
%do_over(ABC, phrase=%nrstr(
%put &_i_.%) %ABC(&_i_.);
),
which = 1:H:2
);
```
- **dynMacroArray**\[0.2\], set of macros (wrappers for a hash table) emulating dynamic array in the datastep (macro predecessor of DFA)
SHA256 digest for macroArray: 53C248E1DE3268946C9CEC7E77BC222F652FBB006D9317BE36B86410DA31AE35
[Documentation for macroArray](https://github.com/yabwon/SAS_PACKAGES/blob/master/packages/macroarray.md "Documentation for macroArray")
- **BasePlus**\[0.62\] adds a bunch of functionalities I am missing in BASE SAS, such as:
```
call arrMissToRight(myArray);
call arrFillMiss(17, myArray);
call arrFill(42, myArray);
rc = delDataset("DataSetToDrop");
string = catXFn("date9.", "#", myArray);
format x bool.;
%put %getVars(sashelp.class, pattern = ght$, sep = +, varRange = _numeric_);
```
SHA256 digest for BasePlus: 278621A6D8BBBB791DEA4C215D4261F2CB8F8B76B1397F7FA9B2E4219E77CB5A
- **dynMacroArray**\[0.2\], set of macros (wrappers for a hash table) emulating dynamic array in the data step (macro predecessor of DFA)
SHA256 digest for dynMacroArray: 066186B94B2976167C797C6A6E6217E361E8DEB10F2AB81906E0A325E5243084
### ======

2973
SPF/SPFinit.sas Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -1,4 +1,4 @@
Copyright (c) 2019 Bartosz Jablonski
Copyright (c) 2019 - 2020 Bartosz Jablonski
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal

File diff suppressed because it is too large Load Diff

View File

@@ -1,164 +0,0 @@
/*** HELP START ***/
/**############################################################################**/
/* */
/* Copyright Bartosz Jablonski, July 2019. */
/* */
/* Code is free and open source. If you want - you can use it. */
/* I tested it the best I could */
/* but it comes with absolutely no warranty whatsoever. */
/* If you cause any damage or something - it will be your own fault. */
/* You have been warned! You are using it on your own risk. */
/* However, if you decide to use it do not forget to mention author: */
/* Bartosz Jablonski (yabwon@gmail.com) */
/* */
/* Here is the official version: */
/*
Copyright (c) 2019 Bartosz Jablonski (yabwon@gmail.com)
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
*/
/**#############################################################################**/
/* Macros to install SAS packages, version 20200603 */
/* A SAS package is a zip file containing a group of files
with SAS code (macros, functions, datasteps generating
data, etc.) wrapped up together and %INCLUDEed by
a single load.sas file (also embedded inside the zip).
*/
/*** HELP END ***/
/*** HELP START ***/
%macro installPackage(
packageName /* package name, without the zip extension */
, sourcePath = /* location of the package, e.g. "www.some.page/", mind the "/" at the end */
, replace = 1 /* 1 = replace if the package already exist, 0 = otherwise */
)
/*** HELP END ***/
/
secure;
%local ls_tmp ps_tmp notes_tmp source_tmp fullstimer_tmp stimer_tmp msglevel_tmp;
%let ls_tmp = %sysfunc(getoption(ls));
%let ps_tmp = %sysfunc(getoption(ps));
%let notes_tmp = %sysfunc(getoption(notes));
%let source_tmp = %sysfunc(getoption(source));
%let stimer_tmp = %sysfunc(getoption(stimer));
%let fullstimer_tmp = %sysfunc(getoption(fullstimer));
%let msglevel_tmp = %sysfunc(getoption(msglevel));
options NOnotes NOsource ls=MAX ps=MAX NOfullstimer NOstimer msglevel=N;
%local in out;
%let in = i%sysfunc(md5(&packageName.),hex7.);
%let out = o%sysfunc(md5(&packageName.),hex7.);
/*options MSGLEVEL=i;*/
/*
Reference:
https://blogs.sas.com/content/sasdummy/2011/06/17/how-to-use-sas-data-step-to-copy-a-file-from-anywhere/
*/
%if %superq(sourcePath)= %then
%do;
%let sourcePath = https://raw.githubusercontent.com/yabwon/SAS_PACKAGES/master/;
%end;
filename &in URL "&sourcePath.%lowcase(&packageName.).zip" recfm=N lrecl=1;
filename &out "%sysfunc(pathname(packages))/%lowcase(&packageName.).zip" recfm=N lrecl=1;
/*
filename in list;
filename out list;
*/
/* copy the file byte-by-byte */
data _null_;
length filein 8 out_path in_path $ 4096;
out_path = pathname ("&out");
in_path = pathname ("&in" );
filein = fopen( "&in", 'S', 1, 'B');
if filein = 0 then
put "ERROR: Source file:" /
"ERROR- " in_path /
"ERROR- is unavaliable!";
if filein > 0;
put @2 "Source information:";
infonum = FOPTNUM(filein);
length infoname $ 32 infoval $ 128;
do i=1 to coalesce(infonum, -1);
infoname = FOPTNAME(filein, i);
infoval = FINFO(filein, infoname);
put @4 infoname ":"
/ @6 infoval
;
end;
rc = FCLOSE(filein);
put;
if FEXIST("&out") = 0 then
do;
put @2 "Installing the &packageName. package.";
rc = FCOPY("&in", "&out");
end;
else if FEXIST("&out") = 1 then
do;
if symget("replace")="1" then
do;
put @2 "The following file will be replaced during "
/ @2 "instalation of the &packageName. package: "
/ @5 out_path;
rc = FDELETE("&out");
rc = FCOPY("&in", "&out");
end;
else
do;
put @2 "The following file will NOT be replaced: "
/ @5 out_path;
rc = 1;
end;
end;
put @2 "Done with return code " rc=;
run;
filename &in clear;
filename &out clear;
options ls = &ls_tmp. ps = &ps_tmp.
&notes_tmp. &source_tmp.
&stimer_tmp. &fullstimer_tmp.
msglevel=&msglevel_tmp.;
%mend installPackage;
/*** HELP START ***/
/* Example 1:
filename packages "C:/Users/&sysuserid/Desktop/download_test/";
%installPackage(SQLinDS);
%installPackage(SQLinDS);
%installPackage(SQLinDS,replace=0);
%installPackage(NotExistingPackage);
*/
/*** HELP END ***/

View File

@@ -1,129 +0,0 @@
/*** HELP START ***/
/**############################################################################**/
/* */
/* Copyright Bartosz Jablonski, July 2019. */
/* */
/* Code is free and open source. If you want - you can use it. */
/* I tested it the best I could */
/* but it comes with absolutely no warranty whatsoever. */
/* If you cause any damage or something - it will be your own fault. */
/* You've been warned! You are using it on your own risk. */
/* However, if you decide to use it don't forget to mention author: */
/* Bartosz Jablonski (yabwon@gmail.com) */
/* */
/* Here is the official version: */
/*
Copyright (c) 2019 Bartosz Jablonski (yabwon@gmail.com)
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
*/
/**#############################################################################**/
/* Macros to list SAS packages in packages' folder, version 20200608 */
/* A SAS package is a zip file containing a group
of SAS codes (macros, functions, datasteps generating
data, etc.) wrapped up together and %INCLUDEed by
a single load.sas file (also embedded inside the zip).
*/
/*
* Example 1:
filename packages "C:\SAS_PACKAGES";
%include packages(listpackages.sas);
%listPackages()
*/
/*** HELP END ***/
%macro listPackages();
%local ls_tmp ps_tmp notes_tmp source_tmp;
%let filesWithCodes = WORK._%sysfunc(datetime(), hex16.)_;
%local ls_tmp ps_tmp notes_tmp source_tmp;
%let ls_tmp = %sysfunc(getoption(ls));
%let ps_tmp = %sysfunc(getoption(ps));
%let notes_tmp = %sysfunc(getoption(notes));
%let source_tmp = %sysfunc(getoption(source));
options NOnotes NOsource ls=MAX ps=MAX;
data _null_;
base = "%sysfunc(pathname(packages))";
if base = " " then
do;
put "NOTE: The filereference PACKAGES is not assigned.";
stop;
end;
length folder file $ 256 folderRef fileRef $ 8;
folderRef = "_%sysfunc(datetime(), hex6.)0";
rc=filename(folderRef, base);
folderid=dopen(folderRef);
put;
put "/*" 100*"+" ;
do i=1 to dnum(folderId); drop i;
folder = dread(folderId, i);
fileRef = "_%sysfunc(datetime(), hex6.)1";
rc = filename(fileRef, catx("/", base, folder));
fileId = dopen(fileRef);
EOF = 0;
if fileId = 0 and lowcase(scan(folder, -1, ".")) = 'zip' then
do;
file = catx('/',base, folder);
length nn $ 96;
nn = repeat("*", (96-lengthn(file)));
putlog " ";
put " * " file @; put nn /;
infile package ZIP FILEVAR=file member="description.sas" end=EOF;
do until(EOF);
input;
if lowcase(scan(_INFILE_,1,":")) in ("package" "title" "version" "author" "maintainer" "license") then
do;
_INFILE_ = scan(_INFILE_,1,":") !! ":" !! scan(_INFILE_,2,":");
putlog " * " _INFILE_;
end;
if strip(_INFILE_) = "DESCRIPTION START:" then leave;
end;
end;
rc = dclose(fileId);
rc = filename(fileRef);
end;
putlog " ";
put 100*"+" "*/";
rc = dclose(folderid);
rc = filename(folderRef);
stop;
run;
options ls = &ls_tmp. ps = &ps_tmp. &notes_tmp. &source_tmp.;
%mend listPackages;

View File

@@ -1,595 +0,0 @@
/*** HELP START ***/
/**############################################################################**/
/* */
/* Copyright Bartosz Jablonski, July 2019. */
/* */
/* Code is free and open source. If you want - you can use it. */
/* I tested it the best I could */
/* but it comes with absolutely no warranty whatsoever. */
/* If you cause any damage or something - it will be your own fault. */
/* You have been warned! You are using it on your own risk. */
/* However, if you decide to use it do not forget to mention author: */
/* Bartosz Jablonski (yabwon@gmail.com) */
/* */
/* Here is the official version: */
/*
Copyright (c) 2019 Bartosz Jablonski (yabwon@gmail.com)
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
*/
/**#############################################################################**/
/* Macros to load, to get help, or to unload SAS packages, version 20200610 */
/* A SAS package is a zip file containing a group of files
with SAS code (macros, functions, datasteps generating
data, etc.) wrapped up together and %INCLUDEed by
a single load.sas file (also embedded inside the zip).
*/
/*** HELP END ***/
/*** HELP START ***/
%macro loadPackage(
packageName /* name of a package,
e.g. myPackage,
required and not null */
, path = %sysfunc(pathname(packages)) /* location of a package,
by default it looks for
location of "packages" fileref */
, options = %str(LOWCASE_MEMNAME) /* posible options for ZIP filename */
, source2 = /*source2*/ /* option to print out details,
null by default */
, requiredVersion = . /* option to test if loaded package
is provided in required version */
, lazyData = /* a list of names of lazy datasets
to be loaded, if not null then
datasets from the list are loaded
instead of a package, asterisk
means "load all datasets" */
, zip = zip /* standard package is zip (lowcase),
e.g. %loadPackage(PiPackage)
if the zip is not avaliable use a folder
unpack data to "pipackage.disk" folder
and use loadPackage in the form:
%loadPackage(PiPackage, zip=disk, options=)
*/
)/secure;
/*** HELP END ***/
%if %superq(packageName) = %then
%do;
%put ;
%put ###############################################################################;
%put # This is short help information for the loadPackage macro #;
%put ###############################################################################;
%put # #;
%put # Macro to load SAS packages, version 20200610 #;
%put # #;
%put # A SAS package is a zip file containing a group #;
%put # of SAS codes (macros, functions, datasteps generating #;
%put # data, etc.) wrapped up together and included by #;
%put # a single load.sas file (also embedded inside the zip). #;
%put # #;
%put # Parameters: #;
%put # #;
%put # packageName Name of a package, e.g. myPackage, #;
%put # Required and not null, default use case: #;
%put # %nrstr(%%loadPackage(myPackage)). #;
%put # If empty displays this help information. #;
%put # #;
%put # path= Location of a package. By default it looks for #;
%put # location of the "packages" fileref, i.e. #;
%put # %nrstr(%%sysfunc(pathname(packages))) #;
%put # #;
%put # options= Posible options for ZIP filename, #;
%put # default value: LOWCASE_MEMNAME #;
%put # #;
%put # source2= Option to print out details, null by default. #;
%put # #;
%put # requiredVersion= Option to test if the loaded package #;
%put # is provided in required version, #;
%put # default value: . #;
%put # #;
%put # lazyData= A list of names of lazy datasets to be loaded. #;
%put # If not null datasets from the list are loaded #;
%put # instead of the package. #;
%put # Asterisk (*) means "load all datasets". #;
%put # #;
%put # zip=zip Standard package is zip (lowcase), #;
%put # e.g. %nrstr(%%loadPackage(PiPackage)). #;
%put # If the zip is not avaliable use a folder. #;
%put # Unpack data to "pipackage.disk" folder #;
%put # and use loadPackage in the following form: #;
%put # %nrstr(%%loadPackage(PiPackage, zip=disk, options=)) #;
%put # #;
%put ###############################################################################;
%put ;
%GOTO ENDloadPackage;
%end;
%local ls_tmp ps_tmp notes_tmp source_tmp fullstimer_tmp stimer_tmp msglevel_tmp;
%let ls_tmp = %sysfunc(getoption(ls));
%let ps_tmp = %sysfunc(getoption(ps));
%let notes_tmp = %sysfunc(getoption(notes));
%let source_tmp = %sysfunc(getoption(source));
%let stimer_tmp = %sysfunc(getoption(stimer));
%let fullstimer_tmp = %sysfunc(getoption(fullstimer));
%let msglevel_tmp = %sysfunc(getoption(msglevel));
options NOnotes NOsource ls=MAX ps=MAX NOfullstimer NOstimer msglevel=N;
%local _PackageFileref_;
%let _PackageFileref_ = P%sysfunc(MD5(%lowcase(&packageName.)),hex7.);
filename &_PackageFileref_. &ZIP.
/* put location of package myPackageFile.zip here */
"&path./%lowcase(&packageName.).&zip." %unquote(&options.)
;
%if %sysfunc(fexist(&_PackageFileref_.)) %then
%do;
%include &_PackageFileref_.(packagemetadata.sas) / &source2.;
filename &_PackageFileref_. clear;
/* test if required version of package is "good enough" */
%if %sysevalf(&requiredVersion. > &packageVersion.) %then
%do;
%put ERROR: Required version is &requiredVersion.;
%put ERROR- Provided version is &packageVersion.;
%ABORT;
%end;
options ls = &ls_tmp. ps = &ps_tmp. &notes_tmp. &source_tmp.;
filename &_PackageFileref_. &ZIP.
"&path./%lowcase(&packageName.).&zip." %unquote(&options.)
ENCODING =
%if %bquote(&packageEncoding.) NE %then &packageEncoding. ;
%else utf8 ;
;
%if %bquote(&lazyData.) = %then
%do;
%include &_PackageFileref_.(load.sas) / &source2.;
%end;
%else
%do;
%include &_PackageFileref_.(lazydata.sas) / &source2.;
%end;
%end;
%else %put ERROR:[&sysmacroname] File "&path./&packageName..&zip." does not exist;
filename &_PackageFileref_. clear;
options ls = &ls_tmp. ps = &ps_tmp.
&notes_tmp. &source_tmp.
&stimer_tmp. &fullstimer_tmp.
msglevel=&msglevel_tmp.;
/* jump here after running %loadPackage() - only help is displayed */
%ENDloadPackage:
%mend loadPackage;
/*** HELP START ***/
%macro unloadPackage(
packageName /* name of a package,
e.g. myPackage,
required and not null */
, path = %sysfunc(pathname(packages)) /* location of a package,
by default it looks for
location of "packages" fileref */
, options = %str(LOWCASE_MEMNAME) /* possible options for ZIP filename */
, source2 = /*source2*/ /* option to print out details,
null by default */
, zip = zip /* standard package is zip (lowcase),
e.g. %unloadPackage(PiPackage)
if the zip is not avaliable use a folder
unpack data to "pipackage.disk" folder
and use unloadPackage in the form:
%unloadPackage(PiPackage, zip=disk, options=)
*/
)/secure;
/*** HELP END ***/
%if %superq(packageName) = %then
%do;
%put ;
%put ###############################################################################;
%put # This is short help information for the unloadPackage macro #;
%put ###############################################################################;
%put # #;
%put # Macro to unload SAS packages, version 20200610 #;
%put # #;
%put # A SAS package is a zip file containing a group #;
%put # of SAS codes (macros, functions, datasteps generating #;
%put # data, etc.) wrapped up together and included by #;
%put # a single load.sas file (also embedded inside the zip). #;
%put # #;
%put # Parameters: #;
%put # #;
%put # packageName Name of a package, e.g. myPackage, #;
%put # Required and not null, default use case: #;
%put # %nrstr(%%unloadPackage(myPackage)). #;
%put # If empty displays this help information. #;
%put # #;
%put # path= Location of a package. By default it looks for #;
%put # location of the "packages" fileref, i.e. #;
%put # %nrstr(%%sysfunc(pathname(packages))) #;
%put # #;
%put # options= Posible options for ZIP filename, #;
%put # default value: LOWCASE_MEMNAME #;
%put # #;
%put # source2= Option to print out details, null by default. #;
%put # #;
%put # zip=zip Standard package is zip (lowcase), #;
%put # e.g. %nrstr(%%unloadPackage(PiPackage)). #;
%put # If the zip is not avaliable use a folder. #;
%put # Unpack data to "pipackage.disk" folder #;
%put # and use loadPackage in the following form: #;
%put # %nrstr(%%unloadPackage(PiPackage, zip=disk, options=)) #;
%put # #;
%put ###############################################################################;
%put ;
%GOTO ENDunloadPackage;
%end;
%local ls_tmp ps_tmp notes_tmp source_tmp msglevel_tmp;
%let ls_tmp = %sysfunc(getoption(ls));
%let ps_tmp = %sysfunc(getoption(ps));
%let notes_tmp = %sysfunc(getoption(notes));
%let source_tmp = %sysfunc(getoption(source));
%let msglevel_tmp = %sysfunc(getoption(msglevel));
options NOnotes NOsource ls=MAX ps=MAX msglevel=N;
%local _PackageFileref_;
%let _PackageFileref_ = P%sysfunc(MD5(%lowcase(&packageName.)),hex7.);
filename &_PackageFileref_. &ZIP.
/* put location of package myPackageFile.zip here */
"&path./%lowcase(&packageName.).&zip." %unquote(&options.)
;
%if %sysfunc(fexist(&_PackageFileref_.)) %then
%do;
%include &_PackageFileref_.(packagemetadata.sas) / &source2.;
filename &_PackageFileref_. clear;
options ls = &ls_tmp. ps = &ps_tmp. &notes_tmp. &source_tmp.;
filename &_PackageFileref_. &ZIP.
"&path./%lowcase(&packageName.).&zip." %unquote(&options.)
ENCODING =
%if %bquote(&packageEncoding.) NE %then &packageEncoding. ;
%else utf8 ;
;
%include &_PackageFileref_.(unload.sas) / &source2.;
%end;
%else %put ERROR:[&sysmacroname] File "&path./&packageName..&zip." does not exist;
filename &_PackageFileref_. clear;
options ls = &ls_tmp. ps = &ps_tmp. &notes_tmp. &source_tmp. msglevel = &msglevel_tmp.;
/* jump here after running %unloadPackage() - only help is displayed */
%ENDunloadPackage:
%mend unloadPackage;
/*** HELP START ***/
%macro helpPackage(
packageName /* name of a package,
e.g. myPackageFile.zip,
required and not null */
, helpKeyword /* phrase to search in help,
when empty prints description
"*" means prints all help
"license" prints license */
, path = %sysfunc(pathname(packages)) /* location of a package,
by default it looks for
location of "packages" fileref */
, options = %str(LOWCASE_MEMNAME) /* possible options for ZIP filename */
, source2 = /*source2*/ /* option to print out details,
null by default */
, zip = zip /* standard package is zip (lowcase),
e.g. %helpPackage(PiPackage,*)
if the zip is not avaliable use a folder
unpack data to "pipackage.disk" folder
and use helpPackage in the form:
%helpPackage(PiPackage, *, zip=disk, options=)
*/
)/secure;
/*** HELP END ***/
%if %superq(packageName) = %then
%do;
%put ;
%put ###############################################################################;
%put # This is short help information for the helpPackage macro #;
%put ###############################################################################;
%put # #;
%put # Macro to get help about SAS packages, version 20200610 #;
%put # #;
%put # A SAS package is a zip file containing a group #;
%put # of SAS codes (macros, functions, datasteps generating #;
%put # data, etc.) wrapped up together and included by #;
%put # a single load.sas file (also embedded inside the zip). #;
%put # #;
%put # Parameters: #;
%put # #;
%put # packageName Name of a package, e.g. myPackage, #;
%put # Required and not null, default use case: #;
%put # %nrstr(%%helpPackage(myPackage)). #;
%put # If empty displays this help information. #;
%put # #;
%put # helpKeyword Phrase to search in help, #;
%put # - when empty prints description, #;
%put # - "*" means prints all help, #;
%put # - "license" prints license. #;
%put # #;
%put # path= Location of a package. By default it looks for #;
%put # location of the "packages" fileref, i.e. #;
%put # %nrstr(%%sysfunc(pathname(packages))) #;
%put # #;
%put # options= Posible options for ZIP filename, #;
%put # default value: LOWCASE_MEMNAME #;
%put # #;
%put # source2= Option to print out details, null by default. #;
%put # #;
%put # zip=zip Standard package is zip (lowcase), #;
%put # e.g. %nrstr(%%helpPackage(PiPackage)). #;
%put # If the zip is not avaliable use a folder. #;
%put # Unpack data to "pipackage.disk" folder #;
%put # and use loadPackage in the following form: #;
%put # %nrstr(%%helpPackage(PiPackage, zip=disk, options=)) #;
%put # #;
%put ###############################################################################;
%put ;
%GOTO ENDhelpPackage;
%end;
%local ls_tmp ps_tmp notes_tmp source_tmp msglevel_tmp;
%let ls_tmp = %sysfunc(getoption(ls));
%let ps_tmp = %sysfunc(getoption(ps));
%let notes_tmp = %sysfunc(getoption(notes));
%let source_tmp = %sysfunc(getoption(source));
%let msglevel_tmp = %sysfunc(getoption(msglevel));
options NOnotes NOsource ls=MAX ps=MAX msglevel=N;
%local _PackageFileref_;
%let _PackageFileref_ = P%sysfunc(MD5(%lowcase(&packageName.)),hex7.);
filename &_PackageFileref_. &ZIP.
/* put location of package myPackageFile.zip here */
"&path./%lowcase(&packageName.).&zip." %unquote(&options.)
;
%if %sysfunc(fexist(&_PackageFileref_.)) %then
%do;
%include &_PackageFileref_.(packagemetadata.sas) / &source2.;
filename &_PackageFileref_. clear;
options ls = &ls_tmp. ps = &ps_tmp. &notes_tmp. &source_tmp.;
filename &_PackageFileref_. &ZIP.
"&path./%lowcase(&packageName.).&zip." %unquote(&options.)
ENCODING =
%if %bquote(&packageEncoding.) NE %then &packageEncoding. ;
%else utf8 ;
;
%include &_PackageFileref_.(help.sas) / &source2.;
%end;
%else %put ERROR:[&sysmacroname] File "&path./&packageName..&zip." does not exist;
filename &_PackageFileref_. clear;
options ls = &ls_tmp. ps = &ps_tmp. &notes_tmp. &source_tmp. msglevel = &msglevel_tmp.;
/* jump here after running %helpPackage() - only help is displayed */
%ENDhelpPackage:
%mend helpPackage;
/*
TODO:
- macro for testing available packages in the packages folder [DONE] checkout: %listPackages()
- add MD5(&packageName.) value hash instead "package" word in filenames [DONE]
*/
/*** HELP START ***/
/*
* Filenames references "packages" and "package" are keywords;
* the first one should be used to point folder with packages;
* the second is used internally by macros;
* Example 1:
* assuming that _THIS_FILE_ and the SQLinDS package (sqlinds.zip file)
* are located in the "C:/SAS_PACKAGES/" folder
* copy the following code into autoexec.sas
* or run it in your SAS session
**/
/*
filename packages "C:/SAS_PACKAGES";
%include packages(loadpackage.sas);
%loadpackage(SQLinDS)
%helpPackage(SQLinDS)
%unloadPackage(SQLinDS)
* optional;
libname packages "C:/SAS_PACKAGES/";
%include "%sysfunc(pathname(packages))/loadpackage.sas";
%loadPackage(SQLinDS)
%helpPackage(SQLinDS)
%unloadPackage(SQLinDS)
* in case when user SAS session does not support ZIP fileref ;
* the following solution could be used, ;
* unzip packagename.zip content into packagename.disk folder ;
* and run macros with following options: ;
%loadPackage(packageName,zip=disk,options=)
%helpPackage(packageName,,zip=disk,options=) %* mind double comma! ;
%unloadPackage(packageName,zip=disk,options=)
*/
/*** HELP END ***/
/*** HELP START ***/
/* Macros to install SAS packages, version 20200603 */
/* A SAS package is a zip file containing a group of files
with SAS code (macros, functions, datasteps generating
data, etc.) wrapped up together and %INCLUDEed by
a single load.sas file (also embedded inside the zip).
*/
/*** HELP END ***/
/*** HELP START ***/
%macro installPackage(
packageName /* package name, without the zip extension */
, sourcePath = /* location of the package, e.g. "www.some.page/", mind the "/" at the end */
, replace = 1 /* 1 = replace if the package already exist, 0 = otherwise */
)
/*** HELP END ***/
/
secure;
%if %superq(packageName) = %then
%do;
%put ;
%put ###############################################################################;
%put # This is short help information for the installPackage macro #;
%put ###############################################################################;
%put # #;
%put # Macro to install SAS packages, version 20200610 #;
%put # #;
%put # A SAS package is a zip file containing a group #;
%put # of SAS codes (macros, functions, datasteps generating #;
%put # data, etc.) wrapped up together and included by #;
%put # a single load.sas file (also embedded inside the zip). #;
%put # #;
%put # Parameters: #;
%put # #;
%put # packageName Name of a package, e.g. myPackage, #;
%put # Required and not null, default use case: #;
%put # %nrstr(%%installPackage(myPackage)). #;
%put # If empty displays this help information. #;
%put # #;
%put # sourcePath= Location of the package, e.g. "www.some.web.page/" #;
%put # Mind the "/" at the end of the path! #;
%put # Current default location: #;
%put # https://raw.githubusercontent.com/yabwon/SAS_PACKAGES/master/ #;
%put # #;
%put # replace= With default value of 1 it causes existing package file #;
%put # to be replaceed by new downloaded file. #;
%put # #;
%put ###############################################################################;
%put ;
%GOTO ENDinstallPackage;
%end;
%local ls_tmp ps_tmp notes_tmp source_tmp fullstimer_tmp stimer_tmp msglevel_tmp;
%let ls_tmp = %sysfunc(getoption(ls));
%let ps_tmp = %sysfunc(getoption(ps));
%let notes_tmp = %sysfunc(getoption(notes));
%let source_tmp = %sysfunc(getoption(source));
%let stimer_tmp = %sysfunc(getoption(stimer));
%let fullstimer_tmp = %sysfunc(getoption(fullstimer));
%let msglevel_tmp = %sysfunc(getoption(msglevel));
options NOnotes NOsource ls=MAX ps=MAX NOfullstimer NOstimer msglevel=N;
%local in out;
%let in = i%sysfunc(md5(&packageName.),hex7.);
%let out = o%sysfunc(md5(&packageName.),hex7.);
/*options MSGLEVEL=i;*/
/*
Reference:
https://blogs.sas.com/content/sasdummy/2011/06/17/how-to-use-sas-data-step-to-copy-a-file-from-anywhere/
*/
%if %superq(sourcePath)= %then
%do;
%let sourcePath = https://raw.githubusercontent.com/yabwon/SAS_PACKAGES/master/;
%end;
filename &in URL "&sourcePath.%lowcase(&packageName.).zip" recfm=N lrecl=1;
filename &out "%sysfunc(pathname(packages))/%lowcase(&packageName.).zip" recfm=N lrecl=1;
/*
filename in list;
filename out list;
*/
/* copy the file byte-by-byte */
data _null_;
length filein 8 out_path in_path $ 4096;
out_path = pathname ("&out");
in_path = pathname ("&in" );
filein = fopen( "&in", 'S', 1, 'B');
if filein = 0 then
put "ERROR: Source file:" /
"ERROR- " in_path /
"ERROR- is unavaliable!";
if filein > 0;
put @2 "Source information:";
infonum = FOPTNUM(filein);
length infoname $ 32 infoval $ 128;
do i=1 to coalesce(infonum, -1);
infoname = FOPTNAME(filein, i);
infoval = FINFO(filein, infoname);
put @4 infoname ":"
/ @6 infoval
;
end;
rc = FCLOSE(filein);
put;
if FEXIST("&out") = 0 then
do;
put @2 "Installing the &packageName. package.";
rc = FCOPY("&in", "&out");
end;
else if FEXIST("&out") = 1 then
do;
if symget("replace")="1" then
do;
put @2 "The following file will be replaced during "
/ @2 "instalation of the &packageName. package: "
/ @5 out_path;
rc = FDELETE("&out");
rc = FCOPY("&in", "&out");
end;
else
do;
put @2 "The following file will NOT be replaced: "
/ @5 out_path;
rc = 1;
end;
end;
put @2 "Done with return code " rc=;
run;
filename &in clear;
filename &out clear;
options ls = &ls_tmp. ps = &ps_tmp.
&notes_tmp. &source_tmp.
&stimer_tmp. &fullstimer_tmp.
msglevel=&msglevel_tmp.;
/* jump here after running %installPackage() - only help is displayed */
%ENDinstallPackage:
%mend installPackage;
/*** HELP START ***/
/* Example 1:
filename packages "C:/Users/&sysuserid/Desktop/download_test/";
%installPackage(SQLinDS);
%installPackage(SQLinDS);
%installPackage(SQLinDS,replace=0);
%installPackage(NotExistingPackage);
*/
/*** HELP END ***/

Binary file not shown.

96
packages/README.md Normal file
View File

@@ -0,0 +1,96 @@
## SAS Packages:
To get started with SAS Packages try this [**`Getting Started with SAS Packages`**](https://github.com/yabwon/SAS_PACKAGES/blob/master/SPF/Documentation/Getting_Started_with_SAS_Packages.pdf "Getting Started with SAS Packages") presentation (see the `./SPF/Documentation` directory).
## Available packages:
Currently the following packages are available:
- **SQLinDS**\[2.2\], based on Mike Rhoads' article *Use the Full Power of SAS in Your Function-Style Macros*. The package allows to write SQL queries in the data step, e.g.
```
data class;
set %SQL(
select age, name, weight, height
from sashelp.class
order by age
);
WH = weight + height;
run;
```
SHA256 digest for SQLinDS: B280D0B72DB77001ADAAE9C1612B67AD30C2C672371B27F1ACB12016C7A1363D
[Documentation for SQLinDS](https://github.com/yabwon/SAS_PACKAGES/blob/master/packages/sqlinds.md "Documentation for SQLinDS")
- **DFA** (Dynamic Function Arrays)\[0.2\], contains set of macros and FCMP functions which implement: a dynamically allocated array, a stack, a fifo queue, an ordered stack, and a priority queue, run `%helpPackage(DFA,createDFArray)` to find examples.
```
%createDFArray(ArrDynamic, resizefactor=17);
data _null_;
call ArrDynamic("Allocate", -2, 2);
do i = -2 to 2;
call ArrDynamic("Input", i, 2**i);
end;
L = .; H = .;
call ArrDynamic("Dim", L, H);
put L= H=;
call ArrDynamic("+", 3, 8);
call ArrDynamic("+",-3, 0.125);
call ArrDynamic("Dim", L, H);
put L= H=;
Value = .;
do i = L to H;
call ArrDynamic("O", i, Value);
put i= Value=;
end;
run;
```
SHA256 digest for DFA: BB8768E977D62429368CFF2E5338A6553C35C998AEC09AF24088BA713BB54DDA
- **macroArray**\[0.5\], implementation of an array concept in a macro language, e.g.
```
%array(ABC[17] (111:127), macarray=Y);
%macro test();
%do i = 1 %to 17;
%put &i.) %ABC(&i.);
%end;
%mend;
%test()
%let %ABC(13,i) = 99999; /* i = insert */
%do_over(ABC, phrase=%nrstr(
%put &_i_.%) %ABC(&_i_.);
),
which = 1:H:2
);
```
SHA256 digest for macroArray: 53C248E1DE3268946C9CEC7E77BC222F652FBB006D9317BE36B86410DA31AE35
[Documentation for macroArray](https://github.com/yabwon/SAS_PACKAGES/blob/master/packages/macroarray.md "Documentation for macroArray")
- **BasePlus**\[0.62\] adds a bunch of functionalities I am missing in BASE SAS, such as:
```
call arrMissToRight(myArray);
call arrFillMiss(17, myArray);
call arrFill(42, myArray);
rc = delDataset("DataSetToDrop");
string = catXFn("date9.", "#", myArray);
format x bool.;
%put %getVars(sashelp.class, pattern = ght$, sep = +, varRange = _numeric_);
```
SHA256 digest for BasePlus: 278621A6D8BBBB791DEA4C215D4261F2CB8F8B76B1397F7FA9B2E4219E77CB5A
- **dynMacroArray**\[0.2\], set of macros (wrappers for a hash table) emulating dynamic array in the data step (macro predecessor of DFA)
SHA256 digest for dynMacroArray: 066186B94B2976167C797C6A6E6217E361E8DEB10F2AB81906E0A325E5243084

View File

@@ -0,0 +1,15 @@
/* 20200914 */
macroArray: 53C248E1DE3268946C9CEC7E77BC222F652FBB006D9317BE36B86410DA31AE35
SQLinDS: B280D0B72DB77001ADAAE9C1612B67AD30C2C672371B27F1ACB12016C7A1363D
/* 20200914 */
SQLinDS: DD5E319EB5AA29C7054EC428072F987E77C29D36874DED1AE5C62E4B300845EB
macroArray: 69F6CF496F921D0E21F3524FC7FD130B4B8290C1E0B9BB3ABEA212B734EBE8A1
/* 20200911 */
sqlindsdemo: CCA3CB51587E30D1A4338EAF732EF03E0922918AAA21C3ECF85CABE93CD2FB15
macroArray: 5C9208ADD091E354794C24FA830F527D17CFC758C24CB77BF2154949059F7E6F
BasePlus: 278621A6D8BBBB791DEA4C215D4261F2CB8F8B76B1397F7FA9B2E4219E77CB5A
SQLinDS: 3EBC11A0890B6128DDB51643DC91F9DA1BDBF283535664540887FA7E7EA9744F
dynMacroArray: 066186B94B2976167C797C6A6E6217E361E8DEB10F2AB81906E0A325E5243084
DFA: BB8768E977D62429368CFF2E5338A6553C35C998AEC09AF24088BA713BB54DDA

View File

@@ -1,7 +1,7 @@
filename packages "C:\SAS_PACKAGES";
%include packages(generatePackage.sas);
filename packages "C:\SAS_PACKAGES\SASPackagesFramework";
%include packages(SPFinit.sas);
ods html;
%generatePackage(filesLocation=C:\SAS_PACKAGES_DEV\SQLinDS)
@@ -13,7 +13,7 @@ ods html;
* the second is used internally by macros;
filename packages "C:\SAS_PACKAGES";
%include packages(loadpackage.sas);
%include packages(SPFinit.sas);
dm 'log;clear';
%loadpackage(SQLinDS)

BIN
packages/baseplus.zip Normal file

Binary file not shown.

Binary file not shown.

1168
packages/macroarray.md Normal file

File diff suppressed because it is too large Load Diff

BIN
packages/macroarray.zip Normal file

Binary file not shown.

175
packages/sqlinds.md Normal file
View File

@@ -0,0 +1,175 @@
- [The SQLinDS package [ver. 2.2]](#sqlinds-package)
- [Content description](#content-description)
* [library `dsSQL`](#library-dssql)
* [`%dsSQL_inner()` macro](#dssql-inner-macro)
* [`%SQL()` macro](#dssql-inner-macro)
* [`dsSQL()` function](#dssql-function)
* [License](#license)
---
# The SQLinDS package [ver. 2.2] <a name="sqlinds-package"></a> ###############################################
The **SQLinDS** package is an implementation of
the *macro-function-sandwich* concept introduced in the
*"Use the Full Power of SAS in Your Function-Style Macros"*,
the article by *Mike Rhoads (Westat, Rockville)*.
Copy of the article is available at:
[https://support.sas.com/resources/papers/proceedings12/004-2012.pdf](https://support.sas.com/resources/papers/proceedings12/004-2012.pdf)
Package provides ability to *execute* SQL queries inside a data step, e.g.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~sas
data class;
set %SQL(select * from sashelp.class);
run;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
See the help for the `%SQL()` macro to find more examples.
### Content ###################################################################
SQLinDS package contains the following components:
1. `%SQL()` macro - the main package macro available for the User
2. `dsSQL()` function (internal)
3. `%dsSQL_inner()` macro (internal)
4. Library `DSSQL` (created as a subdirectory of the `WORK` library)
---
Package contains:
1. libname dssql
2. macro dssql_inner
3. macro sql
4. function dssql
Required SAS Components:
*Base SAS Software*
*SAS package generated by generatePackage, version 20200911*
The SHA256 hash digest for package SQLinDS:
`B280D0B72DB77001ADAAE9C1612B67AD30C2C672371B27F1ACB12016C7A1363D`
---
# Content description ############################################################################################
## >>> library `dsSQL`: <<< <a name="library-dssql"></a> ########################
The `dsSQL` library stores temporary views
generated during the `%SQL()` macro execution.
If possible a subdirectory of the `WORK` location is created, like:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~sas
LIBNAME dsSQL BASE "%sysfunc(pathname(WORK))/dsSQLtmp";
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
if not possible, then redirects to the `WORK` location, like:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~sas
LIBNAME dsSQL BASE "%sysfunc(pathname(WORK))";
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
---
## >>> `%dsSQL_Inner()` macro: <<< <a name="dssql-inner-macro"></a> #############
**Internal** macro called by `dsSQL()` function.
The macro generates a uniquely named SQL view on the fly
which is then stored in the `dsSQL` library.
Recommended for *SAS 9.3* and higher.
---
## >>> `%SQL()` macro: <<< <a name="dssql-macro"></a> ###########################
The **main** macro which allows to use
SQL queries in the data step.
Recommended for *SAS 9.3* and higher.
Based on the article *"Use the Full Power of SAS in Your Function-Style Macros"*
by *Mike Rhoads* (Westat, Rockville), available at:
[https://support.sas.com/resources/papers/proceedings12/004-2012.pdf](https://support.sas.com/resources/papers/proceedings12/004-2012.pdf)
### SYNTAX: ###################################################################
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~sas
%sql(<nonempty sql querry code>)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The sql query code is limited to *32000* bytes.
### EXAMPLES: #################################################################
**EXAMPLE 1**: simple SQL query
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~sas
data class_subset;
set %SQL(select name, sex, height from sashelp.class where age > 12);
run;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
**EXAMPLE 2**: query with dataset options
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~sas
data renamed;
set %SQL(select * from sashelp.class where sex = "F")(rename = (age=age2));
run;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
**EXAMPLE 3**: dictionaries in the data step
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~sas
data dictionary;
set %SQL(select * from dictionary.macros);
run;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
---
## >>> `dsSQL()` function: <<< <a name="dssql-function"></a> ####################
**Internal** function called by the `%SQL()` macro.
The function pass a query code from the `%SQL()`
macro to the `%dsSQL_Inner()` internal macro.
Recommended for *SAS 9.3* and higher.
### SYNTAX: ###################################################################
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~sas
dsSQL(unique_index_2, query)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
**Arguments description**:
1. `unique_index_2` - *Numeric*, internal variable, a unique index for views.
2. `query` - *Character*, internal variable, contains query text.
---
## License ####################################################################
Copyright (c) 2012 Mike Rhoads
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
---

BIN
packages/sqlinds.zip Normal file

Binary file not shown.

Binary file not shown.