Hi, newbie here so bear with me.
I am querying a Ora Db 10g table that holds the current Week value and current Year value.
Require a query capturing upto 14 weeks future data so therefore where the current week number plus 14 = 52 i'll need to increment the year number by 1 and set the week number to 01 before then going onto capture the associated data for each week.
I've think (!) i need to use DECODE...
User Profile
Collapse
-
How to combine DECODE and SUM with a calculation
-
SSIS OLE DB Variables - Library?
Hi, env = Visual Studio 2010 and using SSIS template for connection to DB2 databases.
Within a package we have an OLE DB Task which is configured to run a basic SQL comand and this is successfull, e.g.
[SELECT * FROM TQATTF2.TDFP11]
We have now changed the connection user id & pwd to that of a service account which only has access to the required library. Leaving the SQL statement exactly the same, it is... -
Error when writing to DB2 from SQL DB via VB.net
Complete newbie here so bear with me. I'm look at code written by a.n.other employee who is no longer around.
Using VB.net 2012, within one solution we have a routine which can successfully read data from a file on ISeries and populate a table in a sql db.
When we attempt to write to a file on the ISeries we receive the error "ERROR [42000][IBM][Iseries Access ODBC Driver][DB2 UDB]SQL0104 - Token DEFAULT was not valid.... -
Twinnyfo, Yes the ORNO value is already established in the xls and yes it must be sequential.
These are order header references in Table 2, the order lines are related by the corresponding ORNO presented in Table 3.
Cheers for your time. -
Yes the ORNO value is already established in the xls and yes it must be sequential.
These are order header references in Table 2, the order lines are related by the corresponding ORNO presented in Table 3.
Cheers for your time.Leave a comment:
-
Tks Twinnyfo,
The data is provided in xls format for loading into the db, assuming i can get the source data format for ORNO to be Integer/Long, what would solution would you suggest to ensure that the ORNO value increments by a value of 1 for each record in Table2?Leave a comment:
-
How do i confirm sequential numbers over multiple tables
Hi,
Using MS Access, '97, we have 4 tables in scope, the content of which is provided by a customer. I need to validate the data in all four tables and one validation routine is focused on a field named ORNO which exists in each of the tables.
The following examples show the content of the ORNO field
Table1.ORNO value '0012769'
Table 1 will only ever have one single record and the ORNO value must be numeric.... -
Tks NeoPa & Mihali - Yes there is only the one CR at the end of the file, i'll talk to the vendor of the other application. if they can't fix it then i'll go with the suggestion.Leave a comment:
-
Hi Rabbit,
The exported file is being processed by another application and because there is an additional blank line at the end of the file, it produces an error. Question is, how can i stop the carraige return being applied at the end of the last record of data? Cheers.Leave a comment:
-
How do i stop a carraige return from being inclued in export file?
Can any one advise on the following please;
I am exporting a table of data into a CSV file from a MS Access 97 Db. An extract of the export routine used is below;
Code:DoCmd.TransferText acExportDelim, "EXPORT_MobileSpec", "qryEXPMessageCUSTMobile", "\\server_id\C$\FolderName\FileName.csv"
-
Thanks ive sorted, left the WHERE clause in the same location but added " & FromDate & " AND " & ToDate & "Leave a comment:
-
All, I've now added the following code in an attempt to write an SQL query while using the calculated dates. When the following code runs, it prompts me to input the FromDate and ToDate, despite it already being calculated earlier in the function. Any advice appreciated
Code:StrSQL = "SELECT AULT2F2_OEP40.CONO40, AULT2F2_OEP40.CUSN40, AULT2F2_OEP40.DSEQ40, AULT1F2_T1P1A.EMIL1A, AULT2F2_OEP40.ORDN40, AULT2F2_OEP40.DTDR40" _
Leave a comment:
-
How do i query table using date range value
Hi, Im attempting to run a query over a remote Db400 table using MS Access'97 where i need to specify the from and to date. Depending on the current date, the required dates will change so I'm using VB to calculate the day number, to then calculate the from and to dates. The function is called by a query, but it fails on a type mismatch as the target field must be defined as a integer. Given this happens, is there an alternative solution, appreciate... -
Thanks S7, appreciate your comments.
Rather than complicate my first attempt with an insert, i have changed my query to be the following;
Code:DECLARE @DeliveryDate smalldatetime DECLARE @DepotID int DECLARE @ContractID int set @deliverydate = '2011.11.09' set @depotid = 43 set @contractid = 21 EXEC AMT_DipsOrderSummaryByDate @DeliveryDate, @DepotID, @ContractID
Leave a comment:
-
How to make a local table based on results of a remote sql stored procedure
Hi, From a MS Access97 db i am attempting to write a function that will run a SQL 2000 stored procedure(SP). As part of the function, i need to add some selection criteria that will be used at the point the SP is executed.
I have defined the ODBC settings and tested these ok along with the selection citeria of Date / DepotID / ContractID
How do i call / execute the SP to make a local table of the results whilst also... -
Cognos Impromptu Report - Windows Error on Save Snapshot
Hi,
Using Impromptu v7.0.702.9
I have connected to database no issues, ran the report no issues.
With the report on screen I then select File | Save As, edit the file name and select the "Save a snapshot with the report" check box, the application produces error "Administra tor Version has encountered a problem & needs to close. Please tell Microsoft about this problem"
... -
How to test SMTP from Windows 2003 with Lotus Domino?
Hi, having trouble with an application's auto email alert system. The vendor has recommended we try using a telnet session to create/send and email.
I have followed the following text on the application server (Windows 2003)
Telnet
set LocalEcho
open <mailservername > 25
mail from:email@doma in.com
After entering the last line above, i receive a syntax error message but without any further... -
-
Yes the field in the underlying table is numeric.
I've applied the following to the select query;
Ordered: Format([Demand],"000000000" )
When it is run, the values are displayed as i require them,
specifically - a value of 9 is returned as 000000009.
However, when i export the data into a txt file the zero's are removed and two decimal places are added
eg 9.00Leave a comment:
-
Hi, the file extension is .txt and im viewing the results in notepad.Leave a comment:
No activity results to display
Show More
Leave a comment: