8 votes

SQL for XSLT (jesper.com)

Version 2.0 released - this version contains a new method "SQLExecuteScalar" to use for sqlstatements like INSERT and UPDATE.

This package installs an XSLT extension that enables you to execute any SQL statements. You can use it on the Umbraco database or on any other database for which you have configured a database connection string in web.config

You can use it to fetch any MSSQL data as xml and you can use it to update any MSSQL data.

Have a look at the jesper.umbracosql.xslt example file and try adding the macro to a template or RTE.

Security warning
Do NOT pass any inputvalues, querystring parameters directly into the sql expression.

Examples of use
* fetching / updating data from another database and present it with an xslt macro
* log visitor behaviour to db
* update your custom counter

Configuring another db
Just add the following to your web.config
<add key="MYOWNDB" value="server=myservername.dk;database=test;user id=testuser;password=ddd33422" />

Umbraco 3+ and MS SQL server.

Good luck


 ... HEY - please remember to vote for this if you like it.

Package owner

Jesper Ordrup

Jesper Ordrup

Jesper has 1528 karma points

Package Compatibility

This package is compatible with the following versions as reported by community members who have downloaded this package:
Untested or doesn't work on Umbraco Cloud
Version 8.18.x (untested)

You must login before you can report on package compatibility.

Previously reported to work on versions:

Package Information

  • Package owner: Jesper Ordrup
  • Created: 10/09/2009
  • Current version 2.0
  • License MIT
  • Downloads on Our: 2.8K