Quantcast
Channel: dBforums – Everything on Databases, Design, Developers and Administrators
Viewing all 13329 articles
Browse latest View live

DB2 consecutive check query

$
0
0
Hello All,

I am looking for some help !

I have the below table - sample screen shot with data attached.

columns
id
ref
times
type
status


I need to run a query - that checks the last 3 consecutive times by distinct type

so for example order by timestamp asc... if the last 3 records for type 326 = Y and the current value = N then change the current value to Y to match the last 3 records. I need to do this for all records. So it needs to check by time and type

Any idea's

Thanks in advance

load command for csv --> decimal representation

$
0
0
Hallo everyone,

I have a csv with a column with such entries:
+000005200.
+000002000.
+000003120.
+000003153.
...
...

These are already the datas (no more delimiters)

I want to load this csv file, therefore I created the table with such ddl for the column:
Code:

columnName DECIMAL(9,0)
My question is:
will db2 automatically recognize and convert the entries appropiately as defined -decimal(9,0)- ??

Thanks for the help.

Regards,
Ratna

question about locks

$
0
0
Hi,
is it possible for any kind of DB2 lock to survive across transactions (that is after a commit is issued)?

Thanks!

Display data in form based on recordset

$
0
0
Hi,
I am trying to enter new/or review data in a table using a form (FWQRainfall) to specify the start (StartDate) and end (EndDate) dates. If records between these start and end dates do not exist they need to be created in the table. I found some code which gets me part of the way there - it generates new records if required, but i cannot get the records to udate and display on the form based on the specified dates. I am not sure what is wrong with syntax on the highlighted line of code below, if i block this line out the new records are created in the table (t_WQ_Rainfall) would appreciate any help. Thanks

Private Sub cmdGenRecords_Click()
Dim rs As DAO.Recordset
Dim sSQL As String
Dim sSDate As String
Dim sEDate As String

sSDate = "#" & Format(Me.txtStartDate, "yyyy/mm/dd") & "#"
sEDate = "#" & Format(Me.txtEndDate, "yyyy/mm/dd") & "#"
sSQL = "SELECT * FROM t_WQ_Rainfall WHERE DataDate Between " & sSDate _
& " AND " & sEDate

Set rs = CurrentDb.OpenRecordset(sSQL)

If rs.RecordCount < (Me.txtEndDate - Me.txtStartDate) Then
AddRecords sSDate, sEDate

End If

[COLOR="rgb(255, 0, 255)"] Me.fWQRainfall.Recordset = sSQL[/COLOR]


End Sub



Sub AddRecords(sSDate, sEDate)

sSQL = "INSERT INTO t_WQ_Rainfall (DataDate) " _
& "SELECT AddDate FROM " _
& "(SELECT " & sSDate _
& " + [counter.ID] AS AddDate " _
& "FROM [Counter] " _
& "WHERE " & sSDate _
& "+ [counter.ID] Between " & sSDate _
& " And " & sEDate & ") a " _
& "WHERE AddDate NOT In (SELECT DataDate FROM t_WQ_Rainfall)"

CurrentDb.Execute sSQL, dbFailOnError
End Sub

getting ORA-27369: job of type EXECUTABLE failed with exit code: Operation not permit

$
0
0
Im getting ORA-27369: job of type EXECUTABLE failed with exit code: Operation not permitted , when trying to run a shell script in unix from windows using a pl/sql block.i gave all the acces on the shell script

below is the script im using

begin
dbms_scheduler.create_job
(
job_name => 'test_cpm4',
job_type => 'EXECUTABLE',
job_action => '/eicapps/odi/cpm/DB_Scripts/Others/hello.sh',
enabled => FALSE,
comments => 'sample script' );
end;


im running the above black manually using
BEGIN
DBMS_SCHEDULER****N_JOB(job_name => 'test_cpm4');
END;
any any one help me.

Java Developer in Battle Creek MI‏

$
0
0
Position: Java Developer

Location: Battle Creek, MI



Required a secret clearance



Project Description

REQUIRED SKILLS:

