Re: Newbie web services with WO question
Re: Newbie web services with WO question
- Subject: Re: Newbie web services with WO question
- From: "Luigi Giannini" <email@hidden>
- Date: Thu, 25 May 2006 21:30:39 +0200
Yes I have a EO_PK_TABLE.
What is the function of this table?
Where I can read about it from a more technical point of view?
I have modelled the primary key for PazientiAnagrafica entity with
following attributes:
- "Allows null" set to no
- "Class property" set to no
- "Locking" set to yes
- "External Type" set to int
- "Width" set to 4
- "Value class java" set to number
- "Value Type" set to i
for "External Type" I try different values with no success within some
(but not all) of these:
- uniqueidentifier
- tinyint identity
- smallint identity
- numeric() identity
- decimal() identity
- bigint identity
And I not find nothing about the right choose about "External Type"
setting when the fields in DB is the primary key. Moreover I want
specify that the attributes in MSSQL table for this field are normal:
Data type=int ; Lenght=4 ; Allows null=no.
Is clear also for a newbie like me that the error depends by a JDBC
problem but, without the someone else help, I have no chance.
In the technical specifications of official Apple WebObjects web site
you can read that Microsoft SQL Server 2000 8.00.194 is supported.
Where one newbie WOdeveloper can find jdbc for this RDBMS?
I search in the web and find JTDS jdbc that seem (to me) a valid,
mature and fast jdbc driver for MS-sql-srv.
May be that the jdbc driver generate the problem but if so, please,
someone show me the right jdbc to use without surprise ... or may be
that a newbie like me makes (or forget to make) something! Any ideas?
Thanks first to Chuck and then to everybody spent time to read this.
Luigi Giannini
P.S. to Chuck
I bought your book "Pratical WebObject" great !!!
I count down for the next book because I prefer to use Xcode rather
than Eclipse.
2006/5/25, Chuck Hill <email@hidden>:
On May 24, 2006, at 2:41 PM, Luigi Giannini wrote:
> Hello everyones,
> these are my first steps in WO then please patient ...
>
> I try to write a simple web service connected to MS SQL srv with
> WebServicesAssistant
> Create the EOmodel named ObjectMed using JDBC and jtds 1.2
> Create Xcode WO project with WebServicesDirect assistant
> Create a WebService (named anagrafica) in WebServicesAssistant
> Create an operation (named cerca) that search in the DB table named
> PazientiAnagrafica
> Testing the operation cerca is OK
> Create an operation (named nuovoPaziente) that insert a new record (
> ... ops object) but I have only this frustrating message:
>
> Exception:
> com.webobjects.foundation.NSForwardException
> [org.apache.axis.AxisFault] java.lang.IllegalArgumentException:
> java.lang.IllegalStateException: Adaptor
> com.webobjects.jdbcadaptor.JDBCAdaptor@f98f80 failed to provide new
> primary keys for entity 'PazientiAnagrafica': Exception trying to
> invoke operation: nuovoPaziente
>
> What is wrong?
That looks like a JDBC error, not a WebServices one. How have you
modelled the primary key for this PazientiAnagrafica entity? I have
not used MS SQL server, you might need an EO_PK_TABLE? Do you see
one in the database?
Personally, I would get a very simple web app to be able to do this
(insert into the database) and then move it to web services.
Chuck
--
Coming in 2006 - an introduction to web applications using WebObjects
and Xcode http://www.global-village.net/wointro
Practical WebObjects - for developers who want to increase their
overall knowledge of WebObjects or who are trying to solve specific
problems. http://www.global-village.net/products/practical_webobjects
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden