Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  • Users: benmillus
  • Content: Threads
  • Order by date
  1. benmillus

    Query via VBS returns -1 records

    Attempting to: >Query Informix via VBScript Problem: >Query always returns -1 records Analysis: >Manually queried using MS Query and the same DSN file. Query successfully returns 1 record. >Changed the DSN and query to Oracle DB and AS400 DB, both work fine. My code: "CONST adOpenStatic =...
  2. benmillus

    How To Call VBS from another VBS w/ Named Params

    Here is the issue: Need to call a vbs using another vbs. Last vbs to be called can also be call from command line using: "c:\scrpts\myVBS.vbs" /param1:"c:\scripts\log.txt" /param2:"Val2" /param3:"Val3" /param4:"Val4" This works fine. But when attempting to execute via another vbs it fails...
  3. benmillus

    How can a collection of objects be returned from a function

    What I am trying to do is return the objects 'cn' and 'rs' from the function below. This is what I have: Function OpenRecordSet(cn_str, uid, pwd, sql) Dim cn, rs, dbCollection() CONST adOpenStatic = 3, adLockReadOnly = 1, adCmdText = &H0001 Set cn = CreateObject("ADODB.Connection") cn.Open...
  4. benmillus

    Does not return Integer properly

    I have a table (my.table): Key Val1 Val2 Val3 xcv abc 1 2 sdf def 1 3 The query (select * from my.table) returns: Key Val1 Val2 Val3 xcv abc 1.0 2.0 sdf def 1.0 3.0 Any ideas why and how to correct this?
  5. benmillus

    Qry By Record Number

    Need to query a table without row numbers using row numbers. Like in pl-sql we can write the qry "select * from siebel.s_opty where rownum < 10;" Is there anything similiar to "rownum" in MS Access?
  6. benmillus

    SQL Performance for an 'in' statement.

    Any tips on how to make this query run faster? This is the part that really slows it down: "o.pr_dept_ou_id in ( select c.pr_dept_ou_id from s_org_ext oe, s_contact c where oe.x_name = ' 1234' and c.last_name = '1234' )" select ord.order_num, ordt.name, orgint.name...
  7. benmillus

    GetWindowThreadProcessId

    Not getting output for the 'Process ID'. Here is my code: Const PROCESS_SET_QUOTA = 256; Const TRIM_TO_ZERO = 4294967295; # 0xFFFFFFFF or (-1 as a signed long) Public hWnd, processID, threadID, hProcess, hCurProcess Declare DllFunc "long GetCurrentProcess() kernel32" _GetCurrentProcess...
  8. benmillus

    How to delete duplicate records via SQL.

    Is it possible to convert this to delete the duplicate records as they are found? If so how? If not what would you suggest? SELECT FLD1, FLD2, FLD3, FLD4 FROM DED05 WHERE ((FLD1 In (SELECT FLD1 FROM DED05 As Tmp GROUP BY FLD1,FLD2 HAVING Count(*)>1 And FLD2 = FLD2))) ORDER BY FLD1, FLD2;
  9. benmillus

    How to pass a special character in an SQL statement

    For example, &quot;UPDATE tableName SET [tableName].fieldMessage = 'OTC's Not Covered' WHERE [tableName].fieldNameID1='0403REJ' and [tableName].fieldNameID2='0008';&quot; Need to update &quot;fieldMessage&quot; with the value &quot;OTC's Not Covered&quot;. But the value contains the '...

Part and Inventory Search

Back
Top