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: Lftsk
  • Content: Threads
  • Order by date
  1. Lftsk

    A simple Select Statement

    Hello, I have a simple problem that I can't seem to figure out. I have a table (tblTrans) that has records from the past 3 years. Each record is dated (TransDate). I need a Select Statement that will give me all of the records for the month prior to the current month. This is easy enough...
  2. Lftsk

    Renaming an excel WorkSheet ina DTS ActiveX Script?

    Hello, I have an DTS ActiveX script that deletes, creates and populates an excel worksheet in the same .xls file on a weekly basis. The problem I'm running into is renaming the spreadsheet after I add it into the Worksheets collection. Any help is appreciated. My code is below: Set...
  3. Lftsk

    Hello all, I hope someone here c

    Hello all, I hope someone here can help me. Here's my problem I have 2 Databases. One in MySQL and another in SQL Server. I am trying to link the MySQL Server into SQL Server using the MySQL ODBC driver 3.51. It appears to do so successfully until I try to run a query on any table in the...
  4. Lftsk

    Passing Date to a Stored Proc from an ASP page

    I hope someone can help me. I'm trying to pass a date range (from and to) from 2 text boxes on an ASP page to a stored procedure bu the recordset keeps coming back empty when I know there is at least one record in there. I'm using the ADO command object as follows: FromDate =...
  5. Lftsk

    Combining 2 rows from same table?

    Hello, I hope someone can help me. I have a table. For example's sake, it has 4 columns. In actuality, it has 15. The structure is Date smalldatetime (Primary Key) Total1 money Total2 money Total3 money (table actually has 14 different "Total" columns) The Date column will...
  6. Lftsk

    Hello, I need help with a SELECT

    Hello, I need help with a SELECT Statement. I have a table with 4 columns. Column 1 is RecType ("A", "B", "C", "D") Column 2 is Col1 Column 3 is Col2 Column 4 is Col3 All I need is one record per RecType. Each record is the highest value in Col3 for...
  7. Lftsk

    Initializing a Table in DTS

    Hello, I have a table whose contents are deleted and the table is then re-populated once a week via DTS. I believe there is a property (or some other way) in DTS that will automatically delete the contents of the table before re-populating other than an SQL task of "DELETE FROM...
  8. Lftsk

    Using SELECT CASE in conjunction with GROUP BY

    I have an SQL Statement: SELECT a.SERVER, a.OFFICE, a.LOCATION, a.[Office Name], a.[GL Code], RecType = CASE a.AcctBal WHEN >= 0 THEN 'D' WHEN < 0 THEN 'C' END, a.CLOSEDATE, 0 AS BegTotBal, 0 AS BegRecBal, SUM(a.AcctBal)...
  9. Lftsk

    Getting Top 25 records for each group

    I have a table (tblAccts). It has 3 columns (AcctNo, Category, Balance). There are 4 possible choices (A, B, C, D) for the category column. I need to get the top 25 rows (based on the dollar amount in the Balance column) in each category. I don't want them grouped together. I just need my...
  10. Lftsk

    Updating a table

    I have an issue, I'm not sure how to solve. I have 2 tables - table1 and table2 They both have the same 4 column primary key - K1, K2, K3 and K4. Table1 is a transaction table that contains charges and payments for the past year. Table2 is a summary table that in addition to the key contains...
  11. Lftsk

    DTS not executing

    Hello, I have a DTS package that used to run fine. All it did was initialize a table and then import several DBASE files into the table. Each DBASE file has the same format. All of a sudden, the initialization occurs but none of the imports occur. The only message I receive is &quot;not...
  12. Lftsk

    DTS Connections in VB - Please help

    I am trying to connect to a SQL Server DTS package in VB I have the following code Dim oPackage As DTS.Package2 Dim objConnect As DTS.Connection2 Set oPackage = New DTS.Package2 Set objConnect = oPackage.Connections.New(&quot;SQLOLEDB&quot;) With...
  13. Lftsk

    The And Operator

    I feel quite silly about this, but it just doesn't seem to work. I have a table that contains 2 columns. Duplicates exist for both. But I'll just use Column_1 for the example. Please see the example below. Column_1 Column_2 CB 12345 CB 67890 BA 12345 BA 67890...
  14. Lftsk

    Creating rows for each of current month

    Hello, please forgive me if this is stupid, but I was wondering if anybody knows or has a simple way of inserting a row for each of the current month into a table? Can I do this without a looping construct in a stored? Thank you.

Part and Inventory Search

Back
Top