· Technical resource that has webMethods experience, or TIBCO, webSphere, or WebLogic, Java/J2EE development, SOA, web service development, Business Process Management (BPM), Integration Server or Middleware experience, Struts, Spring, SQL, Oracle 10 g or 11g.



PREFERRED SKILLS:

· logistics experience







Thanks & Regards

Dotnet Developer in Hanover MD with DOT‏

$
0
0
Title: .Net Developer

Duration: Long Term

Location: Hanover, Maryland

Client: Department of Transportation



Required:

· must have 2 years of experience with Visual Studio 2008, ASP.NET or C# programming

· At least 2 years of experience with MS Access 2007

· At least 3 years of experience with application development using SharePoint platform

· At least 2 years of experience with Oracle 10g or higher

· At least years of experience with Business Objects Crystal Reports




Ø If you would like to unsubscribe please click on this link UNSUBSCRIBE

Ø Just in case this is not working send an email to unsubscribe@tscti.com

Ø Send an email to resumes@tscti.com with subject matter REMOVE

Thanks & Regards,

subform to subform date reference in VBA

$
0
0
I have two similar scenarios where a m/f2 with s/f2 is opening and creating a s/f2 new record. There is no data entry in this s/f2 - it is opened, filled with data from other controls and closed - on it's own.

The part where I am lost and looking for assistance is the control reference in my date field on s/f1. The data comes from another open m/f1 s/f1. So I open this m/f1 and make a new entry in s/f1 then click a button to open either scenario1 m/f2 s/f2 or scenario2 m/f2 s/f2.

I've had this running for about a year, and the only way I can get the s/f2's REGDATE to fill in is with Now() for today's date which is inaccurate. I can't get it to "find" the date I entered in s/f1. I have attached a picture for reference.

SCENARIO1 s/f2:
Private Sub Form_Current()
Me.STATLU = [Forms]![RequestResp2611]![STATLU]
Me.REGDATE = [Forms]![RequestResp2611]![RQTsfApp2611].Form!MGRDATE
Me.SLU = [Forms]![RequestResp2611]![SLU]
Me.SLU2 = [Forms]![RequestResp2611]![SLU2]
Me.PTLU = [Forms]![RequestResp2611]![PTLU]
End Sub

SCENARIO2 s/f2:
Private Sub Form_Current()
Me.STATLU = [Forms]![RequestResp2611]![STATLU]
Me.REGDATE.Value = [Forms]![RequestResp2611]![RQTsfApp2611].[Form]![MGRDATE]
Me.SLU = [Forms]![RequestResp2611]![RSLMNRQT]
Me.SLU2 = [Forms]![RequestResp2611]![RSLMNRQT2]
End Sub

I’m not sure if it’s because it’s on a s/f looking to another s/f and I wrote it wrong, or I wrote it wrong because it’s a date data type. Now that I've attempted this code, it has stopped the entire thing from triggering....so I'm guessing I have to put date somewhere else so that the other controls can get their info from m/f1 and REGDATE can get it's from s/f1?

Your wisdom is appreciated!


MODIFIED BY in LOAD

$
0
0
Hallo everyone,

I have an interesting case for deciding how to set the MODIFIED BY option:

"I am 5" tall","my Name"

How can I tell db2, that " beside the 5 is supossed to be a data?

Thank you everyone.

Regards,
Ratna

Can Proxy Tables lead to possible deadlock ?

$
0
0
Hello,

I've build a process that transfers data from a source server(ASE) to a destination one (IQ). When running it I receive, rarely but rather constant, a deadlock error.
I have a table on ASE and created a proxy table in IQ that points to it.

The flow is as follows :
1. An external source inserts data into ASE table.
2. The copy process (running on IQ), checks if data is available in ASE (looks in the ProxyTable from IQ), and, if yes, copies it from the actual table from ASE (bulk insert using : insert into location) into another table on IQ.
3. If the copy succeeded, from the same same IQ process I invoke a "delete" cmd on the proxyTable (with the purpose of erasing the data from the ASE source table), to clear off the data that has been copied.

