Articles in category

Utility

37 Résultats disponibles

CODE SAS
dirlist.sas - Macro to list files

This SAS macro allows listing the names of all files in a specified folder location. It can eithe...

Lire la suite
CODE SAS
Cross-Platform Binary File Copy

SAS macro to copy any file byte by byte using binary input/output streams, offering an operating ...

Lire la suite
CODE SAS
Check for Folder Existence on SAS Drive

This macro checks if a specified folder exists on SAS Drive. It returns '1' if the folder exists ...

Lire la suite
CODE SAS
Checking for File Existence on SAS Drive

This SAS macro checks if a specified file exists on SAS Drive. It returns 1 if the file is found ...

Lire la suite
CODE SAS
Defining HTTP Headers for SASjs/server

This SAS macro defines custom HTTP headers for SASjs server responses. It works by writing the sp...

Lire la suite
CODE SAS
Macro mf_mkdir - Recursive Directory Creation

This SAS macro, `mf_mkdir`, creates a directory on the file system, including all necessary inter...

Lire la suite
CODE SAS
List dataset variables

This macro returns the list of variables in a SAS dataset, with options to format the output (del...

Lire la suite
CODE SAS
Generate a unique SAS libref

This macro generates a unique SAS libref by appending a numeric suffix to a given prefix, to avoi...

Lire la suite
CODE SAS
Dynamic Macro Execution on Metadata

Script dynamically generating macro calls for tables whose name contains a specific pattern.

Lire la suite
CODE SAS
Display the content of the temporary macro catalog

This script uses PROC CATALOG to list the entries (compiled macros) of the temporary 'sasmacr' ca...

Lire la suite
CODE SAS
Macro lsfp2ds

Creates a SAS dataset from a list of Unix/Linux file names with full paths.

Lire la suite
CODE SAS
Create a SAS dataset from a list of Unix/Linux files

SAS macro to list Unix/Linux filenames and write them into a SAS dataset.

Lire la suite
CODE SAS
Example of writing with automatic page variables

The SAS script demonstrates the use of the FILE statement with the PRINT option to write lines to...

Lire la suite
CODE SAS
Export JSON from SASHELP.ORSALES

Export a SASHELP table to JSON and display it in the log.

Lire la suite
CODE SAS
Emits an error message to a logger

This macro emits an error message to a specified logger.

Lire la suite
CODE SAS
Sending a Debug Message to the Log

This macro sends a debug-level message to a specified logger via the log4sas_logevent function. I...

Lire la suite
CODE SAS
Example of using the %help macro

This script demonstrates the use of the standard SAS %help macro to obtain information about othe...

Lire la suite
CODE SAS
Macro to retrieve a variable's label

This SAS macro dynamically retrieves the label associated with a specific variable in a SAS dataset.

Lire la suite
CODE SAS
Generating SAS documentation in Markdown and HTML

This SAS script uses the %code_diary and %convert_markdown_to_html macros to generate documentati...

Lire la suite
CODE SAS
Definition of numeric format fmtNum

Defines a custom SAS value format named fmtNum to categorize numbers.

Lire la suite
CODE SAS
Function F1

This script defines a simple SAS function named F1 that takes a number as input and returns this ...

Lire la suite
CODE SAS
SAS Email Notification

This SAS script defines and uses macros to send email notifications, including the start and end ...

Lire la suite
CODE SAS
Viewing FCMP Function Libraries

This SAS script is used to list and view the contents of an FCMP function library, specifically '...

Lire la suite
CODE SAS
Deletion of WORK data

This script deletes all temporary data tables (memtype=data) from the WORK library.

Lire la suite
CODE SAS
Utility macro to delete a file

This macro allows you to delete a file from the file system if it exists.

Lire la suite
CODE SAS
SAS Tables Deletion Demonstration

This script illustrates the use of the `%delete_dataset` macro to delete SAS tables in various ways.

Lire la suite
CODE SAS
SAS Macro _DATA: Extracting Table Name

This SAS macro extracts the name of a table from a complete reference (library.table) or a simple...

Lire la suite
CODE SAS
Execute a system command and capture output into a dataset

This SAS macro allows executing a local operating system command and capturing its output line by...

Lire la suite
CODE SAS
Log and Output Cleaning

This macro resets the output, log, and ODS results windows in the SAS environment.

Lire la suite
CODE SAS
Email Address Validation with PRXMATCH and FCMP

This SAS script validates email addresses using a custom `CheckMail` function defined with `PROC ...

Lire la suite
CODE SAS
CDM Schema Validation

SAS macro to validate the compatibility of UDM and CDM schema versions.

Lire la suite
CODE SAS
HTTP GET Request with Basic Authentication and JSON Processing

This SAS script performs an HTTP GET request to an external URL protected by basic authentication...

Lire la suite
CODE SAS
SAS Catalog Scan Utility

This macro allows exploring and printing the source content of a specified SAS catalog to a text ...

Lire la suite
CODE SAS
WORK Library Consultation

Execution of the DATASETS procedure to list the contents of the temporary WORK library.

Lire la suite
CODE SAS
CCLI Library Definition

This SAS script defines a macro that creates a SAS library ('libname') pointing to a specified pa...

Lire la suite
CODE SAS
Cleaning the WORK macro catalog

Macro to delete the compiled macro catalog in the temporary WORK library.

Lire la suite
CODE SAS
SAS Header Options Documentation

This comment block provides a standard description of commonly used SAS options for script header...

Lire la suite