Changes between Version 19 and Version 20 of SqlQueryMacro


Ignore:
Timestamp:
Aug 20, 2015, 9:15:29 AM (9 years ago)
Author:
figaro
Comment:

Added deprecation notice.

Legend:

Unmodified
Added
Removed
Modified
  • SqlQueryMacro

    v19 v20  
    11[[PageOutline(2-5,Contents,pullout)]]
    22
    3 = Execute an SQL Query
     3= Execute an SQL Query from within Trac
     4
     5{{{#!box warning
     6**Notice:** This plugin is deprecated in favor of SqlAlchemyQueryMacro.
     7}}}
     8
    49== Description
    510
    6 Execute an SQL Query against a configured database displaying a formatted table of results.
     11This plugin allows you to execute an SQL Query against a configured database displaying a formatted table of results from within Trac.
    712
    813See also:
     
    1217== Bugs/Feature Requests
    1318
    14 Existing bugs and feature requests for SqlQueryMacro are  [report:9?COMPONENT=SqlQueryMacro here].
     19Existing bugs and feature requests for SqlQueryMacro are [report:9?COMPONENT=SqlQueryMacro here].
    1520
    16 If you have any issues, create a  [http://trac-hacks.org/newticket?component=SqlQueryMacro&owner=JamesMills new ticket].
     21If you have any issues, create a  [/newticket?component=SqlQueryMacro new ticket].
    1722
    1823== Download
     
    2328
    2429You can check out SqlQueryMacro from [http://trac-hacks.org/svn/sqlquerymacro here] using Subversion, or [source:sqlquerymacro browse the source] with Trac.
     30
     31== Installation
     32
     33This macro requires the [https://bitbucket.org/prologic/pymills pymills] library and it makes use of its '''db''' and '''table''' modules. Please install pymills first.
     34
     35{{{#!sh
     36wget https://bitbucket.org/prologic/pymills/get/0d1424e1b0ab.zip
     37unzip 0d1424e1b0ab.zip
     38easy_install $PWD/prologic-pymills-0d1424e1b0ab
     39}}}
     40
     41To install the macro:
     42
     43{{{#!sh
     44easy_install TracSqlQueryMacro
     45}}}
     46
     47To enable in your `trac.ini` file:
     48
     49{{{#!ini
     50[components]
     51sqlquery.* = enabled
     52}}}
     53
     54== Configuration
     55
     56To configure this plugin, you must tell SQLQuery what database to connect to.
     57
     58In `trac.ini` or via the WebAdmin menu:
     59
     60{{{#!ini
     61[sqlquery]
     62uri = mysql://user:password@hostname/database
     63}}}
     64
     65You can also use Oracle or SQLite:
     66
     67{{{#!ini
     68[sqlquery]
     69uri = oracle://user:password@tns
     70}}}
     71
     72or:
     73
     74{{{#!ini
     75[sqlquery]
     76uri = sqlite:///path/to/db
     77}}}
    2578
    2679== Example
     
    4194}}}
    4295
    43 == Installation
    44 
    45 This macro requires the [https://bitbucket.org/prologic/pymills pymills] library and makes use of its '''db''' and '''table''' modules. Please install pymills first.
    46 
    47 {{{
    48 #!sh
    49 wget https://bitbucket.org/prologic/pymills/get/0d1424e1b0ab.zip
    50 unzip 0d1424e1b0ab.zip
    51 easy_install $PWD/prologic-pymills-0d1424e1b0ab
    52 }}}
    53 
    54 To install the macro:
    55 
    56 {{{
    57 #!sh
    58 easy_install TracSqlQueryMacro
    59 }}}
    60 
    61 To enable in `trac.ini`:
    62 
    63 {{{
    64 #!ini
    65 [components]
    66 sqlquery.* = enabled
    67 }}}
    68 
    69 == Configuration
    70 
    71 To configure this plugin, you must tell sqlquery what database to connect to:
    72 
    73 In `trac.ini` or via the WebAdmin menu:
    74 
    75 {{{
    76 #!ini
    77 [sqlquery]
    78 uri = mysql://user:password@hostname/database
    79 }}}
    80 
    81 You can also use Oracle or SQLite:
    82 
    83 {{{
    84 #!ini
    85 uri = oracle://user:password@tns
    86 }}}
    87 
    88 or:
    89 
    90 {{{
    91 #!ini
    92 uri = sqlite:///path/to/db
    93 }}}
    94 
    9596== Feedback
    9697