Is it possible that the process which inserts data, first gets a lock on the ASE table (and in background this perhaps implies a request for a lock on proxy table from IQ ?), and at the same time the deletion process from IQ has a lock on the proxyTable (and waits for a lock on Original ASE table, which is already taken) ?
This is the only scenario I can think of that can cause a deadlock to arise, both processes having one lock and waiting for the other.

How does the locking mechanism work when dealing with proxy tables.

If you have any ideas please help.

Thank you,
Sorin

Is there a way to open a "print preview" of a form/report and also email it?

$
0
0
Hello all,

I'm very new to access, I'd say about 1 month or so since I started using it.

Taking some classes and doing some research, I found a way to email a form I created as a PDF. The code I'm using is this:

Private Sub Command166_Click()

Dim strReport As String

strReport = "Audit_Review_Report"
Me.Refresh
DoCmd.OpenReport strReport, acViewPreview, , "Audit_Review_ID = " & Me!Audit_Review_ID
Reports(strReport).Visible = False

DoCmd.SendObject acSendReport, strReport, acFormatPDF
DoCmd.Close acReport, strReport

End Sub

Now, this just opens a blank outlook new message and attaches the file named as "Audit_Review_Report".

I was wondering if there is any way I can change the name of the file.

I have this field called "Audit_Review_ID" in which a unique audit # is assigned to each form. I also have a field called "client" where a client is selected. So, let's say audit for client windows7 is numbered as 1234.

So ideally, I'd want my file name to be something like "1234" or "windows7" or "audit windows 7 1234" (or with _).

Is this possible? If so, could someone please walk me through it? Like I said, most of the coding I've done is based on copy-pasting others' codes.

Thank you in advance,

Gordon.

New to creating triggers which enfore data integrity

$
0
0
I am trying to create a trigger that will ensure that only one record in a table will have that character. Basically enforce uniqueness with a trigger. Any syntax hints will be helpful.


Thanks!

Query not updating variable

$
0
0
I am using the afterUpdate event on a list box to do a query and set a variable to the value from a table. The first two queries function as expected but the third one does not and yet is the same as the first two. I am looking for an explanation as to why not and a suggestion to fix or another approach. The underlying tables are the same construction differing only in the third table having two yes/no fields, I don't think that is an issue. I suspect it revolves around the recordset and snapshot. Thanks in advance, code follows
_______________________________________________


Private Sub lbFilter_AfterUpdate()
Dim Choice2
Dim DB As Database
Dim rst As Recordset
Dim rst2 As Recordset
Dim rst33 As Recordset
Dim THisSQL As String
Dim THisSQL2 As String
Dim THisSQL33 As String

''' act on the choice of contracts by COR
''' run a new query based on lbFilter value and use the ID number to pull all associated records from data values table. Then use the contract number to open the record

Choice2 = Me.lbFilter.Value
Label21.Visible = False

THisSQL = "SELECT [COR].[ID], [COR].[Location] FROM COR"
Set rst = CurrentDb.OpenRecordset(THisSQL, dbOpenSnapshot)
COR_ID = rst![ID] ' works - sets value to pass to update event

THisSQL2 = "SELECT [Contract_Groups].[Number] FROM Contract_Groups"
Set rst2 = CurrentDb.OpenRecordset(THisSQL2, dbOpenSnapshot)
Group_Number = rst2![Number] ' works - sets value to pass to update event

‘’’’’ The following three lines are the problem, the recordset is stuck on record one and not changing to the selected value in the listbox (lbFilter)
THisSQL33 = "SELECT [Station_Lookup].[Number] FROM Station_Lookup"
Set rst33 = CurrentDb.OpenRecordset(THisSQL33, dbOpenSnapshot)
StnName = rst33![Number] ' does not work

Call ListChoice3(Choice2, OneofFourChoice, COR_ID, Group_Number, StnName)

Web Developer Port of Portland, Oregon

$
0
0
Job Title: Web Developer

Location: 7200 NE Airport Way Portland, Oregon

Duration: 1 year with a possible 1 year extension.

Client: Port of Portland, Oregon






Required Skills and Abilities:

