10 - Run the ESQL Preprocessor and UltraLite Analyzer
-
Make sure the reference database is up and running. In this article,
the reference and consolidated databases are one and the same, and the
batch file run_ASA6_dbsrv6_on_ulldemo1.bat can be used to start the server:
Warning! One of the lines in this batch file has been wrapped to fit
on the screen.
SET ASA=E:\Program Files\Sybase\Adaptive Server Anywhere 6.0\win32
SET DB=c:\amisc\ull
rem -c initial cache size
rem -gp maximum page size
rem -n server name
rem -x communication links
rem -n database name
"%ASA%\dbsrv6.exe" -c 10m -gp 4096 -n ulldemo1 -x none
"%DB%\ulldemo1.db" -n ulldemo1
|
-
Run the run_ASA6_sqlpp_on_ulldemo1.bat file to preprocess
the ulldemo1.sqc source code into ulldemo1.c:
Warning! One of the lines in this batch file has been wrapped to fit
on the screen.
SET ASA=E:\Program Files\Sybase\Adaptive Server Anywhere 6.0\win32
SET DB=c:\amisc\ull
SET SRC=c:\amisc\ull\src
rem -c connection parameter
rem *.sqc input source
rem *.c preprocessed output
"%ASA%\sqlpp.exe" -c "DSN=ulldemo1" "%SRC%\ulldemo1.sqc"
"%SRC%\ulldemo1.c"
|
By default, SQLPP will call the UltraLite Generator ULGEN so that everything is done
in one swell foop:
-
If you want to be terrified, have a look at the output from SQLPP in the
c:\amisc\ull\Src\ulldemo.c file.
Warning! Please don't edit the ulldemo.c file!
It's tempting, because it's the
one that shows up in CodeWarrior, and it's the one that shows up in error messages
and debugging windows.
However, it will get replaced every time you run SQLPP,
so make sure you only work on the ulldemo.sqc file.
In ulldemo.c you can see where the ESQL has been /* commented out */, and
where some really nasty C code has been added:
|
|