Help with Script to get user details

Hi All
I am trying to get a list of groups that the currently logged on user belongs to. I came accross an interface in the RG "UserAccountIBeanIfc" which has a method "getGroupsAsCollection".
The problem is that i do not know how to call this method.
Help would be appreciated and points awarded!
Regards
Thashin

Hi Thashin  -
I understand what you are trying to do now. You can definitely accomplish what you are trying to do using the IAPIs. Logically, here is what you need to do:
- Get the User Account Bean for the current logged in user
- Get the list of user groups from the User Account Bean
- Iterate over the list to see if the logged in user is a member of the user groups required to perform the operation
- If the user is a member, let the operation be executed
- If the user is not a member, throw an exception using ApplicationException
To get the User Account Bean for the current logged in user, you would use code such as:
accHome = IBeanHomeLocator.lookup(session, session.getAccount().getAccountObjectReference());
accBean = accHome.find(session.getAccount().getAccountObjectReference());
The accBean would have the method on it that you want to use to get the list of user groups:
groupColl = accBean.getGroupsAsCollection();
You should then be able to iterate over the groupColl to establish whether the user is a member of any of the required groups.
I hope this helps. Good luck.
Rob
PS: Please don't forget to award points if this was helpful.

Similar Messages

  • Need Help with script For Bulk Users Name & Description Updation

    Hi Guys,
    I have below requirement :
    We are having one windows 2008 stand alone server with 200+ local users (No Active Directory Account).
    1. Requirement is to update each account's "Full name" and "Description field" with same text. Which means , Full name and Description field will be same with same text. No other changes are required. )Attached the screenshot)
    Can you guys pls help me out with any scripting (vbs , powershell , DOS .etc etc) method to accomplish this task quickly as manual process is very troublesome and take long time.
    Any help will be highly appreciated,
    Thanks,
    Suvajit Basu

    Hi,
    I dont have any script but seeking for a help.
    Thanks,
    Suvajit Basu
    In that case you should read this first:
    https://social.technet.microsoft.com/Forums/scriptcenter/en-US/a0def745-4831-4de0-a040-63b63e7be7ae/posting-guidelines?forum=ITCG
    Prewritten scripts can be found in the repository (Brent has already suggested one for you):
    https://gallery.technet.microsoft.com/scriptcenter
    If you can't find what you need and you can't write your own, you can request a script here:
    https://gallery.technet.microsoft.com/scriptcenter/site/requests
    Let us know if you have any specific questions.
    Don't retire TechNet! -
    (Don't give up yet - 13,085+ strong and growing)

  • PowerShell Script to get the details Like Scope,Last Deployed date and Name for a Solution Deployed in the Farm.

    Hi Experts,
    I am trying to  build a PowerShell Script to get the details Like Scope,Last Deployed date and Name for a Solution Deployed in the Farm.
    Can anyone advise on this please.
    Regards

    Get-SPSolution|Select Name,Scope,LastOperationResult,LastOperationEndTime|Export-CSV "SPInstalledSolutions.csv" -NoTypeInformation
    SPSolution properties
    Get-SPSolution
    This post is my own opinion and does not necessarily reflect the opinion or view of Slalom.

  • I have an itouch, most songs i got off my cd's. i have a new laptop and want to put songs from itouch to laptop.I can only get the songs that i purchased onto the laptop? need help with how to get the rest from itouch to laptop please??

    i have an itouch, most songs i got off my cd's. i have a new laptop and want to put songs from itouch to laptop.I can only get the songs that i purchased onto the laptop? need help with how to get the rest of the songs (from my cd's) from itouch to laptop please??

    See this previous discussion:
    Recovering your iTunes library from your iPod or iOS device: Apple Support Communities

  • Where does apex get user details from for login in

    sorry for this stupid question. I have been looking up in google "where does apex get user details from for login in" and nothing answers my question. Basically I wanted to know when you log in your application how does apex know you have access to this application. How does it know you are a valid user because I am creating an application which basically checks if a user exist in one database and also checks if he/she exist in the second database.
    Thanks you and sorry if this is very newbie

    In the page 101 which is the login in page in the login in process. I have this in the source its not working in term of it is not letting me login in anymore even though I exist in the user table.
    DECLARE
    v_access_level number;
    BEGIN
    SELECT count(*)INTO
    v_access_level
    FROM USER
    WHERE UPPER(USER_NAME) = UPPER(:APP_USER);
    IF NVL(v_access_level, 0) !=0 THEN
    wwv_flow_custom_auth_std.login(
        P_UNAME       => :P101_USERNAME,
        P_PASSWORD    => :P101_PASSWORD,
        P_SESSION_ID  => v('APP_SESSION'),
        P_FLOW_PAGE   => :APP_ID||':9'
    ELSE
    wwv_flow_custom_auth_std.login(
        P_UNAME       => :P101_USERNAME,
        P_PASSWORD    => 'YtYuTrFRd',
        P_SESSION_ID  => v('APP_SESSION'),
        P_FLOW_PAGE   => :APP_ID||':9'
    END IF;
    end;
    please bare in mind that my USER table DOES NOT have a password because the authentication scheme as all the details of login in to any systems. I am only trying to check if the username exist in my USER table.
    Thanks

  • Help with JTree data by user input

    I am trying to read data into a JTree without it being hardcoded.
    An example of the data is:
    String data[] = {"a","b","c",";","b","g","h",";","c","t",";","g","u"};
    The above data is taken from user input and stored in an array and checked for errors.
    I want to somehow read take the above array's data and put it into following format in some kind of loop but I am not sure how.
    Object[] hierarchy = {"a", new Object[]{"b",new Object[]{"g","u"},"h"},new Object[]{"c","t"}};
    This Object is then passed to a function that interpets it and prints out the appropriate JTREE structure. For the values above it would be:
    a
    ..b
    ....g
    ......l
    ......u
    ....h
    ..c
    ....t
    Tha problem is how to take the string array and put that data correctly into the Object array. I have been racking my feeble mind for quite sometime and if any one out there can see it or has a better idea of how to get my data into the JTree please let me know.
    Thanks

    //OutlookClient.java
    //uses also Console class from Bruce Eckel 
    //<applet code=OutlookClient width=500 height=300>
    //</applet>
    import javax.swing.*;
    import java.awt.event.*;
    import java.awt.*;
    import javax.swing.event.*;
    import javax.swing.tree.*;
    import java.util.*;
    import javax.swing.UIManager;
    import javax.swing.SwingUtilities;
    import BruceEckel.*;
    import DynamicTree.*;
    import DynamicTreeNode.*;
    import java.lang.reflect.*;
    /* a class creating a dialog with the version, and other details about the program*/
    class AboutDialog extends JDialog {
         private JButton ok = null;
         private Container cp = null;
         private JTextField tname = null;
            public AboutDialog() {
                   //System.out.println("constructor");
                   ok = new JButton("OK");
                   cp = getContentPane();
                   cp.setLayout(new FlowLayout());
                   JLabel tlab = new JLabel("Outlook - client side");
                   cp.add(tlab);
                   //tname.setMinimumSize(new Dimension(50,10));
                   //tname.setSize(new Dimension(70,10));
                   tlab = new JLabel("Author: Jiri Machotka");
                   cp.add(tlab);
                   tlab = new JLabel("version 1.0 (September 2001)");
                   cp.add(tlab);
                   tlab = new JLabel("----------------------------------------------");
                   cp.add(tlab);
                   ok.addActionListener( new ActionListener() {
                      public void actionPerformed(ActionEvent e) {
                        dispose();
                      }//actionPerformed
                   });//addActionListener
                   cp.add(ok);
                   setSize(200,150);
                   setTitle("About the program");  
                   setModal(true);
         }//constructor
      *      <P>This class more-or-less contains a graphic design object used for interaction with a user.</P>
      *     Apart from all ScrollPanes, Buttons, and MenuItems, it contains also 3 interesting members:
      *     <ol>
      *     <li> <I>protected final DefaultMutableTreeNode topNode</I>, which is initialized with
      * a potent, non-removable object of the class <I>Node</I>
      *     <li> <I>protected final DefaultTreeModel treeModel</I>, which is initialized with the <I>topNode</I>
      *     <li> and finally <I>protected final DynamicTree dyn_tree</I>, which uses the 2 objects above
      *     </ol>
      *     <P> The <I>OutlookClient</I> is an applet, but it can be also processed as an application (thanks to
      *     a library by BruceEckel).</P>
    public class OutlookClient extends JApplet {
    //------------- properties -----------------------------------------
       private Action
            newMail = new AbstractAction ("New Mail", new ImageIcon("images/NewMailIcon.gif")){
              public void actionPerformed(ActionEvent e) {
                         txt.setText("NewMail");
         reply     = new AbstractAction ("Reply", new ImageIcon("images/ReplyIcon.gif")){
              public void actionPerformed(ActionEvent e) {
                         txt.setText("Reply");
       private JButton
         /*b1 = new JButton("Add a Node"),
         b2 = new JButton("Remove the current Node"),*/ //not used now
         tb1 = new JButton (newMail),
         tb2 = new JButton (reply);
       private JTextField
         txt = new JTextField(10);
       private Container
         leftArea = new Container(),
         rightArea = new Container();
       private JScrollPane
            left = new JScrollPane (leftArea, JScrollPane.VERTICAL_SCROLLBAR_ALWAYS, JScrollPane.HORIZONTAL_SCROLLBAR_ALWAYS),
            right = new JScrollPane (rightArea, JScrollPane.VERTICAL_SCROLLBAR_ALWAYS, JScrollPane.HORIZONTAL_SCROLLBAR_ALWAYS);
       private JSplitPane
            sp = new JSplitPane (JSplitPane.HORIZONTAL_SPLIT, left, right);
       private JToolBar
         toolBar = new JToolBar();
       private JMenuBar
         menuBar = new JMenuBar();
       /*ActionListener al = new ActionListener() {
         public void actionPerformed(ActionEvent e) {
            String name = ( (JButton)e.getSource()).getText();
            txt.setText(name);
       };*/     //not used now - used as an action listener for buttons b1, b2
       private JMenu
         mainOutlookMenu = new JMenu ("Outlook activities"),
         othersMenu      = new JMenu ("Others"),
         mailMenu     = new JMenu ("Mails"),
         chatMenu     = new JMenu ("Chat"),
         look_and_feelMenu = new JMenu ("Look&Feel");
       private JMenuItem
         closeAppItem     = new JMenuItem ("Exit",KeyEvent.VK_F3),
         newMailItem     = new JMenuItem (newMail),
         replyItem     = new JMenuItem (reply);
       private JRadioButtonMenuItem
         windowsLookAndFeelItem;
       protected final DefaultMutableTreeNode topNode = new DefaultMutableTreeNode(new Node ("Outlook", false, true));
       protected final DefaultTreeModel treeModel = new DefaultTreeModel(topNode);
       protected final DynamicTree dyn_tree = new DynamicTree(topNode, treeModel);
    //-------------inner classes----------------------------------------
    /** <P>The class <I>MyRenderer</I> sets the renderer of the tree - by doing that icons can be assigned to
       * the tree's nodes. </P>
       * <P> It sould be probably a standard member of a class <I>DynamicTreeWithIcons</I>.</P>
       * <P> However, it uses the knowledge that the class <B>Node</B>, which is the only object that can be
       * found in the dynamic tree in this application, has a method <I>getIcon()</I>, which returns a
       * reference to the icon object assigned to the node.</P>
       * <P><B>This is the only place, where the class Node, or its methods are called explicitely.</B></P>
       protected class MyRenderer extends DefaultTreeCellRenderer {
         /** The constructor of the class.
           * - sets folders icons (opened, closed folder)
         public MyRenderer() {
                 //setLeafIcon(new ImageIcon("images/middle.gif")); //for leaves' icon, all at once!
              setOpenIcon(new ImageIcon("images/folder_open.gif"));
              setClosedIcon(new ImageIcon("images/folder_close.gif"));
         /** This overridden method gets the user-specified icon for leaf nodes. */
         public Component getTreeCellRendererComponent(
                   JTree tree,
                   Object value,
                   boolean sel,
                   boolean expanded,
                   boolean leaf,
                   int row,
                   boolean hasFocus) {
              super.getTreeCellRendererComponent(tree,value,sel,expanded,leaf,row,hasFocus);
              if (leaf) 
              //workaround: test if icon not eq. null
                     ImageIcon ic = getRightIcon(value);
                     if (ic == null) return this;
                     else
                          setIcon(ic);
              return this;
         }//overridden: getTreeCellRendererComponent
         private ImageIcon getRightIcon(Object value) {
           DefaultMutableTreeNode node = (DefaultMutableTreeNode)value;
              try{
              Node node_object = (Node)(node.getUserObject());   
                 return (node_object.getIcon());
           catch (Exception e) { return null; }
         }// ImageIcon getRightIcon(Object value)
      }//class MyRenderer
    //-------------OutlookClient methods-----------------------------------------
       private void assignListeners(){
         dyn_tree.addTreeSelectionListener(new TreeSelectionListener() {
             public void valueChanged(TreeSelectionEvent e) {
              DefaultMutableTreeNode node = (DefaultMutableTreeNode)dyn_tree.getLastSelectedPathComponent();
              if (node == null) return;
              if (node.isLeaf()) { txt.setText(node.toString()); }
       }//assignListeners()
       private void createLayout(){
         leftArea.setLayout(new BoxLayout(leftArea,BoxLayout.Y_AXIS));
         rightArea.setLayout(new BoxLayout(rightArea,BoxLayout.Y_AXIS));
         //left.setMinimumSize(new Dimension(120,200));
         right.setMinimumSize(new Dimension(50,50));
         //rightArea.add(b1);
         //rightArea.add(b2);
         rightArea.add(txt);
         //leftArea.add(tree);  ... not nice (why?)
           left = new JScrollPane (dyn_tree, JScrollPane.VERTICAL_SCROLLBAR_ALWAYS, JScrollPane.HORIZONTAL_SCROLLBAR_ALWAYS);       
         left.setMinimumSize(new Dimension(180,200));
         sp.setLeftComponent(left);
       }//createLayout()
       private void createMenu(){
         ButtonGroup group = new ButtonGroup();
            JRadioButtonMenuItem rbMenuItem;
         closeAppItem.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_F3, ActionEvent.ALT_MASK));
         closeAppItem.getAccessibleContext().setAccessibleDescription("Closes application");
         closeAppItem.addActionListener( new ActionListener() {
              public void actionPerformed(ActionEvent e) {System.exit(0);}
         othersMenu.setMnemonic(KeyEvent.VK_O);
         othersMenu.getAccessibleContext().setAccessibleDescription("System settings&Others");
            rbMenuItem = new JRadioButtonMenuItem("Java");
            rbMenuItem.setSelected(true);
            rbMenuItem.setMnemonic(KeyEvent.VK_J);
            group.add(rbMenuItem);
            rbMenuItem.addActionListener(new ActionListener() {
              public void actionPerformed(ActionEvent e) {setPLAF(UIManager.getCrossPlatformLookAndFeelClassName( ) );}
            look_and_feelMenu.add(rbMenuItem);
            rbMenuItem = new JRadioButtonMenuItem("Windows");
            rbMenuItem.setMnemonic(KeyEvent.VK_W);
            group.add(rbMenuItem);
            rbMenuItem.addActionListener(new ActionListener() {
              public void actionPerformed(ActionEvent e) {setPLAF("com.sun.java.swing.plaf.windows.WindowsLookAndFeel");}
            look_and_feelMenu.add(rbMenuItem);
         windowsLookAndFeelItem = rbMenuItem;
         look_and_feelMenu.setMnemonic(KeyEvent.VK_L);
         look_and_feelMenu.getAccessibleContext().setAccessibleDescription("Look&Feel");
         JMenuItem aboutItem = new JMenuItem ("About");
         aboutItem.addActionListener(new ActionListener() {
              public void actionPerformed(ActionEvent e) {
                   AboutDialog ad = new AboutDialog();
                   ad.show();
         othersMenu.add(look_and_feelMenu);
         othersMenu.addSeparator();
         othersMenu.add(aboutItem);
         othersMenu.addSeparator();
         othersMenu.add(closeAppItem);
         mainOutlookMenu.setMnemonic(KeyEvent.VK_A);
         mainOutlookMenu.getAccessibleContext().setAccessibleDescription("Outlook activities");
         menuBar.add(mainOutlookMenu);
         menuBar.add(othersMenu);
         mailMenu.setMnemonic(KeyEvent.VK_M);
         mailMenu.getAccessibleContext().setAccessibleDescription("Mail activities");
         chatMenu.setMnemonic(KeyEvent.VK_C);
         chatMenu.getAccessibleContext().setAccessibleDescription("Chat");
         chatMenu.setEnabled(false);
         mainOutlookMenu.add(mailMenu);
         mainOutlookMenu.addSeparator();
         mainOutlookMenu.add(chatMenu);
         //mailMenu.add(newMail);
         //mailMenu.add(reply);     //class Action has problems to catch the accelerator keys
         newMailItem.setMnemonic(KeyEvent.VK_N);
         replyItem.setMnemonic(KeyEvent.VK_R);
         mailMenu.add(newMailItem);
         mailMenu.add(replyItem);
         newMailItem.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_N, ActionEvent.CTRL_MASK));
         replyItem.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_R, ActionEvent.ALT_MASK));
         //newMail.putValue(Action.NAME, "New mail");
         //newMail.putValue(Action.SHORT_DESCRIPTION, "New mail");
         //newMail.putValue(Action.LONG_DESCRIPTION, "New mail");
         //newMail.putValue(Action.MNEMONIC_KEY, "N");  //cast an exception. why?
         //newMail.putValue(Action.ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_N, ActionEvent.CTRL_MASK));     
         setJMenuBar(menuBar);
       }//createMenu()
       private void createToolBar(){
         //toolBar.add(newMail);
         //toolBar.add(reply);    //does not provide texts and mnemonics
         tb1.setMnemonic(KeyEvent.VK_N);
         tb2.setMnemonic(KeyEvent.VK_R);
         toolBar.add(tb1);
         toolBar.add(tb2);
       }//createToolBar()
       private void createNodes(DefaultMutableTreeNode topNode){
         //new for dynamic processing
         DefaultMutableTreeNode
              parentNode = null,
              leaveNode  = null;
         parentNode = dyn_tree.addObject(null,new Node ("MailFolders", false, true));
         dyn_tree.addObject(parentNode,new Node ("Inbox","images/InboxIcon.gif", false, false));
         dyn_tree.addObject(parentNode,new Node ("Outbox","images/OutboxIcon.gif", false, false));
         dyn_tree.addObject(parentNode,new Node ("Sent","images/SentIcon.gif", false, false));
         dyn_tree.addObject(parentNode,new Node ("Deleted","images/DeletedIcon.gif", false, false));
         //leaveNode.setEnabled(false);  //TODO: disable "Chat"node
         dyn_tree.addObject(null,new Node ("Chat", false, false));
       }//createcreateNodes(DefaultMutableTreeNode)
       private void setTreeSettings(){
         //one selection at one time
         dyn_tree.getSelectionModel().setSelectionMode(TreeSelectionModel.SINGLE_TREE_SELECTION);
         //connect nodes with a thin line - Java style only
         dyn_tree.putClientProperty("JTree.lineStyle","Angled");
         //collapse the root's children first
         //tree.setShowsRootHandles(false);
         //icon adjustment
         MyRenderer MyRen = new MyRenderer();
         dyn_tree.setCellRenderer(MyRen);
         //modifiable tree - by double click - allows modifying of nodes' names
         // but unfortunately also restores original icons
         //tree.setEditable(true);
       }//setTreeSettings()
       private boolean setPLAF(String LookAndFeelName){
          try{
         UIManager.setLookAndFeel(LookAndFeelName);
         SwingUtilities.updateComponentTreeUI(this);
         return true;
          } catch (Exception e) {
         //e.printStackTrace(System.err);
         return false;
       }//setPLAF(String LookAndFeelName)
       private void trytosetLookAndFeel(){
          if (setPLAF("com.sun.java.swing.plaf.windows.WindowsLookAndFeel"))
              windowsLookAndFeelItem.setSelected(true);
       }//trytosetLookAndFeel()
       /** The applet's <I>init()</I>.
         * Calls methods to construct all visible objects.
         * Apart from that it also assigns the renderer to the tree.
       public void init(){
         sp.setOneTouchExpandable(true);
            //sp.setDividerLocation(150); - system puts the value to optimize the left part
         sp.setPreferredSize(new Dimension(450,200));
         Container cp = getContentPane();
         cp.setLayout(new FlowLayout());
            createLayout();     
         createMenu();
         createToolBar();
         createNodes(topNode);
         setTreeSettings();
         //createPopupMenu();
         assignListeners();
         cp.add(toolBar);
         cp.add(sp);
         trytosetLookAndFeel();
       }//init()
       /** If called as an application.
         * The desired Windows Look&Feel is re-set again, when the applet is running. Otherwise, it in an application
         * it tends not to work correctly.
       public static void main(String[] args) {
         OutlookClient theApplet;
         BruceEckel.Console.run(theApplet=new OutlookClient(), 500, 300);
         theApplet.trytosetLookAndFeel();
       }//main(String[])
    }///:~Take a look namely at createNodes
    Hope it helps.

  • Help with scripting a period in barcode between fields.

    Good Morning,
    I need help scripting a barcode that has a period as a separator in between fields.
    I have 3 fields that I need all encoded in to one barcode and need a period as separators.
    EMPID
    FormName
    EMPSSN
    I need barcode to read as follows
    EMPID.FormName.EMPSSN
    546514.Harvest123.555284569
    I am very new to this and any help would be greatly appreciated.

    When you go to the Barcode's Value tab and select "Custom calculation script", you get an empty template of how the barcode's value is calculated, which you can then fill-in with the names of the form fields. You can also edit the separator used between the values. I'm not sure the result is a valid barcode, strictly speaking, but it works. Here's the code I used:
    /* Customize: */
    function bMemberOf(strName, aStrNames)
        for (var nMembIdx in aStrNames)
            if (strName == aStrNames[nMembIdx])
                return true;
        return false;
    function strTabDelimited(oParam)
        var bNeedTab = false;
        var strNames = "";
        var strValues = "";
        for (var i = 0; i < oParam.oDoc.numFields; ++i)
            var strFieldName = oParam.oDoc.getNthFieldName(i);
            if ((null == oParam.aFields || bMemberOf(strFieldName, oParam.aFields))
                && (null == oParam.strXclField || strFieldName != oParam.strXclField)
                && (oParam.oDoc.getField(strFieldName).type != "button"))
                if (bNeedTab)
                    if (oParam.bFieldNames)
                        strNames += "."; // I changed these two lines so the separator is a period instead of the default tab
                    strValues += ".";
                if (oParam.bFieldNames)
                    strNames += strFieldName;
                strValues += oParam.oDoc.getField(strFieldName).value;
                bNeedTab = true;
        if (oParam.bFieldNames)
            return strNames + "\n" + strValues;
        else
            return strValues;
    try
        if ( app.viewerVersion >= ADBE.PMD_Need_Version )
            event.value = strTabDelimited({oDoc: this, aFields: ["EMPID", "FormName", "EMPSSN"], bFieldNames: true});
        else event.value = " ";
    catch (e)
        event.value = " ";

  • Need help with script

    There is request to dump every day’s data from one table into text file. I need to write shell script and sql script for that
    There are two tables (INSPECTION_RESULTS and NJAS) under NJSHDOWN schema. The table NJAS is child table of INSPECTION_RESULTS. The key is RES_SYS_NO. The script should get the MIN and MAX RES_SYS_NO from INSPECTION_RESULTS table for yesterday’s date. Then use these RES_SYS_NOs to fetch data from NJAS table. I then need to create comma delimited file for following columns. Also, to add the logic in shell script to check for oracle error (ORA-). If there is error, it should send email to DBAs group(first test it with your email address).
    Following columns are needed from NJAS table.
    NJA_RES_SYS_NO
    NJA_TEST_REC_NO
    NJA_LIC_ST_ID
    NJA_ETS_ID
    NJA_SW_VER
    NJA_TECH_ID
    NJA_VIN
    NJA_LIC_NO
    NJA_LIC_JUR
    NJA_LIC_SRC
    NJA_MODEL_YR
    NJA_MAKE
    NJA_MODEL
    NJA_VHCL_TYPE
    NJA_BODY_STYLE
    NJA_CERT_CLASS
    NJA_GVWR
    Okay- here is the script that I have so far but now, I am stuck. I cannot figure out how to get my script to finish output to comma delimited file and to check for oracle errors. Can anyone help me out here? Thanks!
    Initial script:
    SELECT NJA_RES_SYS_NO, NJA_RES_SYS_NO, NJA_TEST_REC_NO,
    NJA_LIC_ST_ID,
    NJA_ETS_ID,
    NJA_SW_VER,
    NJA_TECH_ID,
    NJA_VIN,
    NJA_LIC_NO,
    NJA_LIC_JUR,
    NJA_LIC_SRC,
    NJA_MODEL_YR,
    NJA_MAKE,
    NJA_MODEL,
    NJA_VHCL_TYPE,
    NJA_BODY_STYLE,
    NJA_CERT_CLASS,
    NJA_GVWR,
    NJA_ASM_ETW,
    NJA_ETW_SRC,
    NJA_NO_OF_CYL,
    NJA_ENG_SIZE,
    NJA_TRANS_TYPE,
    NJA_DUAL_EXH,
    NJA_FUEL_CD,
    NJA_VID_SYS_NO,
    NJA_VRT_REC_NO,
    NJA_ARMSTDS_REC_NO,
    NJA_RSN_F_N_TESTABLE,
    NJA_DYNO_TESTABLE,
    NJA_CURR_ODO_RDNG,
    NJA_PREV_ODO_RDNG,
    NJA_PREV_TEST_DT,
    NJA_TEST_TYPE,
    NJA_TEST_START_DT,
    NJA_TEST_END_TIME,
    NJA_EMISS_TEST_TYPE,
    NJA_TEST_SEQ_NO,
    NJA_LOW_MILE_EXEMP,
    NJA_TIRE_DRY,
    NJA_REL_HUMID,
    NJA_AMB_TEMP,
    NJA_BAR_PRESS,
    NJA_HCF,
    NJA_GAS_CAP_ADAP_AVL,
    NJA_GAS_CAP_REPL,
    NJA_OVERALL_GAS_CAP_RES
    FROM NJAS
    WHERE NJA_RES_SYS_NO IN (SELECT MIN(NJA_RES_SYS_NO) FROM INSPECTION_RESULTS WHERE NJA_RES_SYS_NO IN
    (SELECT MAX(NJA_RES_SYS_NO) FROM INSPECTION_RESULTS WHERE SYSDATE=SYSDATE-1)
    Thanks!
    Scott

    Thanks here is thus far what I have, focusing on the sql script part which is the trickiest:
    -- writedate.sql script for njas
    SELECT NJA_RES_SYS_NO||','||NJA_TEST_REC_NO||','||NJA_LIC_ST_ID||','||NJA_ETS_ID||','||NJA_SW_VER||','||NJA_TECH_ID||','||NJA_VIN||','||NJA_LIC_NO||','
    ||NJA_LIC_JUR||','||NJA_LIC_SRC||','||NJA_MODEL_YR||','||NJA_MAKE||','||NJA_MODEL||','||NJA_VHCL_TYPE||','||NJA_BODY_STYLE||','||NJA_CERT_CLASS||','||
    NJA_GVWR||','||NJA_ASM_ETW||','||NJA_ETW_SRC||','||NJA_NO_OF_CYL||','||NJA_ENG_SIZE||','||NJA_TRANS_TYPE||','||NJA_DUAL_EXH||','||NJA_FUEL_CD||','
    || NJA_VID_SYS_NO||','|| NJA_VRT_REC_NO||','|| NJA_ARMSTDS_REC_NO||','|| NJA_RSN_F_N_TESTABLE||','|| NJA_DYNO_TESTABLE||','||
    NJA_CURR_ODO_RDNG||','|| NJA_PREV_ODO_RDNG||','|| NJA_PREV_TEST_DT||','|| NJA_TEST_TYPE||','||
    NJA_TEST_START_DT||','|| NJA_TEST_END_TIME||','|| NJA_EMISS_TEST_TYPE||','|| NJA_TEST_SEQ_NO||','
    ||NJA_LOW_MILE_EXEMP||','||NJA_TIRE_DRY||','|| NJA_REL_HUMID||','|| NJA_AMB_TEMP||','||NJA_BAR_PRESS||','|| NJA_HCF||','||
    NJA_GAS_CAP_ADAP_AVL||','|| NJA_GAS_CAP_REPL||','|| NJA_OVERALL_GAS_CAP_RES
    FROM NJAS
    WHERE NJA_RES_SYS_NO IN (SELECT MIN(NJA_RES_SYS_NO) FROM INSPECTION_RESULTS WHERE NJA_RES_SYS_NO IN
    (SELECT MAX(NJA_RES_SYS_NO) FROM INSPECTION_RESULTS, (SELECT SYSDATE-1 FROM DUAL))
    =====================
    Output thus far:
    ======================
    NJA_RES_SYS_NO||','||NJA_TEST_REC_NO||','||NJA_LIC_ST_ID||','||NJA_ETS_ID||','||
    4,,04-MAR-03,R,27-MAR-03,27-MAR-03,O,,N,,,,,,,,Z
    10871630,5274,CIF000025,CL002901,4.13,INL004025,1B7GL22X7WS569744,VK765K,NJ,B,19
    98,DODGE,DAKOTA,T,3,TIER0,5200,3750,M,06,3.9,A,N,GASO,1446865,14663,3019,,Y,4654
    5,,21-MAR-03,I,21-MAR-03,21-MAR-03,O,,N,,,,,,N,N,P
    How do I strip the comments from the output file? Also not sure if my subquery is performing the output correctly. Thanks.
    Scott

  • Help with Scripting forms when additional characters added

    Hi,
    I am new to scripting in adobe professional, I thank anyone in advance for any advice or help they can give me.
    I am trying to use the calcuations within the forms that I am putting fields onto.  In the process I discovered that the program the forms are within are attaching a pipe and additional characters after the actual name that I have named them.  So, I am not able to use even the simple calculations within adobe to "sum" fields.   For example: I named the field "1_1Text" and this is what displays when you go into the calculations and pick the fields you want.  But the actual name is "1_1Text|1234567" so the calculations will not work.
    I take it then I need to use the advanced scripting but I am unsure of the format for a routine such as this.  I have a little knowledge of javascript but it has been awhile.  There must be a scan to find the pipe and then you should be able to chop off the extra characters since I will never know the characters the program adds on so then I can do calculations on these fields. Then you would have to put them into an array or something to save them?   Any help with a script or hints would surely be appreciated.
    Thanks!

    Could explain more fully how you are creating your forms and what programs you are using from the creation of the base document to which program and how you are adding fields.
    I think you are misunderstanding me.   I use Adobe Acrobat Professional 6.0.  I can get the calculations to work correctly if I use the form as it is after creating it. 
    But these forms are put into an SQL database and they get selected within a VB.net program or ASP.net program (both are used).  So these programs (VB.net or ASP.net) are adding the extra characters at the end, hence I do not know the names of the fields when the forms are being filled in.  So the calculations do not work with the "original names" that I created for the fields.
    I just figured if I created a routine that looped through and chopped off the extra characters these programs put on the end I would be able to do the calcuations and they would work.  I believe there is a substring operation within javascript.

  • Help with JAVA StringObject - & assign user input; StringMethod

    Hi Everyone! I need help with this Java Program, I need to write a program, single class, & file. That will prompt the user to enter a word. The output will be separted by hypens and do this until the user enters exit. I think this is done by using a string variable. Then use the length of the word to setup a loop to print each letter out with hypens. (example c-a-t)
    1. I think I should store the word like this: Word.Method(). Not sure of this the API was confusing for me because I wasn't sure of what to do.
    2. A string method to find out how many letters are in the user's word in order to setup a loop to print each letter out. I think I can use a While loop to accomplish this?
    3. A string method to access each letter in a string object individually in order to print individual letters to the screen with those hypens. This is really confusing for me? Can this be accomplished in the While loop? or do I declare variables in the main method.
    Any examples you can refer me to would be greatly appreciated. Thanks

    Getting user input:
    This may look strange to a newbie but there's nothing much you can do since you wanted a single class file:import java.io.*
    public class InputTest {
       public static void main(String[] args) {
          BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
          System.out.println("Hi! Please type a word and press enter.");
          String lineReadFromUser = in.readLine();
          System.out.println("You typed " + lineReadFromUser);
    }You can get the lenght of a String using the length() method. Example: int len = "Foobar".length();
    You can get the individual characters of a String with the charAt() method. Example: char firstCharOfString = string.charAt(0);
    (remember that the argument must be from 0 to length-1)
    You can access the documentation of all classes, including java.lang.String, at http://java.sun.com/j2se/1.3/docs/api/index.html You can also download the docs.

  • Getting User Details using objectid

    Hi,
    First i am querying the projects using ALUI IDK
    ===========
    IProjectManager projectManager = GetProjectManager(Request, Response);
    IProjectFilter projectFilter = projectManager.CreateProjectFilter();
    projectFilter.NameSearchText = searchText;
    Plumtree.Remote.PRC.Collaboration.Project.IProject[] projects = projectManager.QueryProjects(projectFilter);
    =================
    then i am retreiving User IDsadded as Project Leader
    ========================
    IRole role = null;
    RoleTypes roleType = RoleTypes.Leader;
    role = project.GetRole(roleType);
    int[] GroupID = role.GetMemberIDs(MemberQueryTypes.AllGroups);
    Display Group ID
    =========================
    Now the issue is i am not able to figure out how to get the users detail ie authusername, login name etc present in the groups that are retrieved.
    Regards,
    Ankit
    Edited by: electrazy on Jul 18, 2011 11:39 AM
    Edited by: electrazy on Jul 20, 2011 2:22 AM

    Hello electrazy,
    This is not possible from within the IDK. The best you can get are the Extended Data properties that are associated with the user object in the Global Property Map. If you want to get user information like the authentication name and the login name, you'll have to use the Portal Server API or directly query the database.
    -Mike Headley, WCI Developer Support

  • How To Get User Details in Collaboration ....?

    HI,
    In collaboration i am unable to see the full User Details (Like Mobile Phone Number, E-Mail Address, etc)  ,When i was click on
    user Names. Here i will get full  User Details for some users and for some users i did not get(But getting only Last Name &  User ID )  . Here we  already having Data in User
    Profiles.

    Hi,
    Maintain the user profile information for all the users in Identity management.
    Regards,
    kiruthika

  • Need help with script - either shell or applescript

    ok, so what i want to do is make some sort of script, either applescript or shell script, that will do the following:
    take out from a command in the terminal
    put that output into a text file already on my computer.
    the only thing is that i need to put the output in the file kinda weird: i need to take it and put each character of output on a new line, but not create new lines
    example:
    take output of command 'uptime' (up 32 days, 23:09)
    place in file 'myFile'
    output:
    key u
    key p
    key space
    key 3
    key 2
    key space
    key d
    anyone have any idea on how to do this?
    thanks in advance

    OK, here is the new one, it will go through the existing text, replacing the text between the specified stopping and starting lines with the shell script text:
    <pre style="
    font-family: Monaco, 'Courier New', Courier, monospace;
    font-size: 10px;
    margin: 0px;
    padding: 5px;
    border: 1px solid #000000;
    width: 720px; height: 340px;
    color: #000000;
    background-color: #FFDDFF;
    overflow: auto;"
    title="this text can be pasted into the Script Editor">
    -- get the file to write to
    property MyFile : missing value -- the file to write to (alias)
    if MyFile is missing value then set MyFile to (choose file with prompt "select a file to write to:" default location (path to desktop) without invisibles)
    -- get the data
    set {TempTID, AppleScript's text item delimiters} to {AppleScript's text item delimiters, ","}
    set MyText to the first text item of (do shell script "uptime") -- just get the uptime part
    set AppleScript's text item delimiters to ""
    set {MyText, AppleScript's text item delimiters} to {the text items of MyText, TempTID} -- get the characters
    -- add text to each character of the data
    repeat with AnItem from 1 to (count MyText)
    if item AnItem of MyText is " " then
    set item AnItem of MyText to "key space" -- expand the space character
    else
    set item AnItem of MyText to "key " & item AnItem of MyText
    end if
    end repeat
    -- show the result
    choose from list MyText with prompt "the following results will be written:" with empty selection allowed
    if result is false then return -- exit
    -- make the new file
    set OldFile to paragraphs of (read MyFile) -- read the old file
    set NewFIle to {} -- this will be the contents of the new file
    set ReadOrNot to true
    repeat with SomeLine in OldFile -- step through each line
    set SomeLine to the contents of SomeLine
    if SomeLine is equal to "key n" then -- stop copying lines
    -- set the end of NewFIle to SomeLine -- include the stop line
    set ReadOrNot to false
    set NewFIle to NewFIle & MyText -- add the data text
    else if SomeLine is equal to "key Down Arrow" then -- start copying lines again
    -- set the end of NewFIle to SomeLine -- include the start line
    set ReadOrNot to true
    else if ReadOrNot then -- add lines only if we are copying
    set the end of NewFIle to SomeLine
    end if
    end repeat
    -- write the new results to the file
    try
    set TheOpenFIle to (open for access MyFile with write permission)
    set eof TheOpenFIle to 0 -- write over the existing contents
    repeat with SomeLine in NewFIle
    write SomeLine & return to TheOpenFIle
    end repeat
    close access TheOpenFIle
    on error ErrorMessage number ErrorNumber -- oops
    log space & (ErrorNumber as text) & ":" & tab & ErrorMessage
    try
    close access TheOpenFIle
    end try
    end try
    </pre>
    I didn't know if you wanted to include the stop and start lines, so just uncomment the appropriate statement(s) if you want to include them. I left the stop line comparison as "key n", change it to your number (or some unique text string if you only want one specific replacement).

  • Please help with script for 3D object

    Hi!
    I have PDF file with simple 3d object (for example a cube).
    I need to make script that when user right-click to this cube, some PDF file (c:\mypdf.pdf) opening in new windows. How to make it? Thank you so much!

    Hi!
    I have PDF file with simple 3d object (for example a cube).
    I need to make script that when user right-click to this cube, some PDF file (c:\mypdf.pdf) opening in new windows. How to make it? Thank you so much!

  • Please help with script for right-mouse click on 3D objects

    Hi!
    I have PDF file with two simple 3d objects (for example with two cube).
    I need to make script that when user right-click to first cube, a PDF file (c:\a.pdf) opening (or c:\b.pdf for second one) in new windows. How to make it? Thank you so much!

    Hi,
    please check SDK sample 22 Right-Click, there is everything you need.
    First catch RightClickEvent, then create the menu entry when beforeAction = true, and when beforeAction = false you have to remove it again (otherwise you will receive an error when rightclicking again).
    Regards
    Sebastian

Maybe you are looking for

  • Recording audio on my iMac

    This may sound like a simple/dumb question, but I'll ask it anyway! How do I record audio that is playing on my iMac? For instance, say I wanted to record the audio from a video on YouTube? I've tried downloading a couple of programs (the last being

  • Old airport (2003) versus new AEBS

    Hi, what is the difference between the old airport versus the new? I have two macs & iphones that will be connected to it? Is it faster and better range? Both macs are intel. Any help is appreciated. I'm working from home and setting up my network an

  • APs not joining WLC

    Hello community, I hope you can help me with my problem. I have a vWLC Firmware version: 7.4.121.0, I have also Aironet 1700Aps I have successfully configured wlc with service and management interface. In the management network I can ping the vWLC ma

  • IOS 5.0 / 5.0.1 Playlist issue on 3GS/iP4 and i4S

    I have a few iOS devices as noted above this issue is experienced on all of them Post upgrade to iOS 5 the new "Split" ipod.app (music and videos) has performance issues with large playlists. Performance issue arent the biggest issue, however large p

  • Can I sync to a network share or personal web server?

    Hello, I really love the idea of FireFox Sync. However I am very uncomfortable with storing that much personal information on a third party server, even one as trusted as yours. Is there a way to sync up to my own web server (running linux) or sync u