Demonstrated skills:Provide advanced knowledge and experience with the .NET framework and our Web site architecture by providing quick and well thought out and integrated solutions – demonstrate ability to handle tasks in a timely and reliable manner; advanced knowledge and proficiency in Web and digital application programming languages, Web site software architecture and applications, Web controls and Web navigation framework; solid knowledge of Microsoft Office Suite, Adobe Acrobat and working knowledge of Adobe Illustrator, Photoshop, Dreamweaver and Visual Studio; develop new or revise design and functionality using existing protocols and tools; demonstrate ability to review existing code and comprehend functions and architecture; use our development toolset effectively to ensure that we can roll-back/forward to a prior version if required and to ensure the proper version is moved to production.

Ability to: Keep pace with advanced digital communications related technologies including new versions of our core products and continue to develop visual and technical skills; actively coordinate all production turnovers and final testing to ensure that all parts and pieces of the new or revised functionality work as expected; assists with the development of the integrated solutions that further enhance the functionality of our Web site and maintains the integrity of our brand image by adding reliable and well tested designs and solutions that increase the functionality and usability of the site; be the expert on .NET framework and our Web site Architecture by providing quick and well thought out and integrated solutions – demonstrate ability to handle complex tasks in a timely and reliable manner under pressure; act as the technical expert and technology innovator for the Web team; proactively anticipate the impact of changes and how it may impact our site performance and act on that knowledge; communicate effectively verbally and in writing with our clients and within the department so that projects/requests can move forward and/or issues or problems are identified very early in the process; make suggestions that will improve either the technical reliability or the functionality of our Web site; manage the projects/requests that are assigned in a timely and effective way that not only meet assigned deadlines but also meet the project/request goals and business objectives; ability to manage simultaneous activities and priorities as well as changing priorities under extremely tight deadlines; keep pace with Web related technologies including new versions of our core products and continue to develop visual and technical skills; provide positive and constructive feedback to the team; support the goals of the Corporate Marketing Department; support other staff members as needed; be an active team participant.
Working knowledge of: Web best practices relating to site architecture, design, usability, content organization and development.

Advanced knowledge of: Web site architecture and digital technologies

Thanks and Regards

Oracle Apps Developer - Exeter NH

$
0
0
Oracle Apps Developer

Location: Exeter, NH

Full-Time//PERM role with CLIENT



5+ Years of Exp with Oracle ERP is a MUST



Job Description

- Develop Oracle PL/SQL procedures, forms, and reports to extend Oracle Applications functionality based on user requirements.

- Build reports, conversions, interfaces, and extensions for Oracle applications.

- Configure applications to suit needs that include system set-ups, flex-fields, workflow builder, custom library, and profile options.

- Assist users with problems and resolves issues independently.

- Create test plans, test cases, test scripts, and performs testing.

- Ongoing support of Oracle applications 11i and 12.

- Plans and organizes tasks and reports progress to the Manager.

- Manage other junior team members including review requests, assign tasks and track progress, and provide technical leadership for architecture design.

- Establish standards for development.

- Provide leadership in communicating with user and business and improve development processes.

- Identify and leverage tools for development.

- Proactively assess opportunities, risks, and challenges for technology and business.

- Define scope, plan, and schedule projects.

- Delegate and manage tasks of each project.

- Manage outside contractors.



Experience/Skill Requirements:

- Strong analytical and problem solving skills

- Strong programming knowledge in Oracle application extension/customizations, PL/SQL, SQL*PLUS, Forms 6i, Report 6i, Java, Workflow, Shell Scripting and Discoverer. Oracle BPEL is a plus.

- 5+ years of Oracle ERP development experience with 11i and 12.



Thanks & Regards
Ram K Vutukuri

Pyramid Consulting, Inc.

ram.v@pyramidci.com

office:404-418-6725 | fax: 678.840.2109

Oracle Accounting lead --- MO

$
0
0
Job Title : Oracle Accounting lead
Location : St. Louis, MO
Duration : 6+ Months of contract



Role Description :



