Convert SQL to SAS7BDAT
Turn SQL files into SAS7BDAT files. A SAS 9 data set in UTF-8.
Converted in an isolated sandbox on our serversDeleted after 24 hours
Drop SQL files on the dialor turn it to pick what to do
One SAS data set for each table in your script.Each table the script creates becomes a SAS 9 data set in UTF-8.
What you get
One SAS7BDAT file per table the script creates, named after the table and in name order. A dump from MySQL, MariaDB or PostgreSQL is rewritten into SQLite's dialect first.
Integers and decimals become numbers. Columns declared DATE, DATETIME or TIMESTAMP become dates and date-times. Binary values become escaped text, and NULL becomes missing.
How columns and dates are handled
Text columns stay text, even when they hold dates. Only columns declared as DATE, DATETIME or TIMESTAMP become dates.
Dates get the format E8601DA, date-times E8601DT and times E8601TM. In a table with text longer than 2,045 bytes, they keep their SAS values without a format.
Dates that are not real dates, such as MySQL's 0000-00-00, become missing. PostgreSQL true and false become 1 and 0.
Column names become SAS names of up to 32 Latin letters, digits and underscores. When a name changes, the original is kept as the variable label.
What is left out
Tables without rows are left out with a warning. Views, functions and triggers are left out with a warning too.
Text longer than 32,767 bytes is cut.
SQL and SAS7BDAT.What each format is.
The formats
SQL Script
SQL statements as text. A database dump that any SQL tool can read or replay.
- Extensions
- .sql
- MIME type
- application
/sql - Kind
- Text and data
SAS Data
SAS datasets.
- Extensions
- .sas7bdat
- MIME type
- application
/x -sas -data - Kind
- Text and data
In your code.The same SQL to SAS7BDAT conversion through the API, for your app or your agent.
$ cv convert report.sql report/ --to sas7bdat$ cv convert report.sql report/ --to sas7bdatQuestions.What people ask about SQL to SAS7BDAT.
One file per table the script creates, named after the table. The files come in name order.
NULL becomes missing in the SAS data set.
Yes. A dump from MySQL, MariaDB or PostgreSQL is rewritten into SQLite's dialect first, and then each table is converted.
SAS names allow up to 32 Latin letters, digits and underscores. A changed name keeps the original as its variable label.