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 SkipVought 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: *

  1. jhall156

    For Each in DictionaryBase collections

    I have created a dictionary base collection Public Class SBTSessions Inherits System.Collections.DictionaryBase Public Sub Add(ByVal Session As SBTSession, ByVal Key As String) Dictionary.Add(Key, Session) End Sub Default Public ReadOnly Property Item(ByVal Key As String) As...
  2. jhall156

    VB and XML question

    Where do you create the XMLDoc object? JHall
  3. jhall156

    Type MisMatch Error??

    I think maybe your where clause is using single quotes which works fine in, say, VFP but not in DAO. You might try "SELECT * From tblEmployees WHERE tblEmployees.Emp_Tracker= " & CHR(34) & USERID & CHR(34) & ";" JHall
  4. jhall156

    Stored Procedures - general question

    In SQL Server you can use parameterized stored procedures. It's okay to use EXEC(sqlstr) but you won't get the benefits of a saved execution plan. JHall
  5. jhall156

    Linked DB -- availability function?

    Perhaps you could use OpenQuery() and see if you get a result like SELECT COUNT(*) FROM OPENQUERY(YourLinkedServer,'SELECT stuff FROM YourOracleTable') JHall
  6. jhall156

    datetime computation

    Once again I assumed something wrong, sorry, thought you wanted to calculate the duration. JHall
  7. jhall156

    Save table with new name

    I think you'll have to use VBA to do it. Create an tabledefs object Create a table object and "SET" it to your table Change the Name property Then use the tabledefs UPDATE method JHall
  8. jhall156

    datetime computation

    Check out DateDiff in Books On-Line DateDiff(ss, <startdatetime>, <enddatetime>) JHall
  9. jhall156

    GETDATE()

    My bust, you're right. I just had it work for me too. My apologies. JHall
  10. jhall156

    Question About Tables In SQL Server

    How can you set the default to a system function. It doesn't return today's date when I try it. I believe Column Default Values must be constant expressions. JHall
  11. jhall156

    RE: Syntax Help

    You could try using Excel automation with sp_OACreate etc. JHall
  12. jhall156

    Trigger Looping Problem

    I would comment out the trigger and see if you are able to insert into the table with your vb code. If not, then you probably have either a problem with your vb code or a permissions issue. JHall
  13. jhall156

    GETDATE()

    The Default Value for a column must be a constant expression. You could maintain it with an insert trigger but whatever process is inserting a record would be the place to put code to insert the current date IMHO. JHall
  14. jhall156

    DISTINCT query?

    Sorry, I forgot to divide by three , how about... I would first create this user defined function CREATE FUNCTION GetBeginDate (@InDate as datetime) RETURNS datetime AS BEGIN DECLARE @StartDate datetime SELECT @StartDate = DateAdd(d, -1 * (2 + CASE WHEN DatePart(dw,@InDate) BETWEEN 4...
  15. jhall156

    DISTINCT query?

    I would first create this user defined function CREATE FUNCTION GetBeginDate (@InDate as datetime) RETURNS datetime AS BEGIN DECLARE @StartDate datetime SELECT @StartDate = DateAdd(d, -1 * (2 + CASE WHEN DatePart(dw,@InDate) BETWEEN 4 AND 6 THEN 0 WHEN DatePart(dw,@InDate) = 7 THEN 1...
  16. jhall156

    ado problem..

    Have you tried using an odbcCommand object and then invoking the method ExecuteNonQuery? That works pretty well for me getting to SBT Data (VFP 5) from .NET JHall
  17. jhall156

    formula for access

    It sounds as if you are trying to earn a grade as well. I would use a switch like Hours * Switch(Grades=&quot;A&quot;, 4, Grades=&quot;B&quot;, 3, Grades=&quot;C&quot;, 2, Grades=&quot;D&quot;, 1) JHall
  18. jhall156

    ado problem..

    Does your DSN have under options &quot;Fetch Data in Background&quot; checked? If so, uncheck it. Hope that helps. JHall
  19. jhall156

    Passing data to App

    Command line should work but just out of curiosity, is there are a lot of data/functionality that you are trying to make available? If not, how would the vendor feel about incorporating the information into their application. You could provide all the needed components and all they would have...
  20. jhall156

    Loop Stops at two

    I think the RecordCount propert for DAO Recordsets (unlike ADO) only count the number of accessed records not the total number of records. To handle this just put a MoveLast and MoveFirst before you start your loop. JHall

Part and Inventory Search

Back
Top