I have a need for a functional Oracle Project Accounting lead. Must have R12 lead experience. Must have lead multiple end to end Implementations or upgrades. Global experience is a must. Integration experience with FA, AR, and AP modules is a must. Must be hands-on and have good configuration experience.



NOTE: Looking only for GC AND US CITIZENS
_______________________________
Thanks and Best Regards,
Neil Johnson | Technical Recruiter
Panzer Solutions LLC
45 Stuart Ave, K Unit
Norwalk CT 06850 USA
Email: neil.johnson@panzersolutions.com
Voice : 203-302-5697
Fax: 203-286-1457

Help in finding a count of columns...

$
0
0
First of all, thanks for the help. My question is this: I have a query that returns the total number of wins for a baseball team in the 1998 season in the AL division. It is the following.
Code:

SELECT name as teamName, W as Wins
FROM teams
WHERE yearID = '1998' AND lgID = 'AL'
group by name
ORDER BY W DESC

This works fantastic. However, I would like to select on a 3rd column, which we will call 'Rank'. It needs to return a ranking for the results. The team with the highest wins is ranked #1, and so on down the list. The best way to do this would be to see how many teams have the same or more wins than me. This will give the top team a ranking of 1, etc. Could anyone help me figure out how to do this? Thanks.

MS Access Database Analyst(s), Multi-year contract

$
0
0
2 positions:
one USMC MACCRAT DB Analyst and one USN CR DB Analyst

Required Skills include:
  • - Familiarity with Marine Aviation Commands Current Readiness Tool (MACCRAT) and/or USN Current Readiness Databases
  • - Advanced MS Access and Excel skills
  • - Experience in SharePoint
  • - Four years experience developing, supporting, and maintaining MS Access databases
Education Requirements:
Bachelor’s degree in a related discipline from an accredited college or university.

Location: Need to be local to Lexington Park, MD (Pax River)

*** US citizenship required per government contract. Applicants selected will be subject to a government security investigation and must meet the eligibility requirements.

If interested, please contact slebas@mainsailgroup.com.

VBA to open multiple exel documents, update, save, and close them.

$
0
0
Hello,

I'm a little new to VBA. I currently have a VBA script in MS Access that automatically opens fourteen excel documents that our team needs to update on a daily basis for linking. We used to have to open each individual document, update linking upon opening the doc, then save and close the documents one at a time.

Below is my current vba. It successfully opens each xls document one at a time automatically. After I manually update/save/exit each xls document, the next xls document in the series will then be opened for updating.

What I'm trying to do now is add code to automatically update each excel document, save the document and close the document before the next document is automatically opened. Is this possible?
Thanks in advance...




Private Sub Command47_Click()

' Late Binding (Needs no reference set)
Dim oXL As Object
Dim oExcel As Object
Dim sFullPath As String
Dim sPath As String


' Create a new Excel instance
Set oXL = CreateObject("Excel.Application")


' Only XL 97 supports UserControl Property
On Error Resume Next
oXL.UserControl = True
On Error GoTo 0


' Full path of excel file to open
On Error GoTo ErrHandle
sFullPath = "\\ad\xx\xxxxx\Reports/Daily Calibration Call Sheets/Weekly Segmentation Matrix/Current Week/California.xls"




' Open it
With oXL
.Visible = True
.Workbooks.Open (sFullPath)
End With

' Full path of excel file to open
On Error GoTo ErrHandle
sFullPath = "\\ad\xx\xxxxx\Reports/Daily Calibration Call Sheets/Weekly Segmentation Matrix/Current Week/capital.xls "




' Open it
With oXL
.Visible = True
.Workbooks.Open (sFullPath)
End With

' Full path of excel file to open
On Error GoTo ErrHandle
sFullPath = "\\ad\xx\xxxxx\Reports/Daily Calibration Call Sheets/Weekly Segmentation Matrix/Current Week/Crossroads.xls "




' Open it
With oXL
.Visible = True
.Workbooks.Open (sFullPath)
End With

' Full path of excel file to open
On Error GoTo ErrHandle
sFullPath = "\\ad\xx\xxxxx\Reports/Daily Calibration Call Sheets/Weekly Segmentation Matrix/Current Week/Denver.xls "




