java.lang.Object
edu.internet2.middleware.grouper.app.gsh.sqlRun

public class sqlRun extends Object
Run a sql script against DB (like ant does it)

Since:
0.0.1
Version:
$Id: sqlRun.java,v 1.3 2008-11-13 20:26:10 mchyzer Exp $
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static void
    invoke(bsh.Interpreter interpreter, bsh.CallStack stack, File scriptFile)
    Create tables and init schema (depending on configuration in grouper.properties)
    static int
    invoke(bsh.Interpreter interpreter, bsh.CallStack stack, String sql)
    Executes an SQL statement.
    static int
    invoke(GrouperSession grouperSession, Object scriptFileOrString)
    Executes an SQL statement.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • sqlRun

      public sqlRun()
  • Method Details

    • invoke

      public static void invoke(bsh.Interpreter interpreter, bsh.CallStack stack, File scriptFile)
      Create tables and init schema (depending on configuration in grouper.properties)

      Parameters:
      interpreter - BeanShell interpreter.
      stack - BeanShell call stack.
      scriptFile -
      Since:
      0.0.1
    • invoke

      public static int invoke(bsh.Interpreter interpreter, bsh.CallStack stack, String sql) throws GrouperShellException
      Executes an SQL statement.

      Parameters:
      interpreter - BeanShell interpreter.
      stack - BeanShell call stack.
      sql -
      Returns:
      int The number of updates made.
      Throws:
      GrouperShellException
      Since:
      0.0.1
    • invoke

      public static int invoke(GrouperSession grouperSession, Object scriptFileOrString)
      Executes an SQL statement.

      Parameters:
      grouperSession -
      scriptFileOrString -
      Returns:
      int The number of updates made if executing a string.