sql varchar
Sponsored Links
Sponsored Links
Secleted [ 0 ] software to compare
Results 1 - 15 of about 850
SQL Relay 0.39
SQL Relay is a persistent database connection pooling, proxying and load balancing system for Unix and Linux. more>>
SQL Relay is a persistent database connection pooling, proxying and load balancing system for Unix and Linux.
Main features:
SQL Relay is ideal for:
- speeding up database-driven web-based applications
- enhancing the scalability of database-driven web-based applications
- distributing access to replicated databases
- throttling database access
- accessing databases from unsupported platforms
- migrating applications from one database to another
SQL Relay supports the following database backends:
- Oracle
- MySQL
- mSQL
- PostgreSQL
- Sybase
- MS SQL Server
- IBM DB2
- Interbase
- Sybase
- SQLite
- ODBC
- MS Access
The SQL Relay client APIs support advanced database operations such as bind variables, multi-row fetches, client-side result set caching and suspended transactions. SQL Relay has native client APIs for the following languages:
- C
- C++
- Perl
- Python
- PHP
- Ruby
- Java
- TCL
- Zope
SQL Relay provides drivers for the following database abstraction layers:
- Perl DBD
- Python DB
- Ruby DBD
- PHP Pear DB
An application coded using another databases native client API may be able to use SQL Relay without modification. SQL Relay provides drop-in replacement libraries for:
- MySQL
- PostgreSQL
SQL Relay also features:
- command line clients
- a GUI configuration tool
- extensive documentation
Enhancements:
- Several contributed patches were applied.
- Oracle stability was improved.
- Support for Oracle OS-authentication was added.
- The maxlisteners option was added.
- Support for Sybase stored procedures which return result sets was added.
- A Zope empty-result set bug was fixed.
- Support for Mac OS X, Solaris, and Cygwin was improved.
<<lessMain features:
SQL Relay is ideal for:
- speeding up database-driven web-based applications
- enhancing the scalability of database-driven web-based applications
- distributing access to replicated databases
- throttling database access
- accessing databases from unsupported platforms
- migrating applications from one database to another
SQL Relay supports the following database backends:
- Oracle
- MySQL
- mSQL
- PostgreSQL
- Sybase
- MS SQL Server
- IBM DB2
- Interbase
- Sybase
- SQLite
- ODBC
- MS Access
The SQL Relay client APIs support advanced database operations such as bind variables, multi-row fetches, client-side result set caching and suspended transactions. SQL Relay has native client APIs for the following languages:
- C
- C++
- Perl
- Python
- PHP
- Ruby
- Java
- TCL
- Zope
SQL Relay provides drivers for the following database abstraction layers:
- Perl DBD
- Python DB
- Ruby DBD
- PHP Pear DB
An application coded using another databases native client API may be able to use SQL Relay without modification. SQL Relay provides drop-in replacement libraries for:
- MySQL
- PostgreSQL
SQL Relay also features:
- command line clients
- a GUI configuration tool
- extensive documentation
Enhancements:
- Several contributed patches were applied.
- Oracle stability was improved.
- Support for Oracle OS-authentication was added.
- The maxlisteners option was added.
- Support for Sybase stored procedures which return result sets was added.
- A Zope empty-result set bug was fixed.
- Support for Mac OS X, Solaris, and Cygwin was improved.
Download (8.6MB)
Added: 2007-08-04 License: GPL (GNU General Public License) Price:
497 downloads
SQL::Schema 0.31
SQL::Schema is a Perl module to convert a data dictionary into SQL statements. more>>
SQL::Schema is a Perl module to convert a data dictionary into SQL statements.
SYNOPSIS
use DBI;
my $dbh = DBI->connect(...);
use SQL::Schema;
my $schema = SQL::Schema->new($dbh);
my $sql = $schema->string;
print $sql;
print "$schema";
WARNING
This is alpha software. It currently works with Oracle databases only. The name of the module might be changed in future releases as well as its interface.
If somebody is modifying the datase schema during the life time of an SQL::Schema object, the object will probably fail and / or produce wrong information.
SQL::Schema is a class for objects representing a database schema. The methods of an instanciated object do allow to access the information within a databases data dictionary and to represent them as SQL create statements and the like using the proper SQL dialect.
Constructor
$schema = SQL::Schema->new($dbh);
The new method instanciates a schema object. The only argument required is a database handle, which has to offer the same API as described within DBI(3).
Methods
$sql = $schema->string;
Returns an SQL string containing several statements at once. This string contains all the SQL statements to create the database schema.
This method is overloaded with the string operator. So the following two lines are equivalent:
$sql = $schema->string;
$sql = "$schema";
<<lessSYNOPSIS
use DBI;
my $dbh = DBI->connect(...);
use SQL::Schema;
my $schema = SQL::Schema->new($dbh);
my $sql = $schema->string;
print $sql;
print "$schema";
WARNING
This is alpha software. It currently works with Oracle databases only. The name of the module might be changed in future releases as well as its interface.
If somebody is modifying the datase schema during the life time of an SQL::Schema object, the object will probably fail and / or produce wrong information.
SQL::Schema is a class for objects representing a database schema. The methods of an instanciated object do allow to access the information within a databases data dictionary and to represent them as SQL create statements and the like using the proper SQL dialect.
Constructor
$schema = SQL::Schema->new($dbh);
The new method instanciates a schema object. The only argument required is a database handle, which has to offer the same API as described within DBI(3).
Methods
$sql = $schema->string;
Returns an SQL string containing several statements at once. This string contains all the SQL statements to create the database schema.
This method is overloaded with the string operator. So the following two lines are equivalent:
$sql = $schema->string;
$sql = "$schema";
Download (0.033MB)
Added: 2007-04-05 License: Perl Artistic License Price:
933 downloads
MySQL table patcher 1.6.2
MySQL table patcher is a patch that reads table creation file (tables.sql) and compares it to what mysqldump gives. more>>
MySQL table patcher is a patch that reads table creation file (tables.sql) and compares it to what mysqldump gives. It creates SQL clauses to update the database to match the creation file.
<<less Download (1.9MB)
Added: 2006-08-02 License: GPL (GNU General Public License) Price:
1179 downloads
KSqlAnalyzer 0.3.0
KSqlAnalyzer is a tool for easily accessing the data of a MS SQL database. more>>
KSqlAnalyzer is a tool for easily accessing the data of a MS SQL database. It is made for developing and testing new SQL queries direclty on the server.
The functionality and look/feel of KSqlAnalyzer are similar to SQL Query Analyzer by Microsoft.
KSqlAnalyzer uses parts of the TDS library, and the editor uses parts of the KWrite source code becaus of its brilliant sytnax highlighting.
Enhancements:
- Trigger viewing and editing, and a new Edit menu item (Clear).
<<lessThe functionality and look/feel of KSqlAnalyzer are similar to SQL Query Analyzer by Microsoft.
KSqlAnalyzer uses parts of the TDS library, and the editor uses parts of the KWrite source code becaus of its brilliant sytnax highlighting.
Enhancements:
- Trigger viewing and editing, and a new Edit menu item (Clear).
Download (0.70MB)
Added: 2006-07-15 License: GPL (GNU General Public License) Price:
1197 downloads
SQL::Generator 0.02
SQL::Generator is a Perl module to generate SQL-statements with oo-perl. more>>
SQL::Generator is a Perl module to generate SQL-statements with oo-perl.
SYNOPSIS
use SQL::Generator;
With this module you can easily (and very flexible) generate/construct sql-statements. As a rookie, you are used to write a lot of sprintf`s every time i needed a statement (i.e.for DBI).
Later you start writing your own functions for every statement and every sql-dialect (RDBMS use to have their own dialect extending the general SQL standard). This SQL::Generator module is an approach to have a flexible abstraction above the statement generation, which makes it easy to implement in your perl code. Its main purpose is to directly use perl variables/objects with SQL-like code.
<<lessSYNOPSIS
use SQL::Generator;
With this module you can easily (and very flexible) generate/construct sql-statements. As a rookie, you are used to write a lot of sprintf`s every time i needed a statement (i.e.for DBI).
Later you start writing your own functions for every statement and every sql-dialect (RDBMS use to have their own dialect extending the general SQL standard). This SQL::Generator module is an approach to have a flexible abstraction above the statement generation, which makes it easy to implement in your perl code. Its main purpose is to directly use perl variables/objects with SQL-like code.
Download (0.013MB)
Added: 2007-04-05 License: Perl Artistic License Price:
932 downloads
SQL Admin 0.2.2
SQL Admin is a Java client application to connect and send queries to different databases through JDBC. more>>
SQL Admin is a Java client application to connect and send queries to different databases through JDBC.
SQLAdmin uses the brand new SWT Toolkit. The main idea is to create a multiplatform and multidatabase thin client. For example, you can connect to an Microsoft SQL Server from a Linux machine, or connect to a PostgreSQL/Linux server from a Windows machine using the same application.
Main features:
- Based on the SWT Tookit. Java applications can use the native Toolkit with a platform independant API. For example, SQLAdmin uses GTK2 in Linux
- Lightweight : The application itself is small, and the SWT provides a nice gui with a very small footprint
- Abstract JDBC driver backend. User should configure only basic parameters like server, port, and login without the need to know about Class names or JDBC URLs
- Graphical view of connections and database metadata such as schemas, tables and fields
- Multiple query execution. Also supports embedded comments on SQL Text
- Log window to view system messages and query results
- Table structure view
- Fast table rows view
<<lessSQLAdmin uses the brand new SWT Toolkit. The main idea is to create a multiplatform and multidatabase thin client. For example, you can connect to an Microsoft SQL Server from a Linux machine, or connect to a PostgreSQL/Linux server from a Windows machine using the same application.
Main features:
- Based on the SWT Tookit. Java applications can use the native Toolkit with a platform independant API. For example, SQLAdmin uses GTK2 in Linux
- Lightweight : The application itself is small, and the SWT provides a nice gui with a very small footprint
- Abstract JDBC driver backend. User should configure only basic parameters like server, port, and login without the need to know about Class names or JDBC URLs
- Graphical view of connections and database metadata such as schemas, tables and fields
- Multiple query execution. Also supports embedded comments on SQL Text
- Log window to view system messages and query results
- Table structure view
- Fast table rows view
Download (0.087MB)
Added: 2006-07-21 License: GPL (GNU General Public License) Price:
1192 downloads
sql++ 0.13
sql++ is an easily configurable, feature-rich, portable command-line SQL tool. more>>
sql++ is an easily configurable, feature-rich, portable command-line SQL tool. It can be used with many different databases and in place of other commandline tools such as MySQLs mysql-client, Microsoft SQL, PostgreSQLs psql, and Oracles sqlplus.
sql++ project has features such as multiple connections, multi-database interfacing, subselects for all databases, regardless of whether the database has native subselects or not, and much more.
<<lesssql++ project has features such as multiple connections, multi-database interfacing, subselects for all databases, regardless of whether the database has native subselects or not, and much more.
Download (0.036MB)
Added: 2006-11-09 License: GPL (GNU General Public License) Price:
1091 downloads
JDBC SQL Profiler 0.3
JDBC SQL Profiler is a Swing-based GUI tool to recommend database index creation. more>>
JDBC SQL Profiler is a quickly hacked tool to do statistics on SELECT queries in order to know where it is most efficient to create indexes.
This small tool, released under an Apache-based license connects to the P6Spy JDBC logger and displays in real time the queries going to the database. It uses an integrated SQL parser to build statistics on the most accessed tables and columns and can generate SQL index creation files.
Other information is also gathered and displayed, such as the request time for a single request, for a class of request, and for all the requests. Sorting may be done on these views to detect database problems efficiently.
This tool can be very useful when you have a big volume of queries that you need to analyze not one by one (meaning that the specific time isnt that much of interest), but rather when you want to know what "group" of queries is taking a lot of time, such as queries on the same tables and columns but with different query values. The integrated SQL parser (built with ANTLR) is used to analyze the incoming SELECT queries.
The Swing GUI was based on Apaches Log4J Chainsaw, but all the bugs are mine. Also contributors are welcome to test, make new suggestions, give their opinion and submit patches.
<<lessThis small tool, released under an Apache-based license connects to the P6Spy JDBC logger and displays in real time the queries going to the database. It uses an integrated SQL parser to build statistics on the most accessed tables and columns and can generate SQL index creation files.
Other information is also gathered and displayed, such as the request time for a single request, for a class of request, and for all the requests. Sorting may be done on these views to detect database problems efficiently.
This tool can be very useful when you have a big volume of queries that you need to analyze not one by one (meaning that the specific time isnt that much of interest), but rather when you want to know what "group" of queries is taking a lot of time, such as queries on the same tables and columns but with different query values. The integrated SQL parser (built with ANTLR) is used to analyze the incoming SELECT queries.
The Swing GUI was based on Apaches Log4J Chainsaw, but all the bugs are mine. Also contributors are welcome to test, make new suggestions, give their opinion and submit patches.
Download (1.0MB)
Added: 2005-04-28 License: The Apache License Price:
1644 downloads
mysqlrowcopy 1.0
mysqlrowcopy is a tool that generates insert statements from result sets. more>>
mysqlrowcopy is a tool that generates insert statements from result sets. It produces output similar to what might result from running mysqldump on a single SELECT query.
This project helps eliminate some of the tedium of moving data between QA and production MySQL databases.
Build:
To build mysqlrowcopy, you should run:
./configure
make
A mysqlrowcopy and mysqlrowcopy.debug file are created. They have identical functionality, the .debug version simply has debugging symbols built in (for gdb).
Since mysqlrowcopy is probably going to be I/O bound with modest CPU and RAM usage, the only reason to even build a 64-bit version is to work around potential issues in dynamic linking 32-bit binaries against 64-bit libraries.
RECIPES
1. Migrating a MySQL user account reaper from QA server to a production server.
e.g. MySQL database server qa3.example.com to prod1.example.com:
$ mysqlrowcopy -h qa3.example.com
SELECT * FROM db WHERE User = "reaper" mysql db > reaper.sql
$ mysql -h prod1.example.com mysql < reaper.sql
You could of course simply pipe the output of mysqlrowcopy into mysql and skip the intermediate file.
(Dont forget to RELOAD PRIVILEGES afterwards)
2. Keep your test environment up to date. Populate it with production data every 24 hours. You could run this sequence from cron once a day:
$ mysqlrowcopy -h finance-db.example.com
SELECT * FROM stocks WHERE modified > DATE_SUB(NOW(),INTERVAL 24 HOUR)
finance stocks > day-stocks.sql
$ cat day-stocks.sql | mysql -h finance-test.example.com finance
3. Copy data between tables on different servers that have some similar fields.
Youve got common data in table Zip on a production database:
mysql> desc Zip;
+-------------+-------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+-------------+-------------+------+-----+---------+-------+
| ZIPCode | varchar(5) | | PRI | | |
| ZIPCodeType | char(1) | YES | | NULL | |
| City | varchar(32) | YES | | NULL | |
| CityType | char(1) | YES | | NULL | |
| State | varchar(32) | YES | | NULL | |
| StateCode | char(3) | YES | | NULL | |
| AreaCode | char(3) | YES | | NULL | |
| Latitude | varchar(12) | YES | | NULL | |
| Longitude | varchar(12) | YES | | NULL | |
+-------------+-------------+------+-----+---------+-------+
9 rows in set (0.00 sec)
And youve got table ZipPosition in a research database:
mysql> desc ZipPosition;
+-------------+-------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+-------------+-------------+------+-----+---------+-------+
| ZIPCode | varchar(5) | | | | |
| Latitude | varchar(12) | YES | | NULL | |
| Longitude | varchar(12) | YES | | NULL | |
+-------------+-------------+------+-----+---------+-------+
3 rows in set (0.00 sec)
You want to load data from production Zip into research ZipPosition.
$ mysqlrowcopy -h production SELECT ZIPCode,Latitude,Longitude common ZipPosition > pos.sql
$ cat pos.sql | mysql -h qa research
Note how we specify ZipPosition on the first line to tell mysqlrowcopy what the destination table is going to be.
<<lessThis project helps eliminate some of the tedium of moving data between QA and production MySQL databases.
Build:
To build mysqlrowcopy, you should run:
./configure
make
A mysqlrowcopy and mysqlrowcopy.debug file are created. They have identical functionality, the .debug version simply has debugging symbols built in (for gdb).
Since mysqlrowcopy is probably going to be I/O bound with modest CPU and RAM usage, the only reason to even build a 64-bit version is to work around potential issues in dynamic linking 32-bit binaries against 64-bit libraries.
RECIPES
1. Migrating a MySQL user account reaper from QA server to a production server.
e.g. MySQL database server qa3.example.com to prod1.example.com:
$ mysqlrowcopy -h qa3.example.com
SELECT * FROM db WHERE User = "reaper" mysql db > reaper.sql
$ mysql -h prod1.example.com mysql < reaper.sql
You could of course simply pipe the output of mysqlrowcopy into mysql and skip the intermediate file.
(Dont forget to RELOAD PRIVILEGES afterwards)
2. Keep your test environment up to date. Populate it with production data every 24 hours. You could run this sequence from cron once a day:
$ mysqlrowcopy -h finance-db.example.com
SELECT * FROM stocks WHERE modified > DATE_SUB(NOW(),INTERVAL 24 HOUR)
finance stocks > day-stocks.sql
$ cat day-stocks.sql | mysql -h finance-test.example.com finance
3. Copy data between tables on different servers that have some similar fields.
Youve got common data in table Zip on a production database:
mysql> desc Zip;
+-------------+-------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+-------------+-------------+------+-----+---------+-------+
| ZIPCode | varchar(5) | | PRI | | |
| ZIPCodeType | char(1) | YES | | NULL | |
| City | varchar(32) | YES | | NULL | |
| CityType | char(1) | YES | | NULL | |
| State | varchar(32) | YES | | NULL | |
| StateCode | char(3) | YES | | NULL | |
| AreaCode | char(3) | YES | | NULL | |
| Latitude | varchar(12) | YES | | NULL | |
| Longitude | varchar(12) | YES | | NULL | |
+-------------+-------------+------+-----+---------+-------+
9 rows in set (0.00 sec)
And youve got table ZipPosition in a research database:
mysql> desc ZipPosition;
+-------------+-------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+-------------+-------------+------+-----+---------+-------+
| ZIPCode | varchar(5) | | | | |
| Latitude | varchar(12) | YES | | NULL | |
| Longitude | varchar(12) | YES | | NULL | |
+-------------+-------------+------+-----+---------+-------+
3 rows in set (0.00 sec)
You want to load data from production Zip into research ZipPosition.
$ mysqlrowcopy -h production SELECT ZIPCode,Latitude,Longitude common ZipPosition > pos.sql
$ cat pos.sql | mysql -h qa research
Note how we specify ZipPosition on the first line to tell mysqlrowcopy what the destination table is going to be.
Download (0.021MB)
Added: 2007-03-01 License: GPL (GNU General Public License) Price:
967 downloads
BITE SQL Reports 1.02a
BITE SQL Reports project consists of an advanced SQL reports for existing databases. more>>
BITE SQL Reports project consists of an advanced SQL reports for existing databases.
BITE is SQL reporting software that can be "plugged" into any existing database to add advanced reporting capabilities.
You can build reports and store them in the same database, view, print, save, and FTP these reports to pre-defined places, or distribute the "viewer" software so that others can run the reports that you build.
Enhancements:
- An initial Makefile has been added.
- gcc compile issues have been fixed.
<<lessBITE is SQL reporting software that can be "plugged" into any existing database to add advanced reporting capabilities.
You can build reports and store them in the same database, view, print, save, and FTP these reports to pre-defined places, or distribute the "viewer" software so that others can run the reports that you build.
Enhancements:
- An initial Makefile has been added.
- gcc compile issues have been fixed.
Download (1.9MB)
Added: 2007-01-19 License: LGPL (GNU Lesser General Public License) Price:
1009 downloads
GsqlR2 1.46
GsqlR2 is a GTK2 interface for Oracle application devlopment / testing. more>>
GsqlR2 is a GTK2 interface for Oracle application devlopment / testing.
Its features include a schema browser, multiple SQL work areas, SQL syntax highlighting, bind variable entry widgets in the command window, tracing facility, and SQL*Plus-style command scripting.
For SQL statement analysis and tuning there is a tree-style SQL statement "explain plan" facility and the ability to load SQL statements from the runtime cursor cache (V$SQL table), Oracle Statspack repository, the Oracle Automatic Workload Repository in Oracle version 10g, plus full AWR reports.
<<lessIts features include a schema browser, multiple SQL work areas, SQL syntax highlighting, bind variable entry widgets in the command window, tracing facility, and SQL*Plus-style command scripting.
For SQL statement analysis and tuning there is a tree-style SQL statement "explain plan" facility and the ability to load SQL statements from the runtime cursor cache (V$SQL table), Oracle Statspack repository, the Oracle Automatic Workload Repository in Oracle version 10g, plus full AWR reports.
Download (0.49MB)
Added: 2006-08-08 License: GPL (GNU General Public License) Price:
1172 downloads
SQL Uniform 1.8.1
SQL Uniform is a database client with a graphical user interface (GUI). more>>
SQL Uniform is a database client with a graphical user interface (GUI). The project is a helper application to relational databases of various types regarding query, maintenance, data comparison, export (convert), and import.
It supports any kind of database and database servers to which there is an ODBC or JDBC standard driver. It has been tested on the following databases: Access, Adabas D, DaffodilDB, dBASE, Excel, HSQL, IBM DB2, Interbase (Firebird), JDataStore, Linter (Relex), McKOI, Mimer, MSSQL, MySQL, Openlink Virtuoso, Oracle, Paradox, Pervasive (Btrive), Pointbase, PostgreSQL, Quadcap QED, Solid, SQLITE, Sybase, ThinkSQL, and Yard.
Enhancements:
- The data browse, SQL query, table design, administration, export, and SQL import windows are also parts of freeware mode.
<<lessIt supports any kind of database and database servers to which there is an ODBC or JDBC standard driver. It has been tested on the following databases: Access, Adabas D, DaffodilDB, dBASE, Excel, HSQL, IBM DB2, Interbase (Firebird), JDataStore, Linter (Relex), McKOI, Mimer, MSSQL, MySQL, Openlink Virtuoso, Oracle, Paradox, Pervasive (Btrive), Pointbase, PostgreSQL, Quadcap QED, Solid, SQLITE, Sybase, ThinkSQL, and Yard.
Enhancements:
- The data browse, SQL query, table design, administration, export, and SQL import windows are also parts of freeware mode.
Download (4.8MB)
Added: 2007-01-24 License: Freeware Price:
1019 downloads
SQL::Preproc 0.10
SQL::Preproc is a Perl module to embed SQL in your Perl (ala SQL preprocessors). more>>
SQL::Preproc is a Perl module to embed SQL in your Perl (ala SQL preprocessors).
SYNOPSIS
use SQL::Preproc
subclass => Chart,
emit => 1,
keepsql => 1,
syntax => [ Teradata ],
pponly => 1,
relax => 1,
alias => 1,
debug => 1;
use DBI;
use DBI qw(:sql_types);
use SQL::Preproc::ExceptContainer;
use DBIx::Chart;
...some code...
my ($host, $user, $passwd) = @ARGV;
DECLARE CONTEXT $sqlpp_ctxt;
CONNECT TO "Teradata:$host"
USER $userid IDENTIFIED BY $passwd AS myconn WITH tdat_mode => ANSI;
my $more_rows;
WHENEVER NOTFOUND { $more_rows = undef }
WHENEVER SQLERROR {
my ($ctxt, $err, $state, $errmsg) = @_;
die $errmsg;
}
DECLARE CURSOR mycursor AS
SELECT * FROM mytable FOR UPDATE;
OPEN mycursor;
my ($col1, $col2, $col3, $col4);
while ($more_rows) {
FETCH mycursor INTO :$col1, :$col2, :$col3, :$col4;
if ($col1 > $col4) {
UPDATE mytable SET col4 = col4 + 100
WHERE CURRENT OF mycursor;
}
}
CLOSE mycursor;
#
# do a bulkload via array binding
#
my @col1 = ();
my @col2 = ();
my @col3 = ();
#
# load some data into the arrays, then send it to the DBMS
#
EXEC SQL INSERT INTO sometable VALUES(:@col1, :@col2, :@col3);
#
# now create a chart, dumping results to @_
#
SELECT * FROM mytable
RETURNING LINEGRAPH(*), IMAGEMAP
WHERE WIDTH=500
AND HEIGHT=500
AND FORMAT=PNG
AND LOGO=myimage.png
AND X_AXIS=Date
AND Y_AXIS=Stock Price
AND MAPNAME=stockmap
AND SIGNATURE=GOWI Systems, Inc.
AND SHOWPOINTS=1
AND POINT=opencircle;
open(OUTF, >mychart.png) || die $!;
binmode OUTF;
print OUTF, $_[0];
close OUTF;
open(OUTF, >mychart.map) || die $!;
print OUTF, $_[1];
close OUTF;
DISCONNECT myconn;
<<lessSYNOPSIS
use SQL::Preproc
subclass => Chart,
emit => 1,
keepsql => 1,
syntax => [ Teradata ],
pponly => 1,
relax => 1,
alias => 1,
debug => 1;
use DBI;
use DBI qw(:sql_types);
use SQL::Preproc::ExceptContainer;
use DBIx::Chart;
...some code...
my ($host, $user, $passwd) = @ARGV;
DECLARE CONTEXT $sqlpp_ctxt;
CONNECT TO "Teradata:$host"
USER $userid IDENTIFIED BY $passwd AS myconn WITH tdat_mode => ANSI;
my $more_rows;
WHENEVER NOTFOUND { $more_rows = undef }
WHENEVER SQLERROR {
my ($ctxt, $err, $state, $errmsg) = @_;
die $errmsg;
}
DECLARE CURSOR mycursor AS
SELECT * FROM mytable FOR UPDATE;
OPEN mycursor;
my ($col1, $col2, $col3, $col4);
while ($more_rows) {
FETCH mycursor INTO :$col1, :$col2, :$col3, :$col4;
if ($col1 > $col4) {
UPDATE mytable SET col4 = col4 + 100
WHERE CURRENT OF mycursor;
}
}
CLOSE mycursor;
#
# do a bulkload via array binding
#
my @col1 = ();
my @col2 = ();
my @col3 = ();
#
# load some data into the arrays, then send it to the DBMS
#
EXEC SQL INSERT INTO sometable VALUES(:@col1, :@col2, :@col3);
#
# now create a chart, dumping results to @_
#
SELECT * FROM mytable
RETURNING LINEGRAPH(*), IMAGEMAP
WHERE WIDTH=500
AND HEIGHT=500
AND FORMAT=PNG
AND LOGO=myimage.png
AND X_AXIS=Date
AND Y_AXIS=Stock Price
AND MAPNAME=stockmap
AND SIGNATURE=GOWI Systems, Inc.
AND SHOWPOINTS=1
AND POINT=opencircle;
open(OUTF, >mychart.png) || die $!;
binmode OUTF;
print OUTF, $_[0];
close OUTF;
open(OUTF, >mychart.map) || die $!;
print OUTF, $_[1];
close OUTF;
DISCONNECT myconn;
Download (0.051MB)
Added: 2007-03-01 License: Perl Artistic License Price:
967 downloads
DL/SQL 1.0.1
DL/SQL is a declarative programming language based on top of a SQL database. more>>
DL/SQL is declarative, turing-complete programming language based on top of SQL database. The main idea is to store both program and data in one SQL table and make all the computations in it.
The current version of interpreter written in PHP contains quasi-lazy evaluation and simple caching.
The syntax was inspired by LISP and bash. Sounds strange? For example,
(* (+ 2 4 (#FACT 4)) 3)
means (2 + 4 + fact(4)) * 3 where fact is user-defined function for factorial.
As youve probably noticed, DL/SQL has got prefix (polish) notation with compulsory bracketing. That means, in front any name of function there must be opening bracket and after last parameter of a function there must be closing bracket. With this rule its really easy to implement variable-length argument lists.
For real deployment its necessary to change the core according to your needs - some special constructions are always necessary. Fortunatelly the core is flexible and easily extendable. Right now DL/SQL uses MySQL as its backend. Therere only several calls to DB, changing them is work for few minutes so porting DL/SQL to lets say PostgreSQL is piece of cake.
Therere only two API calls:
rpn_init()
clears all the cached values (actually sets the counted bit to false).
rpn_eval($expression)
evaluates entered DL/SQL expression. For using DL/SQL interpreter its necessary to include file rpnparser.phtml in your project. For easy implementation I also advise you to include file include/setup.phtml which contains all the necassary stuff for connecting to database and setting the directories. Without this file, youll have to do all the things yourself!
<<lessThe current version of interpreter written in PHP contains quasi-lazy evaluation and simple caching.
The syntax was inspired by LISP and bash. Sounds strange? For example,
(* (+ 2 4 (#FACT 4)) 3)
means (2 + 4 + fact(4)) * 3 where fact is user-defined function for factorial.
As youve probably noticed, DL/SQL has got prefix (polish) notation with compulsory bracketing. That means, in front any name of function there must be opening bracket and after last parameter of a function there must be closing bracket. With this rule its really easy to implement variable-length argument lists.
For real deployment its necessary to change the core according to your needs - some special constructions are always necessary. Fortunatelly the core is flexible and easily extendable. Right now DL/SQL uses MySQL as its backend. Therere only several calls to DB, changing them is work for few minutes so porting DL/SQL to lets say PostgreSQL is piece of cake.
Therere only two API calls:
rpn_init()
clears all the cached values (actually sets the counted bit to false).
rpn_eval($expression)
evaluates entered DL/SQL expression. For using DL/SQL interpreter its necessary to include file rpnparser.phtml in your project. For easy implementation I also advise you to include file include/setup.phtml which contains all the necassary stuff for connecting to database and setting the directories. Without this file, youll have to do all the things yourself!
Download (0.021MB)
Added: 2005-04-14 License: BSD License Price:
1655 downloads
DBIx::SQL::Abstract 0.07
DBIx::SQL::Abstract is a Perl module that provides a convenient abstraction layer to a database. more>>
DBIx::SQL::Abstract is a Perl module that provides a convenient abstraction layer to a database.
SYNOPSIS
use DBIx::SQL::Abstract;
my $dbh = DBIx::SQL::Abstract->new( %dbcfg );
Building SQL Abstractions.
my($query, @bind) = $dbh->select($table, @fields, %where, @order);
my($query, @bind) = $dbh->insert($table, %fieldvals || @values);
my($query, @bind) = $dbh->update($table, %fieldvals, %where);
my($query, @bind) = $dbh->delete($table, %where);
Using DBI methods
my $sth = $dbh->prepare($query);
$sth->execute(@bind_params);
...
my $rc = $dbh->begin_work;
my $rc = $dbh->commit;
my $rc = $dbh->rollback;
my $rc = $dbh->disconnect;
Anything else DBI method can be used, by Example:
my $err = $dbh->err;
my $err = $dbh->errstr;
my $rv = $dbh->state;
my $rc = $dbh->DESTROY;
The intention of this module is to join some methods from the DBI and the SQL::Abstract modules, for a convenient and easy use.
To begin, we create an object, but first we must create a hash which contains the database parameters as follows.
my %dbcfg = { PrintError => 1,
RaiseError => 0,
AutoCommit => 0,
ChopBlanks => 1
driver => Pg,
dbname => db,
host => undef,
port => undef,
user => user,
passwd => undef
};
Notice that this parameters are set as default unless you set your required values.
my $dbh = DBIx::SQL::Abstract->new( %dbcfg );
This object automatically creates the connection with the database, and gets the methods listed above.
<<lessSYNOPSIS
use DBIx::SQL::Abstract;
my $dbh = DBIx::SQL::Abstract->new( %dbcfg );
Building SQL Abstractions.
my($query, @bind) = $dbh->select($table, @fields, %where, @order);
my($query, @bind) = $dbh->insert($table, %fieldvals || @values);
my($query, @bind) = $dbh->update($table, %fieldvals, %where);
my($query, @bind) = $dbh->delete($table, %where);
Using DBI methods
my $sth = $dbh->prepare($query);
$sth->execute(@bind_params);
...
my $rc = $dbh->begin_work;
my $rc = $dbh->commit;
my $rc = $dbh->rollback;
my $rc = $dbh->disconnect;
Anything else DBI method can be used, by Example:
my $err = $dbh->err;
my $err = $dbh->errstr;
my $rv = $dbh->state;
my $rc = $dbh->DESTROY;
The intention of this module is to join some methods from the DBI and the SQL::Abstract modules, for a convenient and easy use.
To begin, we create an object, but first we must create a hash which contains the database parameters as follows.
my %dbcfg = { PrintError => 1,
RaiseError => 0,
AutoCommit => 0,
ChopBlanks => 1
driver => Pg,
dbname => db,
host => undef,
port => undef,
user => user,
passwd => undef
};
Notice that this parameters are set as default unless you set your required values.
my $dbh = DBIx::SQL::Abstract->new( %dbcfg );
This object automatically creates the connection with the database, and gets the methods listed above.
Download (0.004MB)
Added: 2006-10-14 License: Perl Artistic License Price:
1105 downloads
Secleted [ 0 ] software to compare
Copyright Notice:
Software piracy is theft, Using crack, password, serial numbers, registration codes, key generators is illegal and prevent future software development. The above sql varchar search only lists software in full, demo and trial versions for free download. Download links are directly from our mirror sites or publisher sites, torrent files or links from rapidshare.com, yousendit.com or megaupload.com are not allowed