' Open it
With oXL
.Visible = True
.Workbooks.Open (sFullPath)
End With

' Full path of excel file to open
On Error GoTo ErrHandle
sFullPath = "\\ad\xx\xxxxx\Reports/Daily Calibration Call Sheets/Weekly Segmentation Matrix/Current Week/Florida.xls "




' Open it
With oXL
.Visible = True
.Workbooks.Open (sFullPath)
End With

' Full path of excel file to open
On Error GoTo ErrHandle
sFullPath = "\\ad\xx\xxxxx\Reports/Daily Calibration Call Sheets/Weekly Segmentation Matrix/Current Week/Midwest.xls "




' Open it
With oXL
.Visible = True
.Workbooks.Open (sFullPath)
End With

' Full path of excel file to open
On Error GoTo ErrHandle
sFullPath = "\\ad\xx\xxxxx\Reports/Daily Calibration Call Sheets/Weekly Segmentation Matrix/Current Week/nashville.xls "




' Open it
With oXL
.Visible = True
.Workbooks.Open (sFullPath)
End With

' Full path of excel file to open
On Error GoTo ErrHandle
sFullPath = "\\ad\xx\xxxxx\Reports/Daily Calibration Call Sheets/Weekly Segmentation Matrix/Current Week/NewJersey.xls "




' Open it
With oXL
.Visible = True
.Workbooks.Open (sFullPath)
End With

' Full path of excel file to open
On Error GoTo ErrHandle
sFullPath = "\\ad\xx\xxxxx\Reports/Daily Calibration Call Sheets/Weekly Segmentation Matrix/Current Week/NewYork.xls "




' Open it
With oXL
.Visible = True
.Workbooks.Open (sFullPath)
End With

' Full path of excel file to open
On Error GoTo ErrHandle
sFullPath = "\\ad\xx\xxxxx\Reports/Daily Calibration Call Sheets/Weekly Segmentation Matrix/Current Week/Northeast.xls "




' Open it
With oXL
.Visible = True
.Workbooks.Open (sFullPath)
End With

' Full path of excel file to open
On Error GoTo ErrHandle
sFullPath = "\\ad\xx\xxxxx\Reports/Daily Calibration Call Sheets/Weekly Segmentation Matrix/Current Week/Northwest.xls "




' Open it
With oXL
.Visible = True
.Workbooks.Open (sFullPath)
End With

' Full path of excel file to open
On Error GoTo ErrHandle
sFullPath = "\\ad\xx\xxxxx\Reports/Daily Calibration Call Sheets/Weekly Segmentation Matrix/Current Week/SES.xls "




' Open it
With oXL
.Visible = True
.Workbooks.Open (sFullPath)
End With

' Full path of excel file to open
On Error GoTo ErrHandle
sFullPath = "\\ad\xx\xxxxx\Reports/Daily Calibration Call Sheets/Weekly Segmentation Matrix/Current Week/Southwest.xls "




' Open it
With oXL
.Visible = True
.Workbooks.Open (sFullPath)
End With

' Full path of excel file to open
On Error GoTo ErrHandle
sFullPath = "\\ad\xx\xxxxx\Reports/Daily Calibration Call Sheets/Weekly Segmentation Matrix/Current Week/Texas.xls "




' Open it
With oXL
.Visible = True
.Workbooks.Open (sFullPath)


ErrExit:
Set oXL = Nothing
Exit Sub

ErrHandle:
oXL.Visible = False
MsgBox Err.Description
GoTo ErrExit



' Create a new Excel instance
Set oXL = CreateObject("Excel.Application")


' Only XL 97 supports UserControl Property
On Error Resume Next
oXL.UserControl = True
On Error GoTo 0
End With


End Sub

how to retain only last 3 versions of package

$
0
0
Hello

In sysibm.syspackage we are having many versions of same packages. Is there way write sql to retain only latest 3 vesrions and free others

Thank you
sri
Viewing all 13329 articles
Browse latest View live