Skip to content

Commit

Permalink
Add connection passthrough to sql:SQLSource
Browse files Browse the repository at this point in the history
  • Loading branch information
remram44 committed Mar 21, 2017
1 parent e93f8af commit 512130c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion vistrails/packages/sql/init.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,8 @@ class SQLSource(Module):
_input_ports = [('connection', '(DBConnection)'),
('cacheResults', '(basic:Boolean)'),
('source', '(basic:String)')]
_output_ports = [('result', '(org.vistrails.vistrails.tabledata:Table)'),
_output_ports = [('connection', '(DBConnection)'),
('result', '(org.vistrails.vistrails.tabledata:Table)'),
('resultSet', '(basic:List)')]

def is_cacheable(self):
Expand All @@ -156,6 +157,7 @@ def compute(self):
cached = self.get_input('cacheResults')
self.is_cacheable = lambda: cached
connection = self.get_input('connection')
self.set_output('connection', connection)
inputs = dict((k, self.get_input(k)) for k in self.inputPorts.iterkeys()
if k not in ('source', 'connection', 'cacheResults'))
s = urllib.unquote(str(self.get_input('source')))
Expand Down

0 comments on commit 512130c

Please sign in to comment.