Showing posts with label anywhere. Show all posts
Showing posts with label anywhere. Show all posts

Monday, March 26, 2012

Relational Algebra & SQL newbie needs help!

I have been posed and attempted to answer several questions but I do not seem to be getting anywhere. I have emailed my tutor a week ago and he has not responded, If anyone can take a look and help me out I would be grateful.
Two of the questions are below, if anyone can help with these two I'm sure that I can crack the rest!

Find the first name, surnames and address of the patients that have had at least one operation with broken bones.

SQL:

REL1=SELECT FROM Operation WHERE OperationType LIKE Broken%
REL2=Patient NATJOIN REL1 with PatientCode common.
REL3=PROJECT REL2 OVER PatientSurname, PatientFirstname, PatientAddress.

Relational Algebra:

σ operationtype = broken*(operation)
patient |x| operation
∏ patientsurname, patientfirstname, patientaddress (patient)

[I]Find the details of all patients that have shared any doctors with the patient that has the code P57". [/I]

SQL:

REL1=Operation NATJOIN Is_Seen_By with PatientCode common.
REL2=SELECT DoctorCode FROM REL1 WHERE PatientCode=P57.
REL3=Operation NATJOIN REL2 WHERE DoctorCode common.
REL4=Is_Seen_By NATJOIN REL3 WHERE DoctorCode common.
REL5=Patient NATJOIN REL4 with PatientCode common.
REL6=PROJECT REL5 OVER PatientCode, PatientSurname, PatientFirstname, PatientAddress, PatientSex, PatientAge, PatientOccupation, PatientHeight, PatientWeight.

Relational Algebra:

operation |x| is_seen_by
σ doctorcode ^ patientcode = p57(operation |x| is_seen_by)

(I can't get my head around this query at all, hence the lack of algebra)

Thanks.Bump. Please Help Me!|||Maybe these guys can help you.|||Thanks for the move, anyone got any help to offer? I'm really stuck on this one.

Wednesday, March 7, 2012

Registry entries for application to connect to remote SQL Server DB

I am trying to switch a PowerBuilder application from using a local database (SQL Anywhere) to a remote SQL Server database. I am getting IM002 after defining the data source and pointing the application to the datasource.
Can someone please send me some examples of Registry entries where an application is pointed to a remote SQL Server database?
IM002 is not a SQL Server error message. This seems to be a power builder issue, and I think you have a batter
chance to get good advice in a PowerBuilder newsgroup...
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Rajeev" <rlpd@.hotmail.com> wrote in message news:72091455-61D9-475E-B9AB-5DAF5A1DE604@.microsoft.com...
> I am trying to switch a PowerBuilder application from using a local database (SQL Anywhere) to a remote SQL
Server database. I am getting IM002 after defining the data source and pointing the application to the
datasource.
> Can someone please send me some examples of Registry entries where an application is pointed to a remote SQL
Server database?

Registry entries for application to connect to remote SQL Server DB

I am trying to switch a PowerBuilder application from using a local database
(SQL Anywhere) to a remote SQL Server database. I am getting IM002 after d
efining the data source and pointing the application to the datasource.
Can someone please send me some examples of Registry entries where an applic
ation is pointed to a remote SQL Server database?IM002 is not a SQL Server error message. This seems to be a power builder is
sue, and I think you have a batter
chance to get good advice in a PowerBuilder newsgroup...
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Rajeev" <rlpd@.hotmail.com> wrote in message news:72091455-61D9-475E-B9AB-5DAF5A1DE604@.micro
soft.com...
> I am trying to switch a PowerBuilder application from using a local database (SQL
Anywhere) to a remote SQL
Server database. I am getting IM002 after defining the data source and poin
ting the application to the
datasource.
> Can someone please send me some examples of Registry entries where an application
is pointed to a remote SQL
Server database?

Registry entries for application to connect to remote SQL Server DB

I am trying to switch a PowerBuilder application from using a local database (SQL Anywhere) to a remote SQL Server database. I am getting IM002 after defining the data source and pointing the application to the datasource
Can someone please send me some examples of Registry entries where an application is pointed to a remote SQL Server database?IM002 is not a SQL Server error message. This seems to be a power builder issue, and I think you have a batter
chance to get good advice in a PowerBuilder newsgroup...
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Rajeev" <rlpd@.hotmail.com> wrote in message news:72091455-61D9-475E-B9AB-5DAF5A1DE604@.microsoft.com...
> I am trying to switch a PowerBuilder application from using a local database (SQL Anywhere) to a remote SQL
Server database. I am getting IM002 after defining the data source and pointing the application to the
datasource.
> Can someone please send me some examples of Registry entries where an application is pointed to a remote SQL
Server database?